gov.sns.xal.model.probe
Class EnsembleProbe

java.lang.Object
  |
  +--gov.sns.xal.model.probe.Probe
        |
        +--gov.sns.xal.model.probe.BeamProbe
              |
              +--gov.sns.xal.model.probe.EnsembleProbe
All Implemented Interfaces:
IArchive, IProbe

public class EnsembleProbe
extends BeamProbe

Represents an ensemble of particles. This IProbe type maintains an Ensemble object which is a collection of Particles. Thus, this probe designed for muli-particle simulation.


Field Summary
static int FLDCALC_GRIDFD
          use grid finite difference scheme
static int FLDCALC_GRIDFT
          use grid Fourier transform method
static int FLDCALC_NONE
          no field calculation scheme specified
static int FLDCALC_SUMMATION
          use a full potential summation of each particle
 
Fields inherited from class gov.sns.xal.model.probe.Probe
PROBE_LABEL
 
Fields inherited from interface gov.sns.xal.model.IProbe
LightSpeed, Permittivity, UnitCharge
 
Constructor Summary
EnsembleProbe()
          Creates a new (empty) instance of EnsembleProbe
EnsembleProbe(EnsembleProbe probe)
          Copy Constructor.
 
Method Summary
 void applyState(ProbeState state)
          Apply the contents of ProbeState to update my current state.
 ProbeState createProbeState()
          Creates a state snapshot of this probe's state and returns it as a ProbeState object.
 Trajectory createTrajectory()
          Creates a trajectory of the proper type for saving the probe's history.
 R3 electricField(R3 ptFld)
          Get the electric field at a point in R3 from the ensemble.
 Ensemble getEnsemble()
          Return the Ensemble state object
 int getFieldCalculation()
          Return the field calculation method
 CorrelationMatrix phaseCorrelation()
          Return the correlation matrix of the distribution
 PhaseVector phaseMean()
          Return the coordinates of the ensemble centroid.
 void setEnsemble(Ensemble ens)
          Set the EnsembleProbe state to the value of the argument NOTE: the copy operation can be expansive for large Ensembles
 void setFieldCalculation(int enmFldCalc)
          Set the field calculation method
 
Methods inherited from class gov.sns.xal.model.probe.BeamProbe
beamPerveance, getBeamCharge, getBeamCurrent, phaseCovariance, setBeamCharge, setBeamCurrent
 
Methods inherited from class gov.sns.xal.model.probe.Probe
computeBetaFromGamma, computeGammaFromBeta, computeGammaFromW, deepCopyProbeBase, getAlgorithm, getArchive, getBeta, getBetaGamma, getComment, getCurrentElement, getGamma, getKineticEnergy, getPosition, getSpeciesCharge, getSpeciesRestEnergy, getTime, getTimestamp, getTrajectory, initialize, load, newProbeInitializedFrom, readFrom, reset, save, setAlgorithm, setComment, setCurrentElement, setKineticEnergy, setPosition, setSpeciesCharge, setSpeciesRestEnergy, setTime, setTimestamp, setTracking, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

FLDCALC_NONE

public static final int FLDCALC_NONE
no field calculation scheme specified

See Also:
Constant Field Values

FLDCALC_SUMMATION

public static final int FLDCALC_SUMMATION
use a full potential summation of each particle

See Also:
Constant Field Values

FLDCALC_GRIDFD

public static final int FLDCALC_GRIDFD
use grid finite difference scheme

See Also:
Constant Field Values

FLDCALC_GRIDFT

public static final int FLDCALC_GRIDFT
use grid Fourier transform method

See Also:
Constant Field Values
Constructor Detail

EnsembleProbe

public EnsembleProbe()
Creates a new (empty) instance of EnsembleProbe


EnsembleProbe

public EnsembleProbe(EnsembleProbe probe)
Copy Constructor. Create a new instance of EnsembleProbe which is a deep copy of the argument NOTE: the copy operation can be expansive for large Ensembles

Parameters:
probe - object to be copied
Method Detail

createProbeState

public ProbeState createProbeState()
Creates a state snapshot of this probe's state and returns it as a ProbeState object.

Specified by:
createProbeState in class Probe
Returns:
a EnsembleProbeState encapsulating the probe's current state

createTrajectory

public Trajectory createTrajectory()
Creates a trajectory of the proper type for saving the probe's history.

Specified by:
createTrajectory in class Probe
Returns:
a new, empty EnsembleTrajectory for saving the probe's history

phaseMean

public PhaseVector phaseMean()
Return the coordinates of the ensemble centroid.

Overrides:
phaseMean in class BeamProbe
Returns:
(homogeneous) phase space coordinates of ensemble centroid

phaseCorrelation

public CorrelationMatrix phaseCorrelation()
Return the correlation matrix of the distribution

Specified by:
phaseCorrelation in class BeamProbe
Returns:
symmetric 7x7 covariance matrix in homogeneous coordinates
See Also:
PhaseMatrix

setFieldCalculation

public void setFieldCalculation(int enmFldCalc)
Set the field calculation method

Parameters:
enmFldCalc - field calculation method enumeration

setEnsemble

public void setEnsemble(Ensemble ens)
Set the EnsembleProbe state to the value of the argument NOTE: the copy operation can be expansive for large Ensembles

Parameters:
ens - Ensemble object to be copied

getFieldCalculation

public int getFieldCalculation()
Return the field calculation method


getEnsemble

public Ensemble getEnsemble()
Return the Ensemble state object


electricField

public R3 electricField(R3 ptFld)
Get the electric field at a point in R3 from the ensemble.

Parameters:
ptFld - field point to evaluation ensemble field
Returns:
electric field at field point

applyState

public void applyState(ProbeState state)
Apply the contents of ProbeState to update my current state. The argument supplying the new state should be of concrete type EnsembleProbeState.

Overrides:
applyState in class BeamProbe
Parameters:
state - ProbeState object containing new probe state data
Throws:
java.lang.IllegalArgumentException - wrong ProbeState subtype for this probe