Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function f2 = changefunction(f1)
- fs = func2str(f1);
- fs(fs=='+') = '*';
- f2 = str2func(fs);
- end
- f = @(x) x+5;
- a = 5;
- g = @(x) x+a;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement