How can I differentiate a function w.r.t. a dependent variable symbolically?

3 visualizzazioni (ultimi 30 giorni)
Hello everyone. I have a problem regarding differentiating a functions w.r.t. a dependent variable (let's say another function) - moreover this is a multivariate problem. I did solve it by hand actually, but the final version became so complicated that I wanted to verify the solution with Matlab, if I can.
The functions, just a part of them at least for instance are:
N=sin(t)+sin(t)*u;
x=3*cosh(t)+sin(u);
y=sinh(2*t)-9*sin(u);
I need to find:
diff(N,x,3);
diff(N,y,3);
and they should be in terms of t and u.
Any solution anyone would like to recommend?
PS: The functions are far too complicated than given here involving many sin, cos, sinh, cosh terms in fact. I just reduced them for the sake of context.

Risposta accettata

Birdman
Birdman il 29 Mar 2018
Modificato: Birdman il 29 Mar 2018
According to the definition of diff function, the thing you want is not possible. See the attached figure.
  1 Commento
kandaz
kandaz il 29 Mar 2018
Yes, that is the error message I'm getting. I was just wondering whether there is any workaround, by defining functions in other ways, substituting variables, using inverse functions and their derivatives, etc?

Accedi per commentare.

Più risposte (0)

Community Treasure Hunt

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

Start Hunting!

Translated by