Package xal.tools.beam.calc
Introduction
This package contains classes that perform common processing tasks for simulation data produced by the online model. Such data is contained in aTrajectory
object where the
template parameter indicates the type of simulation that was run (i.e.,
single particle, transfer map calculation, RMS envelope simulation, etc.).
The available processing options depend upon the type of simulation data
contained in a trajectory object. For example, computation of Courant-Snyder
parameters for a single particle simulation has no meaning. Thus, the class
that processes single particle simulation data,
CalculationsOnParticles
, has no methods for such a
calculation.
There are, however, methods with the same name in difference processing
classes and it is important to point out that the results of these
computations depend upon context. For example, the method
CalculationsOnMachines.computeFixedOrbit(xal.model.probe.traj.TransferMapState)
does not return the same quantity as
.
In the former the expected quantity is computed, the position of the closed
orbit at the given state location. In the later, the location of the particle
at the state location is returned. This admittedly ambiguous situation is the
result of a implementation requirement that the various processing classes
expose common interfaces for providing computed parameters from the
simulation data. The consumers of this data are assumed to know the context
of the returned parameters based upon the simulation data they provide.
CalculationsOnParticles.computeFixedOrbit(xal.model.probe.traj.ParticleProbeState)
Interfaces
There are two interfaces exposed by the processing classes in this package, both of them contained in the parent interfaceISimulationResults
. The first is
{@link ISimLocResults<>}
which exposes methods involved in the
computation of points or locations in phase space. The second is
{@link ISimEnvResults<>}
which exposes methods that are
concerned with the computation of beam properties, such as Courant-Snyder
parameters, betatron phase of the envelope, and chromatic dispersion within
the bunch. See the Javadoc for each interface for a more complete description
of the expected quantities.
Calculation Engines
There are 4 classes that produce finished information from simulation data. There is an additional base class,CalculationEngine
,
which provides common operations for the above concrete classes. Each
computational engine class exposes at least one of the above interfaces,
depending upon their function. A class may also provide additional methods
which are appropriate to their context. The computation classes and their
function are listed below
CalculationsOnParticles
: Provides processing
functions appropriate for single particle simulation data. Also has methods
available for processing data that was taken for a periodic system between
two period locations. The simulation data is of type
Trajectory<ParticleProbeState>
.
CalculationsOnMachines
: This class is concerned
with the calculation of machine properties without regard to any beam
propagation. The simulation data is of type
Trajectory<TransferMapState>
.
CalculationsOnRings
: Computes ring properties
and parameters. This class is a super class of
CalculationsOnMachines
, since a ring is a machine. Consequently
the simulation data is also of type
Trajectory<TransferMapState>
. However, it is necessary
that the simulation data be produced by a machine with the topology of a ring
for the calculations to have context.
CalculationsOnBeams
: Computes parameters for a
beam itself. These include collective properties of a beam bunch. The
simulation data for this class is of type
Trajectory<EnvelopeProbeState>
.
Of the 4 classes only 2 operate on the same simulation data type,
CalculationsOnMachines
and CalculationsOnRings
.
Convenience Classes
There are two additional convenience classes within the package,SimResultsAdaptor
and SimpleSimResultsAdaptor
. The
function of SimResultsAdaptor
is to expose both the above
interfaces but where the underlying computation engine used depends upon the
type of simulation data provided. After creating the class the developer
specifies which computational engine is to be used with which data. The class
SimpleSimResultsAdaptor
defines these computation engines a
priori. The CalculationsOnRings
class is used for
simulation data of type Trajectory<TransferMapState>
,
CalculationsOnParticles
is used for type
Trajectory<ParticleProbeState>
, and
CalculationsOnBeams
is used for type
Trajectory<EnvelopeProbeState>
.
- Since:
- Sep 25, 2014
- Version:
- Sep 25, 2014
- Author:
- Christopher K. Allen
-
ClassDescriptionClass
CalculationEngine
performs all the common numerical calculation when computing machine parameters from simulation data.Class for performing calculations on data obtained from simulating linacs and beam transport systems.Class for performing the calculations expressed in theISimEnvResults
interface in the context of a particle beam system without regard to the particle.Provides processing functions appropriate for single particle simulation data.Class for computing ring parameters from simulation data.Encapsulates base for any interfaces that processes simulation data.Processes simulation data concerned with the beam properties.This interface defines methods for computation results that are in the form of points, or locations, in phase space.This class reduces the general operation of the base classSimResultsAdaptor
to the specific use of the calculation engine
for simulation data of typeCalculationsOnRings
TransferMapTrajectory
, and use of calculation engine
for simulation data of typeCalculationsOnBeams
EnvelopeTrajectory
.This class allows the developer to dynamically choose which calculation engine applies to which simulation results type.