spis.Top.Simulation
Class SimulationFromUIParams

java.lang.Object
  extended byspis.Top.Simulation.Simulation
      extended byspis.Top.Simulation.PlasmaScSimulation
          extended byspis.Top.Simulation.SimulationFromUIParams

public class SimulationFromUIParams
extends PlasmaScSimulation

Class Name : Simulation (generic Simulation class)
Project ref : SPIS project
File name : Simulation.java
File type : class
Copyright : ONERA, 2 Av. E. Belin, 31055 Toulouse cedex, France http://www.onecert.fr
Status : under development
Creation : 25/04/2003
Modification :

Description : Simulation class, based on UI-defined parameters.
This is the class called by SPIS framework (JyTop4.py).

Versions and anomalies correction :

Version numberAuthor (name, e-mail) Corrections/Modifications
0.1 JF Roussel, roussel@onecert.frCreation


Version:
0.1
Author:
JF Roussel

Field Summary
private  ScalSurfField collectedCurrent
          collected current on SC
private  int electricCircuitIntegrate
          electric circuit integration flag
private  ScalSurfField emittedCurrent
          emitted current from SC
private  Environment environment
          UI-defined environement
private  ElecSuperNodeMonitor esnMonitor
          monitor for data on electric super nodes
private  FieldMonitor fieldMonitor
          monitor for surface and volume fields
private  float initPot
          global initial potential
private  int initPotFlag
          flag for potential initialisation
private  LocalParameter[] localParameters
          Local parameters (material type...)
private  ScalSurfField netCurrent
          net current onto SC
private  float particleTrajectoriesNb
          number of particle trajectories per PIC population
 
Fields inherited from class spis.Top.Simulation.PlasmaScSimulation
bdSurfMesh, plasma, sc, scSurfMesh, volMesh
 
Fields inherited from class spis.Top.Simulation.Simulation
results
 
Constructor Summary
SimulationFromUIParams(ThreeDUnstructVolMesh vm, ThreeDUnstructSurfMesh bsm, ThreeDUnstructSurfMesh scsm, GlobalParameter[] globalParameters, LocalParameter[] localParameters_)
          Default constructor
SimulationFromUIParams(ThreeDUnstructVolMesh vm, ThreeDUnstructSurfMesh bsm, ThreeDUnstructSurfMesh scsm, GlobalParameter[] globalParameters, LocalParameter[] localParameters_, java.lang.String outPath)
          Constructor with the default output path to write files
SimulationFromUIParams(ThreeDUnstructVolMesh vm, ThreeDUnstructSurfMesh bsm, ThreeDUnstructSurfMesh scsm, GlobalParameter[] globalParameters, LocalParameter[] localParameters_, java.lang.String outPath, java.lang.String inPath)
          Constructor with the default output and input path to write/read files
 
Method Summary
private  void addData(java.lang.Object data, java.lang.String name, float t)
          Stores data for postprocessing
private  ScalSurfField computeRnOverR2()
          Computes and returns r.n/(r.r), where r is the vector field of bd mesh surface positions (centres) with origin the SC mesh barycentre, and n is the vector field of the (outgoing) normals to the external boundary mesh.
 void init()
          Initialisation: build objects for the simulation (SC, plasma...).
 void integrate()
          Time integration of of the SC-plasma dynamics over the UI-defined duration t
 void integrate(float duration)
          Time integration of the SC-plasma dynamics over the duration t
 
Methods inherited from class spis.Top.Simulation.PlasmaScSimulation
getBdSurfResults, getCurveTimePlots, getMFPlasma, getRCCabsSC, getScSurfResults, getTrajectories, getVolResults, selectSurfResults, setPlasma, setSC
 
Methods inherited from class spis.Top.Simulation.Simulation
exportUIData, getBdSurfMesh, getGlobalParameters, getResults, getScalTimePlots, getScSurfMesh, getVolMesh, importUIData, selectResults, setBdSurfMesh, setDefaultInputPath, setDefaultOutputPath, setDefaultPaths, setGlobalParameters, setResults, setScSurfMesh, setVolMesh
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

localParameters

private LocalParameter[] localParameters
Local parameters (material type...)


environment

private Environment environment
UI-defined environement


fieldMonitor

private FieldMonitor fieldMonitor
monitor for surface and volume fields


esnMonitor

private ElecSuperNodeMonitor esnMonitor
monitor for data on electric super nodes


particleTrajectoriesNb

private float particleTrajectoriesNb
number of particle trajectories per PIC population


electricCircuitIntegrate

private int electricCircuitIntegrate
electric circuit integration flag


initPotFlag

private int initPotFlag
flag for potential initialisation


initPot

private float initPot
global initial potential


collectedCurrent

private ScalSurfField collectedCurrent
collected current on SC


emittedCurrent

private ScalSurfField emittedCurrent
emitted current from SC


netCurrent

private ScalSurfField netCurrent
net current onto SC

Constructor Detail

SimulationFromUIParams

public SimulationFromUIParams(ThreeDUnstructVolMesh vm,
                              ThreeDUnstructSurfMesh bsm,
                              ThreeDUnstructSurfMesh scsm,
                              GlobalParameter[] globalParameters,
                              LocalParameter[] localParameters_)
Default constructor

Parameters:
vm - - the volume mesh
bsm - - the external boundary surface mesh
scsm - - the spacecraft surface mesh
globalParameters - - the global parameters coming from UI
localParameters_ - - the local parameters coming from UI

SimulationFromUIParams

public SimulationFromUIParams(ThreeDUnstructVolMesh vm,
                              ThreeDUnstructSurfMesh bsm,
                              ThreeDUnstructSurfMesh scsm,
                              GlobalParameter[] globalParameters,
                              LocalParameter[] localParameters_,
                              java.lang.String outPath)
Constructor with the default output path to write files

Parameters:
vm - - the volume mesh
bsm - - the external boundary surface mesh
scsm - - the spacecraft surface mesh
globalParameters - - the global parameters coming from UI
localParameters_ - - the local parameters coming from UI
outPath - - path of the directory where to write files

SimulationFromUIParams

public SimulationFromUIParams(ThreeDUnstructVolMesh vm,
                              ThreeDUnstructSurfMesh bsm,
                              ThreeDUnstructSurfMesh scsm,
                              GlobalParameter[] globalParameters,
                              LocalParameter[] localParameters_,
                              java.lang.String outPath,
                              java.lang.String inPath)
Constructor with the default output and input path to write/read files

Parameters:
vm - - the volume mesh
bsm - - the external boundary surface mesh
scsm - - the spacecraft surface mesh
globalParameters - - the global parameters coming from UI
localParameters_ - - the local parameters coming from UI
outPath - - path of the directory where to write files
inPath - - path of the directory where to read files from
Method Detail

init

public void init()
Initialisation: build objects for the simulation (SC, plasma...). Called by the constructor.
Note for debugging: although this initialisation is called by the SimulationFromUIParams constructor, local and global parameters (including meshes) are serialised in the constructor before this call. Hence in case of a bug in this init(), the serialed parameters can be read again in a debbugger (as Eclipse) and init be invoked again in the debugger at construction time of SimulationFromUIParams.


integrate

public void integrate(float duration)
Time integration of the SC-plasma dynamics over the duration t

Specified by:
integrate in class Simulation

addData

private void addData(java.lang.Object data,
                     java.lang.String name,
                     float t)
Stores data for postprocessing

Parameters:
data -
name -
t - time of creation of this data

integrate

public void integrate()
Time integration of of the SC-plasma dynamics over the UI-defined duration t


computeRnOverR2

private ScalSurfField computeRnOverR2()
Computes and returns r.n/(r.r), where r is the vector field of bd mesh surface positions (centres) with origin the SC mesh barycentre, and n is the vector field of the (outgoing) normals to the external boundary mesh.
This is used to compute Fourier local alpha parameter mimicking r^-n decay.

Returns: