The main function script is working very well.
Nope. Your cwt.m function is not returning any actual numbers.
>> out=cwt(x0); class(out)
ans =
'sym'
You need to provide actual numeric values for the variables ('delta_a', 'delta_c', 'delta_t', 'Di'). You cannot define them with sym().
Also, Aeq and beq should not be generated inside cwt(). Your cwt_solver() function cannot see them there.
Best Answer