comparison scripts/plot/fplot.m @ 6220:0c3537d2a844

[project @ 2006-12-30 17:29:34 by jwe]
author jwe
date Sat, 30 Dec 2006 17:29:35 +0000
parents 34f96dd5441b
children 3f4ccca05612
comparison
equal deleted inserted replaced
6219:ba9db82d85a8 6220:0c3537d2a844
42 n = 100; 42 n = 100;
43 endif 43 endif
44 44
45 x = linspace (limits(1), limits(2), n)'; 45 x = linspace (limits(1), limits(2), n)';
46 46
47 if (strcmp (class (fn), "inline function") 47 if (isa (fn, "inline function") || isa (fn, "function_handle"))
48 || strcmp (class (fn), "function handle"))
49 y = fn (x); 48 y = fn (x);
50 elseif (all (isalnum (fn))) 49 elseif (all (isalnum (fn)))
51 y = feval (fn, x); 50 y = feval (fn, x);
52 else 51 else
53 finl = inline (fn); 52 finl = inline (fn);