I want to compute streamlines in deal.II after solving a velocity potential equation, so I need to get velocity (gradient of solution) on the point to take the streamline a step forward. Unfortunately, each streamline consists around 2000 points which means it should call `VectorTools::point_gradient` 2000 times. It takes too much time. I search the document but find VectorTools::point_gradient only support searching the point belong to which cell globally.  I think it can be optimized, because if I have got previous point, next point should locate in the same cell or neighbor cells. My question is:

To augment the generic solution Daniel already pointed out, let me mention that Rene Gassmoeller a while ago put a *lot* of work on doing exactly what you are looking for in ASPECT. This work is documented here:
https://www.math.colostate.edu/~bangerth/publications/2016-particles.pdf
A longer version exists here:
https://arxiv.org/abs/1612.03369

The algorithm described in the paper is implemented starting here, in ParticleHandler::sort_particles_into_subdomains_and_cells():
https://github.com/dealii/dealii/blob/master/source/particles/particle_handler.cc#L1299

Best
 W.

--
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 [email protected]
                           www: http://www.math.colostate.edu/~bangerth/

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/e5e6ac01-5bc8-c256-36a6-2aa9dc6e4cb6%40colostate.edu.

Reply via email to