Differential of a User-defined Function (Matlab)
显示 更早的评论
Hi,
How might I make my script perform differentiation on a user-defined function? I also want the function and its derivative (in the form of a function) to be applied throughout the script, say in the forms of f and f' respectively, which I believe requires str2func.
Example: The user is prompted for an f(x). He enters x^3. Then both x^3 and 3*x^2 are applied in the place of f and f' throughout the script.
Thanks in advance!
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Functional Programming 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!