Derivative functionality #868
Unanswered
TomvanSluijs
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
We want to take the time derivative of a residual by using a chain rule. As shown in the mwe below, we want to take the derivative to the dofs of variable u and multiply by the dofs of the time derivative of u, which is a separate field called dudt. (Also shown in a previous discussion) We want to do this multiple times to obtain the third time derivative of a weak form, as shown in the comments in the script. However, the script does not do exactly what I want. The script gives me this output:
which indicates that the weak form still contains udofs after taking the first derivative. This is shown in the second derivative where we take the derivative to both udofs and dudtdofs, which should only be dudtdofs. I expected the dependency of udofs to disappears after taking the derivative to udofs. The output that I would expect is:
Am I using this function incorrectly or is there some other problem? (In this linear example, I could use the replace function to obtain the result that I need, however, I want to extend this to a non-linear example.)
Best,
Tom
Beta Was this translation helpful? Give feedback.
All reactions