Taking the adjoint of a non-linear form
Asked by
Douglas Brinkerhoff
I'd like to get the adjoint of a non-linear Form that is calculated by taking the first variation of a Lagrangian. The problem is that the adjoint() function in FEniCs expects a bilinear form, and the nonlinear form is obviously a vector, since the variables of interest are specified as Functions rather than TrialFunctions. Is there a way to algorithmically replace every instance of a Function (u, say) with a TrialFunction (u_trial, say) in a given Form, such that the form becomes bilinear?
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- DOLFIN Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Douglas Brinkerhoff for more information if necessary.
To post a message you must log in.