How to nest functions?
Ältere Kommentare anzeigen
Hello, I have a function. Then I want to create another function and use the value of the first function to compute the second one. How can I "connect" these functions?
Regards, Sergey
2 Kommentare
I'm unclear what you want to do exactly. Functions can call each other:
F = @(X)(X + 2)
G = @(X)(2*F(X) + F(4))
G(F(2))
Are all valid.
Sergey Dukman
am 14 Jan. 2016
Bearbeitet: Walter Roberson
am 14 Jan. 2016
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Mathematics finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!