Solving equation, calculus derivatives
4 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I really am stuck on this question, any help appreciated,
For the function f(x) = (exp(-2*x)-2.7*x^2)/(cosh(3*x)
find the coordinates of the point with x>0 at which f has a zero derivative.
x =?
y=?
I know that I have to differentiate the function, and than set the derivative to zero, however I canot seem to set f'(x)=0 on matlab, this is what I have done so far.
syms x
f=inline((exp(-2*x)-2.7*x^2)/(cosh(3*x)))
df=diff(f(X),x)
and than i try and do fzero(df,1) on matlab, to set the derivative to zero, and than find he value of x, which I will than put back into the derivative to get the value of y. However i am really stuck from this point onwards.
Any help appreciated.
0 Kommentare
Antworten (1)
Walter Roberson
am 17 Feb. 2013
There is no reason to inline()
syms x
f = (exp(-2*x)-2.7*x^2)/(cosh(3*x));
df = diff(f, x);
solve(df, x)
1 Kommentar
Pascal André
am 2 Okt. 2015
Bearbeitet: Pascal André
am 2 Okt. 2015
Pay attention to syms and double:
Example:
syms t
x=100*t
dx=diff(x,t)
y=100*t-9.81*t^2
dy=diff(y,t)
timpact=max(double((solve(y,t))))
xmax=subs(x,t,timpact)
thmax=double(solve(dy,t))
ymax=subs(y,t,thmax)
I hope to have contributed a little cause I am a beginner.
Siehe auch
Kategorien
Mehr zu Calculus finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!