On Wed, Apr 20, 2022 at 6:37 AM Jonathan Gutow <gu...@uwosh.edu> wrote:
>
>
> On Apr 19, 2022, at 10:48 PM, Andre Bolle <andrebo...@gmail.com> wrote:
>
> Here's what I did. You will notice that the second derivative couldn't see 
> the 'x', which had been replaced by psi.
>
> Yes, that is a “feature” of sympy, which assumes that all symbols that do not 
> have an explicit dependence on the variable of differentiation are constants. 
> Most of the time that works well. You can get around that by specifying that 
> psi is a function of x. See the sympy documentation on functions. I have been 
> fiddling with how to make it take more general derivatives, but need to 
> figure out a definition of an infinitesimal that will function consistently 
> within the sympy environment.

If you're making a custom object, you can redefine various
differentiation methods to make it work correctly with derivatives
(the docs for this aren't great right now, but I hope to improve that
soon).

Aaron Meurer

Aaron Meurer

>
>
> I do like the equation annotation.  (eq1), (eq2), (eq3), etc. Nice.
>
> Glad you like it. I sometimes collapse the code blocks. This then leaves you 
> with the results of each step as might be provided in a traditional 
> derivation. You can also pretty it up with comments in markdown cells between 
> the each step.
>
> Jonathan
>
> --
> 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+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/sympy/615CE6C5-8B01-4ED3-8D3E-3F7E16C1B5D1%40uwosh.edu.

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/CAKgW%3D6%2B0t3c63fvdZWERp_ytO7SVfB2ng_fWy8EiBHH7YnQm7g%40mail.gmail.com.

Reply via email to