undefined function max for sym matlab

2 views (last 30 days)
I am generating a code to find reference signal from pid gain values ,but couldnt find maximum for the reference signal,could you please help me out of this problem,i am attaching the code which i am working: Kp=0.4662; Kd=0.2546; Ki=0.2456; Ei=60 F=laplace(Ei,s) Eo=((Kp+Ki/s+Kd*s)*F); F1=Eo; ref=ilaplace(F1,t1) st=0.1; % simulation period in seconds Ts=1e-6; % sampling peiod in seconds t=0:Ts:st; Cont=7*sin(2*pi*50*t); Ar1=(7*ref) Ar=max(Ar1)

Answers (1)

Star Strider
Star Strider on 28 Feb 2015
Use the norm function.
From the documentation:
  • norm(A,inf) is computed as max(abs(V)).
  2 Comments
preethamrengarajan kannan
preethamrengarajan kannan on 28 Feb 2015
Edited: preethamrengarajan kannan on 28 Feb 2015
I tried this but the error i received was "Undefined function 'norm' for input arguments of type 'sym'."
Star Strider
Star Strider on 28 Feb 2015
Edited: Star Strider on 28 Feb 2015
That’s strange. The documentation page I linked to is clearly part of the Symbolic Math Toolbox, because I specifically chose it from the other options. The online documentation is for R2014b, so if you have an earlier version, the norm function may not be available. I don’t know when it was introduced.
Search ‘Help’ in your version documentation under ‘Linear Equations’ to see what functions you have available.

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!