Im fairly new to matlab and I keep getting the same error message.
When the following is entered: diff cot^2(sin theta)
I get:
Error using sym>convertExpression (line 2256) Conversion to 'sym' returned the MuPAD error: Error: Unexpected 'identifier'. [line 1, col 11]
Error in sym>convertChar (line 2167) s = convertExpression(x);
Error in sym>convertCharWithOption (line 2150) s = convertChar(x);
Error in sym>tomupad (line 1881) S = convertCharWithOption(x,a);
Error in sym (line 108) S.s = tomupad(x,'');
Error in char/diff (line 11) y = diff(sym(f),varargin{:});
Would appreciate any help or guidance thank you.

 Akzeptierte Antwort

Walter Roberson
Walter Roberson am 12 Dez. 2012

0 Stimmen

syms theta
diff( cot(sin(theta))^2, theta)

3 Kommentare

Frank
Frank am 12 Dez. 2012
Awesome thank you!
I ran this code:
syms theta %create symbolic variable theta
assume(theta,'real') %theta is real
f = fit_v2; %calling our fitted polynomials
g = diff(f,theta);
g0=solve(g,theta);
double(g0);
I get this error:
Error in sym (line 215)
S.s = tomupad(x);
Error in sym/privResolveArgs (line 988)
argout{k} = sym(arg);
Error in sym/diff (line 21)
args = privResolveArgs(S,varargin{:});
Error in code (line 54)
g = diff(f,theta);
Walter Roberson
Walter Roberson am 29 Dez. 2017
What is fit_v2 ?

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by