Suppose, v(x) is a user-defined function. How, to get v(-x) which is going to be used in the same code?
5 views (last 30 days)
Show older comments
Is there any in-built MATLAB function to do it. Should we define user-defined function, say, a local function. If so, how that can be done?
0 Comments
Answers (2)
Titus Edelhofer
on 13 Feb 2015
Hi,
sorry, I don't understand the question. If you have the function, why don't you simply call v(-x)?
Or are you looking for defining this function? In this case you could do e.g.
minusv = @(x) v(-x);
Titus
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!