|
Peano
|
Single particle. More...


Public Member Functions | |
| __init__ (self, name) | |
| Constructor. | |
Public Member Functions inherited from peano4.datamodel.DaStGen2.DaStGen2 | |
| configure (self, namespace, association, subdirectory="") | |
| Configure output. | |
| additional_load_and_store_arguments (self) | |
| additional_load_and_store_arguments (self, new_arguments) | |
| hosts_smart_pointer_attribute (self) | |
| Does class host a smart pointer attribute. | |
Public Member Functions inherited from peano4.datamodel.DoF.DoF | |
| get_full_qualified_type (self) | |
| get_logical_type_name (self) | |
| What should the data type be called within the data repository, or within action sets. | |
| get_enumeration_type (self) | |
| What should the data type be called within the data repository. | |
| additional_load_and_store_arguments_for_other_dof (self, argument_name, use_dof_association=None) | |
| You can make Peano's store and load arguments of any DoF depend on other DoFs that you have loaded before. | |
| subnamespace (self) | |
Data Fields | |
| name | |
| partid | |
Data Fields inherited from peano4.datamodel.DaStGen2.DaStGen2 | |
| generator | |
| data | |
| peano4_mpi_and_storage_aspect | |
Data Fields inherited from peano4.datamodel.DoF.DoF | |
| association | |
| name | |
| namespace | |
| subdirectory | |
Additional Inherited Members | |
Static Public Attributes inherited from peano4.datamodel.DaStGen2.DaStGen2 | |
| str | readme_descriptor |
| str | readme_package_descriptor |
Protected Attributes inherited from peano4.datamodel.DaStGen2.DaStGen2 | |
| _additional_load_and_store_arguments | |
Protected Attributes inherited from peano4.datamodel.DoF.DoF | |
| _additional_load_and_store_arguments | |
Single particle.
Represent a single particle. This is a DaStGen2 wrapper, i.e. I define a DaStGen object and add some particular fields that I always need to administer the particles.
If you use these particles, please do not add them to your use definitions of the actions/observers. For pidt, you need a second ParticleSet and this one is used by the observers.
You have to add the particle to your project though via
my_project.add_global_object
If you want to attributes to a particle, use the data subattribute. An all-time classic is the call
add_attribute( peano4.dastgen2.Peano4DoubleArray("v","Dimensions") )
I actually need only very few fields in Peano's particle toolbox:
The only action set that should alter the state is UpdateParallelState.
If a particle moves, we have to update its state, and we might have to update its vertex association. This discussion focuses on the state update.
Details can be found in UpdateParallelState.
If any debug level is active, each particle carries a unique identifier.
Particles in Peano are typically stored in the vertex next to them. This is the pidt (paricle in dual tree) technique referenced in the Readme.md file that's automatically generated when you use the particle toolbox.
In the illustration below, the blue paricle is associated to the vertex left above it, the red one belongs to the vertex right of it.
The logical information where the "owning" vertex of a particle is is easy to compute at any time from the geometric context. However, we found that this recomputation is quickly becoming excessively expensive. Therefore, we add the field
to the data model which encodes this information. It is to be set properly by the particle sorting algorithm in use.
In the example above, the bitfield would hold 010 (read from right to left) for the blue particle and 0100 for the red one. The code is read from the vertex's point of view: If we look at the centre vertex and study the position of particle, it is not in the left bottom adjacent cell. It is however in the right bottom adjacent cell. So we use a lexicographic enumeration of the adjacent cells.
As the position of a particle within cells is not unique if a particle resides exactly on the face between two cells, the bitfield can hold more than one entry.
Definition at line 10 of file Particle.py.
| peano4.toolbox.particles.Particle.Particle.__init__ | ( | self, | |
| name ) |
Constructor.
name: String Name of the particle. Has to be a valid C++ class name. We pass this to the superclass as fully qualified name
Reimplemented from peano4.datamodel.DaStGen2.DaStGen2.
Reimplemented in swift2.particle.tests.testLeapfrogFixedTimeStepSize.testLeapfrogFixedTimeStepSize, swift2.particle.ExplicitEulerFixedSearchRadius.ExplicitEulerFixedSearchRadius, swift2.particle.LeapfrogFixedSearchRadius.LeapfrogFixedSearchRadius, swift2.particle.tests.DisappearingParticleTest.DisappearingParticleTest, swift2.particle.ExplicitEulerDynamicSearchRadius.ExplicitEulerDynamicSearchRadius, swift2.particle.tests.testDensityCalculation.testDensityCalculation, swift2.particle.SPHLeapfrogFixedSearchRadius.SPHLeapfrogFixedSearchRadius, swift2.particle.SPHParticle.SPHParticle, swift2.particle.Particle.Particle, and swift2.particle.tests.DastgenTestDummyParticle.DastgenTestDummyParticle.
Definition at line 112 of file Particle.py.
| peano4.toolbox.particles.Particle.Particle.name |
Definition at line 126 of file Particle.py.
Referenced by exahype2.solvers.aderdg.kernels.Gemms.Gemms.__repr__(), swift2.particle.ExplicitEulerFixedSearchRadius.ExplicitEulerFixedSearchRadius.__setup_algorithm_steps(), swift2.particle.AlgorithmStep.AlgorithmStep.__str__(), swift2.particle.LeapfrogFixedSearchRadius.LeapfrogFixedSearchRadius._setup_algorithm_steps_dict(), peano4.datamodel.DoF.DoF.additional_load_and_store_arguments_for_other_dof(), swift2.particle.ExplicitEulerDynamicSearchRadius.ExplicitEulerDynamicSearchRadius.algorithm_steps(), swift2.particle.tests.DastgenTestDummyParticle.DastgenTestDummyParticle.algorithm_steps(), peano4.solversteps.UserActionSet.UserActionSet.get_action_set_name(), peano4.datamodel.DoF.DoF.get_full_qualified_type(), peano4.datamodel.DoF.DoF.get_logical_type_name(), dastgen2.attributes.Enumeration.Enumeration.get_to_string(), and swift2.particle.Particle.Particle.readme_descriptor().
| peano4.toolbox.particles.Particle.Particle.partid |
Definition at line 128 of file Particle.py.