When solving a differential-algebraic system (DAE) via the command:
options = odeset('Mass', rand(3));[t,z] = ode15s('odefun', TSPAN, X0, options);
where odefun is the derivative function, I receive the following error:
??? SWITCH expression must be a scalar or string constant.
Best Answer