← Back to team overview

libadjoint team mailing list archive

A Functional that does pointwise evaluation

 

Hi all (Marie in particular!)

I want to have a functional J that evaluates the solution u at a certain
point coords. I know I can do

u(coords)

to evaluate the number, but I was wondering if there's a /symbolic UFL
expression/ for that operation? Because I want to use it in a
Functional, so I need to be able to call derivative on it. If I try

derivative(u(coords), u)

it complains of course, because u(coords) is just a float.

I saw your discussion of making a new measure on
https://bugs.launchpad.net/dolfin/+bug/1010850 --
I know there's a PointSource class that creates delta functions; but
how do you actually use it to do an integration?

delta = PointSource(V, Point(0.5))
inner(u, delta)*dx

fails.

Am I missing something obvious?

Patrick


Follow ups