help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: anonymous function


From: Deep
Subject: Re: anonymous function
Date: Wed, 6 Jul 2011 02:52:14 -0700 (PDT)

Hi, 
If I understand you correctly you should try something like this:

function [a b]=f
  a=@(x) x;
  b=@(x) x.^2;
endfunction

g = @(t) a(t)+b(t)

a and b can be any functions you want and can be of any number of variables.
g can then be any combination of those functions. Hope this helps.

Dave



--
View this message in context: 
http://octave.1599824.n4.nabble.com/anonymous-function-tp3600567p3648181.html
Sent from the Octave - General mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]