apace.tracking_matrix
¶
Module Contents¶
Classes¶
Particle tracking using the transfer matrix method. |
- class apace.tracking_matrix.TrackingMatrix(lattice, initial_distribution, turns=1, watch_points=None, start_point=0, **kwargs)¶
Inherits:
apace.matrixmethod.MatrixMethod
Particle tracking using the transfer matrix method.
- Parameters
lattice (Lattice) – Lattice which particles will be tracked through.
initial_distribution (np.ndarray) – Initial particle distribution.
turns (int) – Number of turns.
watch_points (array-like, optional) – List of watch points. If unset all particle trajectory will be saved for all positions. Indices correspont to
orbit_positions
.start_point (int) – Point at which the particle tracking begins.
Attributes
- watch_points¶
- initial_distribution¶
- Return type
- particle_trajectories¶
Contains the 6D particle trajectories.
- Return type
- orbit_position¶
- Return type
- x¶
- Return type
- x_dds¶
- Return type
- y¶
- Return type
- y_dds¶
- Return type
- lon¶
- Return type
- delta¶
- Return type
- element_indices¶
Contains the indices of each element within the transfer_matrices.
- Return type
Dict[apace.classes.Element, List[int]]
- step_size¶
Contains the step_size for each point. Has length of n_kicks
- Return type
- s¶
Contains the orbit position s for each point. Has length of n_kicks + 1.
- Return type
- matrices¶
Array of transfer matrices with shape (6, 6, n_kicks)
- Return type
- k0¶
Array of deflections angles with shape (n_kicks).
- Return type
- k1¶
Array of geometric quadruole strenghts with shape (n_kicks).
- Return type
- start_index¶
Start index of the one-turn matrix and the accumulated transfer matrices.
- Return type
- matrices_acc¶
The accumulated transfer matrices starting from start_index.
- Return type
Methods
- update_particle_trajectories()¶
Manually update the 6D particle trajectories
- _on_particle_trajectories_changed()¶
- _on_element_changed(element, attribute)¶
- update_n_steps()¶
Manually update the total number of kicks.
- _on_n_steps_changed()¶
- update_element_indices()¶
Manually update the indices of each element.
- _on_element_indices_changed()¶
- update_step_size()¶
Manually update the step_size array.
- _on_step_size_changed()¶
- update_s()¶
Manually update the orbit position array s.
- _on_s_changed()¶
- update_matrices()¶
Manually update the transfer_matrices.
- update_matrices_acc()¶
- _on_matrices_accumulated_changed()¶