firedrakeproject / tsfc

Two-stage form compiler
Other
15 stars 25 forks source link

Interpolation onto a Vertex Only Mesh (Old) #226

Closed ReubenHill closed 3 years ago

ReubenHill commented 4 years ago

Draft for changes needed to interpolate onto a Vertex Only Mesh from a suitable parent mesh.

Based on top of branch dual_base_fiat - see draft PR #218. Base should change to master when that PR is complete (or if this diverges and stops being dependent on #218).

Linked PRs: https://github.com/firedrakeproject/firedrake/pull/1815 & https://github.com/FInAT/FInAT/pull/66

ReubenHill commented 4 years ago

At time of writing the attempt is to define a runtime tabulated GEM point set using a new FInAT PointSet type inside a suitably defined QuadratureElement but this is liable to change.

Predictably there are issues with tabulation since the FInAT PointSet, which contains a gem.Variable('X', (tdim,)) (where tdim is the topological dimension of the source mesh) as its expression, is translated into a TSFC.fem.PointSetContext which is for compile time known points. I want to make a kernel for run time known points. I presume I ultimately want whatever represents my gem.Variable('X', (tdim,)) to translate to a TSFC.fem.GemPointContext but I'll need to check this.

miklos1 commented 4 years ago

I want to make a kernel for run time known points. I presume I ultimately want whatever represents my gem.Variable('X', (tdim,)) to translate to a TSFC.fem.GemPointContext but I'll need to check this.

Yes, GemPointContext is exactly for evaluations at points that are only known at run-time, while PointSetContext is for compile-time known set of points. However, this was designed with mere point evaluations in mind, how that exactly composes with generic dual evaluation is something I have not thought through.

ReubenHill commented 4 years ago

I want to make a kernel for run time known points. I presume I ultimately want whatever represents my gem.Variable('X', (tdim,)) to translate to a TSFC.fem.GemPointContext but I'll need to check this.

Yes, GemPointContext is exactly for evaluations at points that are only known at run-time, while PointSetContext is for compile-time known set of points. However, this was designed with mere point evaluations in mind, how that exactly composes with generic dual evaluation is something I have not thought through.

Well for this PR at least I will just be doing point evaluations so we should be alright for now. Thanks for the heads up though

ReubenHill commented 3 years ago

Replaced by #247 which is based on top of master

ReubenHill commented 3 years ago

Note to self: there are no unresolved relevant comments to move to #247