[Scilab-users] using "intg" in a function
    haasejos 
    haasejos at web.de
       
    Sat Jan 26 19:44:28 CET 2013
    
    
  
hello,
I wont to write a little programm like the example below. When I use
 
/function [wert] = in(x(1) , x($));
     wert = intg(x(1),x($),quad);
endfunction;/
(what I want to do!) it does not work. What am I doing wrong?
thanks a lot!
*clear; clc; xdel;
function y = linear(x);
    y = 2*x;
endfunction;
function yy = quad(x);
    yy = (linear(x))^2;
endfunction;
function [wert] = in(x(1) , x($));
     wert = intg(x(1),x($),quad);
endfunction;
x =  [0:4];
wert = intg(x(1) , x($) , quad); //this works*
--
View this message in context: http://mailinglists.scilab.org/using-intg-in-a-function-tp4025769.html
Sent from the Scilab users - Mailing Lists Archives mailing list archive at Nabble.com.
    
    
More information about the users
mailing list