ComputationalRadiationPhysics / picongpu

Performance-Portable Particle-in-Cell Simulations for the Exascale Era :sparkles:
https://picongpu.readthedocs.io
Other
710 stars 218 forks source link

High-Level P3M Algorithms: Caching & Execution Templates #1439

Open ax3l opened 8 years ago

ax3l commented 8 years ago

We should provide general "algorithmic templates" for general particle-mesh & particle-particle(-particle) algorithms in PMacc.

The idea behind this is, that our currently implemented PIC methods are still only particle-mesh methods, but we are planning to enhance them a lot by particle-particle(-particle/mesh) interactions that can be used for

When developers implement those methods, we should already have a set of algorithms accepting functors of the form f_pp(particle1, particle2), f_ppp(...), f_pm(particle, gridpoint), f_mp(...) ready so the caching, execution order, range-selection and streaming operations can be re-used. This also applies to the methods we already implemented (Field2ParticleInterpolation, CurrentDeposition, FieldTmp, CreateGas, all general concepts behind the functors in speciesInitilization) which a PM methods and should be isolated in the same manner (if you have a look at FieldTmp solvers, there is already an attempt to do so; speciesInitilization.param/particleManipulators is a great example, too - but we need to get them generalized)

I choose the term algorithm in analogy to STL algorithms such as for_each, transform (map), generate, "do"_if ... but you have to imagine that they operate on two ranges at the same time (e.g., two particle lists of frames, a list of cells and a list of particles, ...).

A side note: when talking about P3M we do not necessarily need an "actual NxN" algorithm above all global particles as in a "true" MD simulation. What we need are spatially-cut "n x n" algorithms (note the small n << N) that can be used to model the neglected short-range interactions. For efficient scaling, we will at least in PIConGPU base on the particle-mesh interaction which already covers that.

This is a requirement to implement (the above mentioned methods)

efficiently.

ccing @erikzenker @psychocoderHPC

bussmann commented 8 years ago

THIS is EXTREMELY important!

psychocoderHPC commented 8 years ago

A dependency to implement this algorithms we need first to implement issue #1441