how to solve a system of equations in matlab
1 view (last 30 days)
How do I solve this system of equations in matlab for F(-2:2) ?
f(x)= x+2 if x<=0
-x+2 if x>0
Apparently you can't use an if for this solution, but I don't really understand why either.
Thanks in advance