Public Member Functions |
| Species () |
| Default constructor.
|
virtual | ~Species () |
| Destructor.
|
virtual void | Init () |
| Get the pointer to the Wall and Geometry and un-normalize all the parameters. Initialize the particle density grid.
|
virtual bool | Execute () |
| Executes the Task. This is the place where the algorithm for executing a Task it placed. The return value specifies, if the task is finished and can be removed. The basic Execute method executes all its sub-Tasks. The derived classes should call this member function, whenever there are subtasks to be executed.
|
void | MakeRho () |
| Weight all the particles onto the density grid. Only needs to be executed when particles have moved.
|
double | GetSize () const |
| Return the size of the superparticles.
|
double | GetSize0 () const |
| Return the initial size of the superparticles.
|
double | GetCharge () const |
| Return the Charge.
|
double | GetMass () const |
| Return the Mass.
|
double | Getdt () const |
| Return the time step.
|
grid< double > & | Rho () |
| Return a reference to the density grid.
|
double | Vabs (int p) const |
| Return the absolute velocity of particle number p.
|
void | SetV (int p, const Velocity &_V) |
| Set the velocity of particle p to _V.
|
Position | GetRx (int nParticle) const |
| Returns the position of particle nParticle.
|
void | SetMovedFlag () |
| Set the Moved flag to true.
|
void | ClearMovedFlag () |
| Set the Moved flag to false.
|
bool | HasMoved () const |
| Return if particles have moved.
|
int | Generate (Position aX, Velocity aV) |
void | Remove (int nP) |
void | Swap (int i1, int i2) |
void | ModifySize (double densityContribution) |
| Modify the size of the particles. This modifies the size of the simulation particles given the contribution of a particle creator and the total number of particles. This can be called more than once. The density contributions are summed up and after the last call the particle size reflects the valid size of the superparticles. This method is particularly important in electrostatic simulations to prevent an overall charge density in the system.
|
virtual std::string | GetClassName () const |
| returns the name of the class, here "Species".
|
| Task () |
| Default constructor sets the running number nNr of the Task.
|
virtual | ~Task () |
| When destructing a Task is has to be detatched from the parents Task list.
|
int | GetStep () const |
| Return the interval between execution in timesteps.
|
int | GetEnd () const |
| Return the timestep when the Task ends execution.
|
bool | DoNow () |
| Returns true if the Task is to be executed now.
|
std::string | GetName () const |
| Returns the name given to the Task object.
|
virtual bool | IsInteractive () const |
| If not specified otherwise, a Task is not interactive.
|
void | AttachTask (Task *pTask) |
| Insert Task into Task list and registers it with the Process.
|
void | DetachTask (Task *pTask) |
| DetachTask from Task list.
|
virtual std::string | Rebuild (std::istream &in) |
| Rebuilds the task from the setup. This normally does not need to be overwritten. Rebuild always returns the next token that does not belong to the object setup.
|
virtual void | DumpTaskList (std::ostream &o, int nDepth=0) |
| Recursively dumps the complete Task list into a stream.
|
This class implements an individual particle species. A Species class contains all the positions and velocities of a particle species. It also contains direct links to a Wall Object and a grid containing the particle density. Normally a species will contain at least a Movement sub-Task and either a Generation sub-Task or some Task that will create particles during run time.
- Parameters:
-
dt | The normalized timestep |
mass | The normalized mass of the particle |
charge | The normalized charge of the particle |
size | The size of the superparticles |
maxn | The maximum number of super particles |
density | Name of the referenced Density |
wall | Name of the reference Wall |
movement | Allows creation of sub-Task Movement |
ed_movement | Allows creation of sub-Task RelEDMovement |
ionization | Allows creation of sub-Task Ionization |
homogen_setup | Allows creation of sub-Task StartHomogen |
two_stream_setup | Allows creation of sub-Task StartTwoStream |
shock_setup | Allows creation of sub-Task StartUniformShock |
file_setup | Allows creation of sub-Task StartFile |
phasespace | Allows creation of diagnostic sub-Task PhaseSpace |
particlecount | Allows creation of diagnostic sub-Task plotting the number of particles |
geometry | Name of the reference Geometry |