This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

efficient way to define convolution

+1 vote

I am wondering if there is an efficient way to define the convolution of two functions in FEniCS. That is, given functions $f$ and $g$, define the function $h=f*g$ by

$$h(x)=\int_\Omega f(x-y)g(y)dy.$$

It should be possible to do this by defining $h$ at each point in the mesh manually, but this method would be extremely time consuming if one has a large 2D or 3D mesh. I am hoping there is a more efficient way of doing it.

asked Nov 3, 2014 by bseguin FEniCS Novice (650 points)

Someone else tried this a while back:
https://answers.launchpad.net/dolfin/+question/141904

Ok. Thanks for letting me know.

1 Answer

0 votes

Take a look at the example in:

https://bitbucket.org/fenics-project/dolfin/issue/413/add-a-demo-of-global-operators-with-semi

and see if you can adapt that approach to your needs.

answered Dec 9, 2014 by martinal FEniCS User (2,800 points)
...