Derivatives of chained functions

33 views
Skip to first unread message

Alan Bromborsky

unread,
May 4, 2014, 4:08:38 PM5/4/14
to sympy
let s be a symbol and

x = Function('x')(s)

f = Function('f')(x)

Then let F be an expression containing f (UndefinedFuction) and defined
functions.

You want to calculate diff(F,s), but you do not want to evaluate
diff(f,s). You do want to
evaluate the derivatives of all the defined functions. In general you
will not know the names
of the UndefinedFuction(s) in F.

What is a good way of evaluating the derivative of F with respect to s
under this constraint.

Chris Smith

unread,
May 9, 2014, 12:16:18 PM5/9/14
to sy...@googlegroups.com
Maybe if you replace functions with symbols and use idiff and then back-replace the symbols with the functions you will get what you want? It would be easier to understand if you give an actual F that you are interested in.

Alan Bromborsky

unread,
May 9, 2014, 12:22:47 PM5/9/14
to sy...@googlegroups.com
On 05/09/2014 12:16 PM, Chris Smith wrote:
Maybe if you replace functions with symbols and use idiff and then back-replace the symbols with the functions you will get what you want? It would be easier to understand if you give an actual F that you are interested in.
--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To post to this group, send email to sy...@googlegroups.com.
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/96985648-d3cb-4ff5-9f60-d973806f97c2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
In effect I did what you suggested.
Reply all
Reply to author
Forward
0 new messages