Thread Previous • Date Previous • Date Next • Thread Next |
On 12/04/10 21:49, Anders Logg wrote:
On Mon, Apr 12, 2010 at 09:34:38PM +0800, Garth N. Wells wrote:On 12/04/10 21:29, Anders Logg wrote:On Mon, Apr 12, 2010 at 09:21:32PM +0800, Garth N. Wells wrote:On 12/04/10 21:19, Garth N. Wells wrote:On 12/04/10 20:47, Anders Logg wrote:We are doing some work where we need to do run-time quadrature over arbitrary polyhedra.We (Mehdi and I) do this already (using UFC), so I don't see why a new function is required. Can you explain why evaluate_tensor is not enough?I meant 'tabulate_tensor'.Which function do you call for evaluating the integrand?We evaluate it inside ufc::tabulate_tensor. We construct our forms with an extra argument, say an object "CutCellIntegrator", which can provide quadrature schemes which depend on the considered cell.That would require a special purpose code generator.
What's wrong with that? FFC won't (and shouldn't) be able to do everything. Just adding a function to UFC won't make FFC do what we do now. We reuse FFC (import modules) and add special purpose extensions.
Having evaluate_integrand would allow more flexibility for users to implement their own special quadrature scheme.
We make "CutCellIntegrator" an abstract base class, so the user has *complete* freedom to define the quadrature scheme and the generated code does not depend on the scheme, since the scheme may depend on things like how the cell 'cut' is represented.
I also don't understand how it can work at all since the quadrature points are not known at compile-time. Or do you a fixed set of reference polyhedra that you map to?
The "CutCellIntegrator" object is asked for the quadrature points, and it returns them. One way to do it is to sub-triangulate polyhedra (I think that CGAL can do this). "CutCellIntegrator" would usually be aware of intersecting surfaces, etc. It can also return schemes on surfaces.
I would like a quadrature generator on polyhedra to eventually be part of DOLFIN.
Garth
-- Anders
Thread Previous • Date Previous • Date Next • Thread Next |