Differentiating a symbolic function

i want to differentiate f=@(x)x^3-4*x^2+x+6; how can i do this? how i can find f'(x)?

Antworten (2)

KSSV
KSSV am 24 Mär. 2017

0 Stimmen

syms x
f=x^3-4*x^2+x+6;
df = diff(f)
Roger Stafford
Roger Stafford am 24 Mär. 2017

0 Stimmen

Express your function in symbolic form and use ‘diff’.

Gefragt:

am 24 Mär. 2017

Beantwortet:

am 24 Mär. 2017

Community Treasure Hunt

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

Start Hunting!

Translated by