Package xal.model.probe
Class TwissProbe
EnvelopeProbe represents the RMS beam envelopes of a beam.
Specifically, the state of this probe is the 7x7 matrix of homogeneous phase
space moments up to, and including second order. This is the correlation
matrix for the beam and is represented as
χ = <
zzT>
where z =(x,x',y,y',z,z',1) is the vector of homogeneous
phase space coordinates, and <.> is the moment operator with respect to
the beam distribution.
- Author:
- Christopher K. Allen, Craig McChesney
-
Field Summary
Fields inherited from class xal.model.probe.Probe
COMMENT_LABEL, PROBE_LABEL, stateCurrent, TEXT_LABEL, TIME_LABEL, trajHist, TYPE_LABELFields inherited from interface xal.model.IProbe
LIGHT_SPEED, PERMITTIVITY, UNIT_CHARGE -
Constructor Summary
ConstructorsConstructorDescriptionDefault Constructor.TwissProbe(TwissProbe prbParent) Copy constructor - clones the argumentTwissProbe(DataAdaptor daSource) Initializing constructor - initialize from data adaptor Create an newTwissProbeobject and initialize its state variables according to the data in the data source exposing theDataAdaptorinterface. -
Method Summary
Modifier and TypeMethodDescriptioncopy()Make a deep copy of this probe and return it.Creates a new, emptyTwissProbeState.Creates a snapshot of the current state and returns it as aProbeStateobject of the proper type.Creates aTrajectory<TwissProbeState>object of the proper type for saving the probe's history.Returns the betatron phase with space charge for all three phase planes.Get the centroid location of the beam bunch in homogeneous coordinates.Get the first-order response matrix accumulated by the probe since its initial state.getTwiss()Returns the array of Twiss parameters for this state for all three planes.getTwiss(Twiss3D.IND_3D iPlane) Returns the Twiss parameters for the given phase plane.protected voidinitializeFrom(Probe<TwissProbeState> probe) Deprecated.Never usedprotected TwissProbeStatereadStateFrom(DataAdaptor container) Creates a newTwissProbeStateobject and initializes it from the data source exposing the givenDataAdaptorinterface.double[]Convenience Method: Returns the rms emittances for this state as from the individual Twiss parameters.voidsetBetatronPhase(R3 vecPhase) Set the betatron phase for each phase plane.voidsetCentroid(PhaseVector vecCentroid) Set the centroid location of the beam bunch in homogeneous coordinates.voidsetResponseMatrix(PhaseMatrix matResp) Set the first-order response matrix accumulated by the Envelope since its initial state.voidSet all the twiss parameters for the probevoidsetTwiss(Twiss3D.IND_3D iPlane, Twiss twiss) Set the Twiss parameters for the given phase plane.Methods inherited from class xal.model.probe.BunchProbe
beamDCPerveance, beamPerveance, bunchCharge, getBeamCurrent, getBunchFrequency, setBeamCurrent, setBunchFrequencyMethods inherited from class xal.model.probe.Probe
applyState, cloneCurrentProbeState, deepCopy, getAlgorithm, getArchive, getBeta, getComment, getCurrentElement, getCurrentElementTypeId, getCurrentHardwareId, getCurrentState, getGamma, getInitialState, getKineticEnergy, getLongitinalPhase, getMomentum, getPosition, getSpeciesCharge, getSpeciesName, getSpeciesRestEnergy, getTime, getTimestamp, getTrajectory, initialize, load, lookupLastStateFor, newProbeInitializedFrom, performPostProcessing, readFrom, reset, save, setAlgorithm, setComment, setCurrentElement, setCurrentElementTypeId, setCurrentHardwareId, setKineticEnergy, setLongitudinalPhase, setPosition, setSpeciesCharge, setSpeciesName, setSpeciesRestEnergy, setTime, setTimestamp, setTracking, update
-
Constructor Details
-
TwissProbe
public TwissProbe()Default Constructor. Creates a new, empty instance of TwissProbe -
TwissProbe
Copy constructor - clones the argument- Parameters:
prbParent-TwissProbeobject to be cloned
-
TwissProbe
Initializing constructor - initialize from data adaptor Create an newTwissProbeobject and initialize its state variables according to the data in the data source exposing theDataAdaptorinterface.- Parameters:
daSource- data source containing state variable values- Throws:
DataFormatException- unable to parse, bad data format
-
-
Method Details
-
initializeFrom
Deprecated.Never usedInitialize this probe from the one specified.- Overrides:
initializeFromin classProbe<TwissProbeState>- Parameters:
probe- to copy
-
copy
Make a deep copy of this probe and return it.- Specified by:
copyin classProbe<TwissProbeState>- Returns:
- a clone of this probe object
- Since:
- Nov 5, 2013
- See Also:
-
setCentroid
Set the centroid location of the beam bunch in homogeneous coordinates.- Parameters:
vecCentroid- new centroid of the bunch (x,x',y,y',z,z',1)
-
setResponseMatrix
Set the first-order response matrix accumulated by the Envelope since its initial state. Note that this response includes the effects of space charge.- Parameters:
matResp- first-order response matrix in homogeneous coordinates
-
setBetatronPhase
Set the betatron phase for each phase plane.- Parameters:
vecPhase- vector (ψx,ψy,ψz) of betatron phases in radians
-
setTwiss
Set the Twiss parameters for the given phase plane.- Parameters:
iPlane- phase plane indextwiss- twiss parameters
-
setTwiss
Set all the twiss parameters for the probe- Parameters:
envTwiss- new 3 dimensional array of Twiss objects (hor, vert,long)- See Also:
-
getCentroid
Get the centroid location of the beam bunch in homogeneous coordinates.- Returns:
- centroid of the bunch (x,x',y,y',z,z',1)
-
getResponseMatrix
Get the first-order response matrix accumulated by the probe since its initial state.- Returns:
- first-order response matrix in homogeneous coordinates
-
getBetatronPhase
Returns the betatron phase with space charge for all three phase planes.- Returns:
- vector (ψx,ψy,ψz) of betatron phases in radians
-
getTwiss
Returns the Twiss parameters for the given phase plane.- Parameters:
iPlane- phase plane index- Returns:
- twiss parameters for given phase plane
-
getTwiss
Returns the array of Twiss parameters for this state for all three planes.- Returns:
- array(twiss-H, twiss-V, twiss-L)
-
rmsEmittances
public double[] rmsEmittances()Convenience Method: Returns the rms emittances for this state as from the individual Twiss parameters.- Returns:
- array (ex,ey,ez) of rms emittances
-
createProbeState
Creates a snapshot of the current state and returns it as aProbeStateobject of the proper type.- Specified by:
createProbeStatein classBunchProbe<TwissProbeState>- Returns:
- a new
TwissProbeStateencapsulating the probe's current state - See Also:
-
createEmptyProbeState
Creates a new, emptyTwissProbeState.- Specified by:
createEmptyProbeStatein classBunchProbe<TwissProbeState>- Returns:
- a new, empty
TwissProbeState - Since:
- Jul 1, 2014
-
createTrajectory
Creates aTrajectory<TwissProbeState>object of the proper type for saving the probe's history.- Specified by:
createTrajectoryin classProbe<TwissProbeState>- Returns:
- a new, empty
Trajectory<TwissProbeState>for saving the probe's history
-
readStateFrom
Creates a newTwissProbeStateobject and initializes it from the data source exposing the givenDataAdaptorinterface.- Specified by:
readStateFromin classProbe<TwissProbeState>- Parameters:
container-DataAdaptorto read a Trajectory from- Returns:
- the newly instantiated and initialized
TwissProbeStateobject - Throws:
DataFormatException- error encountered reading the DataAdaptor- Since:
- Nov 5, 2013
- See Also:
-