cast the objective function as partial displacment

Asked by Bahram

Hi,

I want to cast the objective function as displacement on specific nodes not whole displacement field. now u2 is function of all displacement but for example I just want to solve the optimization problem based on the value of the response on few node
so I don't know how I can change u2 that it only represents the nodes that I want. more specifically, in order to solve my inverse problem i just have the displacement of some sensors in structure not the whole field

my objective function is :
u2 = Function(V)
parameters["adjoint"]["test_derivative"] = True
 solve(a == L, u2, bc)
cc=u2-u_Desiredsolution

J = Functional(inner(cc,cc)*dx)

I will be very thankful if anyone can guide me.
Thanks

Question information

Language:
English Edit question
Status:
Solved
For:
dolfin-adjoint Edit question
Assignee:
No assignee Edit question
Solved by:
Bahram
Solved:
Last query:
Last reply:
Revision history for this message
Simon Funke (simon-funke) said :
#1

If I understand correctly, what you want is to integrate the functional integral only over a subdomain?

If this is correct, then you need to define a dolfin measure (see http://fenicsproject.org/documentation/dolfin/dev/python/demo/pde/subdomains-poisson/python/documentation.html)
and use that in your functional definition, e.g. if you define a measer dxfunc, then you would define the functional as:

J = Functional(inner(cc,cc)*dxfunc)

Revision history for this message
Bahram (behinoo) said :
#2

Thank you very much for your answer.