Error in writing c-coefficient as a function of unknown solution u

Why I got error after writing this c-coefficient? I got error pointing at my u=parabolic() c='(por^3*(1-ct*(u-u0))^3)/(5*S^2*(1-(por*(1-ct*(u-u0))))^2)';
Even if I use the period for the multiplication I still got error.
Please help and thank you,

1 Comment

I meant error after c='(por^3*(1-ct*(u-u0))^3)/(5*S^2*(1-(por*(1-ct*(u-u0))))^2)';

Sign in to comment.

 Accepted Answer

As the documentation states, Use .*, ./, and .^ for multiplication, division, and exponentiation operations. The text expressions operate on row vectors, so the operations must make sense for row vectors. This means you need to use .^3 and similar for exponentiation.
If you want more help then I strongly suggest that you give us more information. Specifically, which MATLAB version are you running? What is the exact and full error message that MATLAB throws? What is the exact and full function call?
Alan Weiss
MATLAB mathematical toolbox documentation

More Answers (0)

Asked:

on 15 Jan 2016

Commented:

on 28 Jan 2016

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!