xtrack 0.98.10__tar.gz → 0.98.12__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (372) hide show
  1. {xtrack-0.98.10/xtrack.egg-info → xtrack-0.98.12}/PKG-INFO +1 -1
  2. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_bucket_with_ref_energy_change.py +31 -0
  3. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_elements.py +30 -0
  4. xtrack-0.98.12/xtrack/_version.py +1 -0
  5. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements.py +25 -14
  6. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet_kick.h +1 -1
  7. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_rf.h +5 -1
  8. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_rf.template.h +5 -1
  9. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/line.py +78 -8
  10. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/twiss.py +316 -253
  11. {xtrack-0.98.10 → xtrack-0.98.12/xtrack.egg-info}/PKG-INFO +1 -1
  12. xtrack-0.98.10/xtrack/_version.py +0 -1
  13. {xtrack-0.98.10 → xtrack-0.98.12}/LICENSE +0 -0
  14. {xtrack-0.98.10 → xtrack-0.98.12}/MANIFEST.in +0 -0
  15. {xtrack-0.98.10 → xtrack-0.98.12}/README.md +0 -0
  16. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/__init__.py +0 -0
  17. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/base_classes.py +0 -0
  18. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/BB6D.py +0 -0
  19. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/BB6Ddata.py +0 -0
  20. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/__init__.py +0 -0
  21. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/beambeam.py +0 -0
  22. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/boost.py +0 -0
  23. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/gaussian_fields.py +0 -0
  24. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/propagate_sigma_matrix.py +0 -0
  25. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/qgauss.py +0 -0
  26. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/slicing.py +0 -0
  27. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/be_beamfields/spacecharge.py +0 -0
  28. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/elements.py +0 -0
  29. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/line.py +0 -0
  30. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/mathlibs.py +0 -0
  31. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/particles.py +0 -0
  32. {xtrack-0.98.10 → xtrack-0.98.12}/ducktrack/temp_pyparticles.py +0 -0
  33. {xtrack-0.98.10 → xtrack-0.98.12}/pyproject.toml +0 -0
  34. {xtrack-0.98.10 → xtrack-0.98.12}/setup.cfg +0 -0
  35. {xtrack-0.98.10 → xtrack-0.98.12}/setup.py +0 -0
  36. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_acceleration.py +0 -0
  37. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_acdipole.py +0 -0
  38. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_acdipole_twiss.py +0 -0
  39. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_amplitude_detuning.py +0 -0
  40. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_aperture_polygon.py +0 -0
  41. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_aperture_table.py +0 -0
  42. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_aperture_turn_ele_and_monitor.py +0 -0
  43. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_apertures.py +0 -0
  44. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_attr_replicas_and_slices.py +0 -0
  45. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_boris_spatial.py +0 -0
  46. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_cavity_absolute_time.py +0 -0
  47. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_cavity_harmonic.py +0 -0
  48. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_chromatic_functions_vs_madx.py +0 -0
  49. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_coasting.py +0 -0
  50. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_collective_tracker.py +0 -0
  51. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_collimation.py +0 -0
  52. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_coupling_edwards_teng.py +0 -0
  53. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_electron_cooler.py +0 -0
  54. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_element_characterization_functions.py +0 -0
  55. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_element_internal_record.py +0 -0
  56. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_elements_classflags.py +0 -0
  57. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_elements_thick.py +0 -0
  58. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_environment.py +0 -0
  59. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_fcc_ee_solenoid_correction.py +0 -0
  60. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_fcc_ee_solenoid_correction_new_optimize_api.py +0 -0
  61. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_footprint.py +0 -0
  62. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_freeze_longitudinal.py +0 -0
  63. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_full_rings.py +0 -0
  64. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_h6_sps_beamline.py +0 -0
  65. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_hvkick.py +0 -0
  66. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_ions.py +0 -0
  67. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_json.py +0 -0
  68. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_lhc_env.py +0 -0
  69. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_lhc_match_phase_15.py +0 -0
  70. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_line.py +0 -0
  71. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_load.py +0 -0
  72. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_load_vars.py +0 -0
  73. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_lumi.py +0 -0
  74. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_mad_writer.py +0 -0
  75. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_madloader.py +0 -0
  76. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_madnginterface.py +0 -0
  77. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_magnet.py +0 -0
  78. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_and_track_from_element.py +0 -0
  79. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_coupling_knob.py +0 -0
  80. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_nested.py +0 -0
  81. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_optics_and_ip_knob.py +0 -0
  82. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_optics_and_ip_knob_new_optimize_api.py +0 -0
  83. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_orbit_bump.py +0 -0
  84. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_match_tune_chroma_cminus.py +0 -0
  85. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_misalign.py +0 -0
  86. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_monitor.py +0 -0
  87. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_multi_bunch_gauss.py +0 -0
  88. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_multiline.py +0 -0
  89. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_multisetter.py +0 -0
  90. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_multispecies.py +0 -0
  91. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_native_madloader.py +0 -0
  92. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_native_madloader_lhc.py +0 -0
  93. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_native_madloader_lhc_thin.py +0 -0
  94. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_native_madloader_ps.py +0 -0
  95. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_native_madloader_sps.py +0 -0
  96. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_native_madloader_ti2.py +0 -0
  97. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_optimize_for_tracking.py +0 -0
  98. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_particles.py +0 -0
  99. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_particles_basics.py +0 -0
  100. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_particles_pdg.py +0 -0
  101. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_pipeline.py +0 -0
  102. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_prebuild_kernels.py +0 -0
  103. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_ps_against_ptc.py +0 -0
  104. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_ps_multiturn_twiss.py +0 -0
  105. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_psb_chicane.py +0 -0
  106. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_pyht_interface.py +0 -0
  107. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_quadrupole_fringe_ptc.py +0 -0
  108. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_quadrupole_wedge.py +0 -0
  109. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_radial_steering.py +0 -0
  110. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_radiation.py +0 -0
  111. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_radiation_equilibrium_emittances.py +0 -0
  112. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_radiation_equilibrium_emittances_thick.py +0 -0
  113. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_radiation_integrals.py +0 -0
  114. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_random_gen.py +0 -0
  115. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_random_gen_exp.py +0 -0
  116. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_random_gen_gauss.py +0 -0
  117. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_random_gen_ruth.py +0 -0
  118. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_rbend_straight_body.py +0 -0
  119. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_rf_track.py +0 -0
  120. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_rotation_signs.py +0 -0
  121. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_second_order_taylor_map.py +0 -0
  122. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_seeds.py +0 -0
  123. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_slice_and_insert_with_replicas.py +0 -0
  124. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_slice_elements.py +0 -0
  125. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_slicing.py +0 -0
  126. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_solenoid_bz_map_vs_boris.py +0 -0
  127. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_solenoid_bz_map_vs_boris_legacy.py +0 -0
  128. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_spacecharge_in_ring.py +0 -0
  129. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_spin.py +0 -0
  130. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_sps_thick_cpymad_loader.py +0 -0
  131. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_sps_thick_native_loader.py +0 -0
  132. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_survey.py +0 -0
  133. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_tapering.py +0 -0
  134. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_thick_kickers_rf_crab.py +0 -0
  135. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_thick_lhc.py +0 -0
  136. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_tilt_shifts.py +0 -0
  137. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_tracker.py +0 -0
  138. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_trajectory_correcton.py +0 -0
  139. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_twiss.py +0 -0
  140. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_twiss_to_file.py +0 -0
  141. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_twiss_vs_madx_psb.py +0 -0
  142. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_vs_madx.py +0 -0
  143. {xtrack-0.98.10 → xtrack-0.98.12}/tests/test_xmask_orbit_correction.py +0 -0
  144. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/__init__.py +0 -0
  145. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/__init__.py +0 -0
  146. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/boris_and_solenoid_map/__init__.py +0 -0
  147. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/boris_and_solenoid_map/boris.h +0 -0
  148. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/boris_and_solenoid_map/solenoid_field.py +0 -0
  149. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/lhc_match/__init__.py +0 -0
  150. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/lhc_match/gen_madx_optics_file.py +0 -0
  151. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/lhc_match/lhc_match.py +0 -0
  152. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/lhc_match/var_limits.py +0 -0
  153. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/python_lattice_writer/__init__.py +0 -0
  154. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/_temp/python_lattice_writer/lattice_py_generation.py +0 -0
  155. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/aperture_meas.py +0 -0
  156. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/base_element.py +0 -0
  157. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/__init__.py +0 -0
  158. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/acdipole.py +0 -0
  159. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures.py +0 -0
  160. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures_src/limitellipse.h +0 -0
  161. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures_src/limitpolygon.h +0 -0
  162. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures_src/limitracetrack.h +0 -0
  163. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures_src/limitrect.h +0 -0
  164. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures_src/limitrectellipse.h +0 -0
  165. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/apertures_src/longitudinallimitrect.h +0 -0
  166. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/beam_interaction.py +0 -0
  167. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/_generate_slice_elements_c_code.py +0 -0
  168. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/_include_integrator.py +0 -0
  169. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/acdipole.h +0 -0
  170. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/bend.h +0 -0
  171. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/cavity.h +0 -0
  172. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/crab_cavity.h +0 -0
  173. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/default_magnet_config.h +0 -0
  174. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/dipole_fringe.h +0 -0
  175. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/dipoleedge.h +0 -0
  176. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift.h +0 -0
  177. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_exact.h +0 -0
  178. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_exact_slice.h +0 -0
  179. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice.h +0 -0
  180. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_bend.h +0 -0
  181. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_cavity.h +0 -0
  182. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_crab_cavity.h +0 -0
  183. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_multipole.h +0 -0
  184. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_octupole.h +0 -0
  185. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_quadrupole.h +0 -0
  186. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_rbend.h +0 -0
  187. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_sextupole.h +0 -0
  188. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/drift_slice_uniform_solenoid.h +0 -0
  189. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/electroncooler.h +0 -0
  190. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/elens.h +0 -0
  191. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/exciter.h +0 -0
  192. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/firstordertaylormap.h +0 -0
  193. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/legacy_solenoid.h +0 -0
  194. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/linesegmentmap.h +0 -0
  195. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/magnet.h +0 -0
  196. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/magnet_drift.h +0 -0
  197. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/magnet_edge.h +0 -0
  198. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/magnet_kick.h +0 -0
  199. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/marker.h +0 -0
  200. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/misalignment.h +0 -0
  201. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/multipole.h +0 -0
  202. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/multipoleedge.h +0 -0
  203. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/nonlinearlens.h +0 -0
  204. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/octupole.h +0 -0
  205. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/quadrupole.h +0 -0
  206. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/rbend.h +0 -0
  207. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/referenceenergyincrease.h +0 -0
  208. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/rfmultipole.h +0 -0
  209. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/second_order_taylor_map.h +0 -0
  210. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/sextupole.h +0 -0
  211. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/simplethinbend.h +0 -0
  212. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/simplethinquadrupole.h +0 -0
  213. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/slnd.h +0 -0
  214. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/srotation.h +0 -0
  215. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_bend.h +0 -0
  216. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_cavity.h +0 -0
  217. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_crab_cavity.h +0 -0
  218. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_multipole.h +0 -0
  219. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_octupole.h +0 -0
  220. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_quadrupole.h +0 -0
  221. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_rbend.h +0 -0
  222. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_sextupole.h +0 -0
  223. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thick_slice_uniform_solenoid.h +0 -0
  224. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_bend.h +0 -0
  225. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_bend_entry.h +0 -0
  226. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_bend_exit.h +0 -0
  227. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_cavity.h +0 -0
  228. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_crab_cavity.h +0 -0
  229. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_multipole.h +0 -0
  230. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_octupole.h +0 -0
  231. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_octupole_entry.h +0 -0
  232. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_octupole_exit.h +0 -0
  233. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_quadrupole.h +0 -0
  234. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_quadrupole_entry.h +0 -0
  235. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_quadrupole_exit.h +0 -0
  236. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_rbend.h +0 -0
  237. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_rbend_entry.h +0 -0
  238. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_rbend_exit.h +0 -0
  239. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_sextupole.h +0 -0
  240. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_sextupole_entry.h +0 -0
  241. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_sextupole_exit.h +0 -0
  242. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_uniform_solenoid_entry.h +0 -0
  243. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/thin_slice_uniform_solenoid_exit.h +0 -0
  244. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_acdipole.h +0 -0
  245. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_dipole_edge_linear.h +0 -0
  246. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_dipole_edge_nonlinear.h +0 -0
  247. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_dipole_fringe.h +0 -0
  248. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_drift.h +0 -0
  249. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_legacy_solenoid.h +0 -0
  250. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_legacy_solenoid_multipolar_components.h +0 -0
  251. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_legacy_solenoid_radiation.h +0 -0
  252. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet.h +0 -0
  253. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet.template.h +0 -0
  254. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet_configure.h +0 -0
  255. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet_drift.h +0 -0
  256. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet_edge.h +0 -0
  257. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_magnet_radiation.h +0 -0
  258. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_misalignments.h +0 -0
  259. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_mult_fringe.h +0 -0
  260. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_srotation.h +0 -0
  261. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_thick_bend.h +0 -0
  262. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_thick_cfd.h +0 -0
  263. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_wedge.h +0 -0
  264. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_xrotation.h +0 -0
  265. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_xyshift.h +0 -0
  266. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/track_yrotation.h +0 -0
  267. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/variable_solenoid.h +0 -0
  268. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/wedge.h +0 -0
  269. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/wire.h +0 -0
  270. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/xrotation.h +0 -0
  271. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/xyshift.h +0 -0
  272. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/yrotation.h +0 -0
  273. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/elements_src/zetashift.h +0 -0
  274. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/exciter.py +0 -0
  275. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/rft_element.py +0 -0
  276. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/slice_base.py +0 -0
  277. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/slice_elements_drift.py +0 -0
  278. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/slice_elements_edge.py +0 -0
  279. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/slice_elements_thick.py +0 -0
  280. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/beam_elements/slice_elements_thin.py +0 -0
  281. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/boris.py +0 -0
  282. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/builder.py +0 -0
  283. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/environment.py +0 -0
  284. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/footprint.py +0 -0
  285. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/functions.py +0 -0
  286. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/general.py +0 -0
  287. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/atomicadd.h +0 -0
  288. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/checks.h +0 -0
  289. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/constants.h +0 -0
  290. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/particle_states.h +0 -0
  291. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/synrad_spectrum.h +0 -0
  292. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/track.h +0 -0
  293. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/headers/track_local_particle_with_transformations.h +0 -0
  294. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/internal_record.py +0 -0
  295. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/json.py +0 -0
  296. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/linear_normal_form.py +0 -0
  297. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/load.py +0 -0
  298. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/loss_location_refinement/__init__.py +0 -0
  299. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/loss_location_refinement/loss_location_refinement.py +0 -0
  300. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/lumi.py +0 -0
  301. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/mad_loader.py +0 -0
  302. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/mad_parser/__init__.py +0 -0
  303. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/mad_parser/loader.py +0 -0
  304. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/mad_parser/madx.lark +0 -0
  305. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/mad_parser/parse.py +0 -0
  306. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/mad_writer.py +0 -0
  307. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/madng_interface.py +0 -0
  308. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/match.py +0 -0
  309. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/__init__.py +0 -0
  310. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/beam_position_monitor.h +0 -0
  311. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/beam_position_monitor.py +0 -0
  312. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/beam_profile_monitor.h +0 -0
  313. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/beam_profile_monitor.py +0 -0
  314. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/beam_size_monitor.h +0 -0
  315. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/beam_size_monitor.py +0 -0
  316. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/last_turns_monitor.h +0 -0
  317. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/last_turns_monitor.py +0 -0
  318. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/particles_monitor.h +0 -0
  319. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/monitors/particles_monitor.py +0 -0
  320. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multiline.py +0 -0
  321. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multiline_legacy/__init__.py +0 -0
  322. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multiline_legacy/multiline_legacy.py +0 -0
  323. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multiline_legacy/shared_knobs.py +0 -0
  324. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multisetter/__init__.py +0 -0
  325. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multisetter/multisetter.h +0 -0
  326. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/multisetter/multisetter.py +0 -0
  327. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/__init__.py +0 -0
  328. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/constants.py +0 -0
  329. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/local_particle_custom_api.h +0 -0
  330. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/masses.py +0 -0
  331. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/particles.py +0 -0
  332. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/pdg.py +0 -0
  333. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/rng_src/base_rng.h +0 -0
  334. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/particles/rng_src/particles_rng.h +0 -0
  335. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/pipeline/__init__.py +0 -0
  336. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/pipeline/core.py +0 -0
  337. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/pipeline/manager.py +0 -0
  338. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/pipeline/multitracker.py +0 -0
  339. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/prebuilt_kernel_definitions/__init__.py +0 -0
  340. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/prebuilt_kernel_definitions/element_inits.py +0 -0
  341. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/prebuilt_kernel_definitions/element_types.py +0 -0
  342. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/progress_indicator.py +0 -0
  343. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/__init__.py +0 -0
  344. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_generators.py +0 -0
  345. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_src/exponential.h +0 -0
  346. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_src/exponential_integral_Ei.h +0 -0
  347. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_src/normal.h +0 -0
  348. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_src/rutherford.h +0 -0
  349. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_src/uniform.h +0 -0
  350. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/random/random_src/uniform_accurate.h +0 -0
  351. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/slicing.py +0 -0
  352. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/survey.py +0 -0
  353. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/svgutils/__init__.py +0 -0
  354. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/svgutils/parser.py +0 -0
  355. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/svgutils/path.py +0 -0
  356. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/svgutils/svgutils.py +0 -0
  357. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/synctime.py +0 -0
  358. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/table.py +0 -0
  359. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/tapering.py +0 -0
  360. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/targets.py +0 -0
  361. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/track_flags.py +0 -0
  362. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/tracker.py +0 -0
  363. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/tracker_data.py +0 -0
  364. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/tracker_src/tracker.h +0 -0
  365. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/trajectory_correction.py +0 -0
  366. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/twissplot.py +0 -0
  367. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack/view.py +0 -0
  368. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack.egg-info/SOURCES.txt +0 -0
  369. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack.egg-info/dependency_links.txt +0 -0
  370. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack.egg-info/entry_points.txt +0 -0
  371. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack.egg-info/requires.txt +0 -0
  372. {xtrack-0.98.10 → xtrack-0.98.12}/xtrack.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: xtrack
3
- Version: 0.98.10
3
+ Version: 0.98.12
4
4
  Summary: Tracking library for particle accelerators
5
5
  Author: G. Iadarola et al.
6
6
  License-Expression: Apache-2.0
@@ -4,6 +4,10 @@ import xobjects as xo
4
4
 
5
5
  import numpy as np
6
6
  from scipy.constants import c as clight
7
+ import pathlib
8
+
9
+ test_data_folder = pathlib.Path(
10
+ __file__).parent.joinpath('../test_data').absolute()
7
11
 
8
12
  def test_bucket_below_transition():
9
13
 
@@ -1014,3 +1018,30 @@ def test_bucket_with_reference_ernergy_increase_elem():
1014
1018
  xo.assert_allclose(z_std, np.mean(z_std), atol=0.025*sigma_z)
1015
1019
  xo.assert_allclose(delta_mean, np.mean(delta_mean), atol=0.025*sigma_delta)
1016
1020
  xo.assert_allclose(delta_std, np.mean(delta_std), atol=0.025*sigma_delta)
1021
+
1022
+ def test_bucket_with_radiation():
1023
+
1024
+ env = xt.load(test_data_folder / 'fcc_ee/fccee_h.seq')
1025
+ pc_gev = 120.
1026
+
1027
+ line = env.fccee_p_ring
1028
+ line.set_particle_ref('positron', p0c=pc_gev*1e9)
1029
+
1030
+ tw_no_rad = line.twiss6d()
1031
+ rfb_no_rad = line._get_bucket()
1032
+
1033
+ line.configure_radiation(model='mean')
1034
+ line.compensate_radiation_energy_loss()
1035
+
1036
+ tw_rad = line.twiss6d(eneloss_and_damping=True)
1037
+ rfb_rad = line._get_bucket()
1038
+
1039
+ # Check that the effect of the radiation is visible on qs
1040
+ assert tw_no_rad.qs > 0.045
1041
+ assert tw_rad.qs < 0.035
1042
+
1043
+ # Check consistency of qs and bets0 between twiss and rfb
1044
+ xo.assert_allclose(rfb_no_rad.Q_s, tw_no_rad.qs, rtol=0.01)
1045
+ xo.assert_allclose(rfb_rad.Q_s, tw_rad.qs, rtol=0.01)
1046
+ xo.assert_allclose(rfb_no_rad.beta_z, tw_no_rad.bets0, rtol=0.015)
1047
+ xo.assert_allclose(rfb_rad.beta_z, tw_rad.bets0, rtol=0.015)
@@ -1349,3 +1349,33 @@ def test_beam_element_shifts_backwards_compatible():
1349
1349
  assert sext.shift_x == legacy_dict['_shift_x']
1350
1350
  assert sext.shift_y == legacy_dict['_shift_y']
1351
1351
  assert sext.shift_s == legacy_dict['_shift_s']
1352
+
1353
+ def test_cavity_lag_taper():
1354
+
1355
+ env = xt.Environment()
1356
+
1357
+ line = env.new_line(components=[
1358
+ env.new('cav', xt.Cavity, frequency=400e6, voltage=16e6),
1359
+ ])
1360
+ p0 = xt.Particles(p0c=450e9)
1361
+
1362
+ p1 = p0.copy()
1363
+ line.track(p1)
1364
+ xo.assert_allclose(p1.delta, 0, atol=1e-10)
1365
+
1366
+ env['cav'].lag = 60
1367
+ p2 = p0.copy()
1368
+ line.track(p2)
1369
+ assert p2.delta != 0
1370
+
1371
+ env['cav'].lag_taper = -60
1372
+ p3 = p0.copy()
1373
+ line.track(p3)
1374
+ # lag_taper should be ignored because radiation is off
1375
+ xo.assert_allclose(p3.delta, p2.delta, atol=1e-10)
1376
+
1377
+ line.configure_radiation(model='mean')
1378
+ p4 = p0.copy()
1379
+ line.track(p4)
1380
+ # lag_taper should be applied now
1381
+ xo.assert_allclose(p4.delta, 0, atol=1e-10)
@@ -0,0 +1 @@
1
+ __version__ = '0.98.12'
@@ -840,7 +840,12 @@ class CrabCavity(_HasModelRF, _HasIntegrator, BeamElement):
840
840
 
841
841
 
842
842
  class XYShift(BeamElement):
843
- '''Beam element modeling an transverse shift of the reference system.
843
+ '''
844
+ Beam element modeling an transverse shift of the reference system, by applying
845
+ the following transformation to the particle coordinates:
846
+
847
+ x_new = x_old - dx
848
+ y_new = y_old - dy
844
849
 
845
850
  Parameters
846
851
  ----------
@@ -985,9 +990,12 @@ class Wire(BeamElement):
985
990
 
986
991
 
987
992
  class SRotation(BeamElement):
988
- """Beam element modeling a rotation of the reference system around the s-axis.
989
- Positive angle is defined as x to y, i.e. counter-clockwise when looking
990
- from the end of the s-axis towards the origin.
993
+ """
994
+ Beam element modeling a rotation of the reference system around the s-axis.
995
+ The sign convention is such that:
996
+
997
+ px_out = px_in * cos(angle) - py_in * sin(angle)
998
+
991
999
 
992
1000
  Parameters
993
1001
  ----------
@@ -1053,9 +1061,11 @@ class SRotation(BeamElement):
1053
1061
 
1054
1062
 
1055
1063
  class XRotation(BeamElement):
1056
- """Beam element modeling a rotation of the reference system around the x-axis.
1057
- Positive angle is defined as y to s, i.e. counter-clockwise when looking
1058
- from the end of the x-axis towards the origin.
1064
+ """
1065
+ Beam element modeling a rotation of the reference system around the x-axis.
1066
+ The sign convention is such that:
1067
+
1068
+ py_out = py_in * cos(angle) + pz_in * sin(angle)
1059
1069
 
1060
1070
  Parameters
1061
1071
  ----------
@@ -1142,9 +1152,11 @@ class XRotation(BeamElement):
1142
1152
 
1143
1153
 
1144
1154
  class YRotation(BeamElement):
1145
- """Beam element modeling a rotation of the reference system around the y-axis.
1146
- Positive angle is defined as s to x, i.e. counter-clockwise when looking
1147
- from the end of the y-axis towards the origin.
1155
+ """
1156
+ Beam element modeling a rotation of the reference system around the y-axis.
1157
+ The sign convention is such that:
1158
+
1159
+ px_out = px_in * cos(angle) - pz_in * sin(angle)
1148
1160
 
1149
1161
  Parameters
1150
1162
  ----------
@@ -1182,8 +1194,6 @@ class YRotation(BeamElement):
1182
1194
  calculate the missing values from the others. If more than necessary
1183
1195
  parameters are given, their consistency will be checked.
1184
1196
  """
1185
- #Note MAD-X node_value('other_bv ') is ignored
1186
- # minus sign follows MAD-X convention
1187
1197
 
1188
1198
  if '_xobject' in kwargs and kwargs['_xobject'] is not None:
1189
1199
  self.xoinitialize(**kwargs)
@@ -1591,11 +1601,12 @@ class _BendCommon(_HasKnlKsl, _HasIntegrator, _HasModelCurved):
1591
1601
  self._length = value
1592
1602
  if self.length != 0:
1593
1603
  self._h = self.angle / self.length
1594
- if self.k0_from_h:
1595
- self._k0 = self.h
1596
1604
  else:
1597
1605
  self._h = 0.0
1598
1606
 
1607
+ if self.k0_from_h:
1608
+ self._k0 = self.h
1609
+
1599
1610
  @property
1600
1611
  def h(self):
1601
1612
  return self._h
@@ -87,7 +87,7 @@ void track_magnet_kick_single_particle(
87
87
  double const hl = h * length * kick_weight + hxl * kick_weight;
88
88
  dpx += hl * (1. + LocalParticle_get_delta(part));
89
89
  double const rv0v = 1./LocalParticle_get_rvv(part);
90
- dzeta += -rv0v * chi * hl * x;
90
+ dzeta += -rv0v * hl * x;
91
91
  }
92
92
 
93
93
  double htot = h;
@@ -340,6 +340,10 @@ void track_rf_particles(
340
340
  double body_length;
341
341
  double factor_knl_ksl_body;
342
342
 
343
+ #ifndef XTRACK_MULTIPOLE_NO_SYNRAD
344
+ lag += lag_taper;
345
+ #endif
346
+
343
347
  if (LocalParticle_check_track_flag(part0, XS_FLAG_BACKTRACK)) {
344
348
  body_length = -length;
345
349
  factor_knl_ksl_body = -factor_knl_ksl;
@@ -405,7 +409,7 @@ void track_rf_particles(
405
409
  body_length * weight,
406
410
  voltage * weight,
407
411
  frequency,
408
- lag + lag_taper,
412
+ lag,
409
413
  harmonic,
410
414
  transverse_voltage * weight,
411
415
  transverse_lag,
@@ -259,6 +259,10 @@ void track_rf_particles(
259
259
  double body_length;
260
260
  double factor_knl_ksl_body;
261
261
 
262
+ #ifndef XTRACK_MULTIPOLE_NO_SYNRAD
263
+ lag += lag_taper;
264
+ #endif
265
+
262
266
  if (LocalParticle_check_track_flag(part0, XS_FLAG_BACKTRACK)) {
263
267
  body_length = -length;
264
268
  factor_knl_ksl_body = -factor_knl_ksl;
@@ -324,7 +328,7 @@ void track_rf_particles(
324
328
  body_length * weight,
325
329
  voltage * weight,
326
330
  frequency,
327
- lag + lag_taper,
331
+ lag,
328
332
  harmonic,
329
333
  transverse_voltage * weight,
330
334
  transverse_lag,
@@ -1567,6 +1567,8 @@ class Line:
1567
1567
 
1568
1568
  """
1569
1569
  Compute the 4D Twiss parameters. Equivalent to `twiss` with `method='4d'`.
1570
+ See :ref:`Line.twiss method documentation<twiss_method_label>` for all
1571
+ available options.
1570
1572
  """
1571
1573
  assert 'method' not in kwargs, 'method cannot be provided as argument to twiss4d'
1572
1574
  kwargs['method'] = '4d'
@@ -1576,6 +1578,8 @@ class Line:
1576
1578
 
1577
1579
  """
1578
1580
  Compute the 6D Twiss parameters. Equivalent to `twiss` with `method='6d'`.
1581
+ See :ref:`Line.twiss method documentation<twiss_method_label>` for all
1582
+ available options.
1579
1583
  """
1580
1584
  assert 'method' not in kwargs, 'method cannot be provided as argument to twiss6d'
1581
1585
  kwargs['method'] = '6d'
@@ -1744,29 +1748,95 @@ class Line:
1744
1748
  element0=0, reverse=None):
1745
1749
 
1746
1750
  """
1747
- Returns a survey of the beamline (based on MAD-X survey command).
1751
+ Compute the geometrical layout, i.e. the coordinates of all beam line
1752
+ elements in the global reference system. (for detailed definitions of
1753
+ the involved quantities please refer to the Xsuite Physics Guide
1754
+ (https://xsuite.readthedocs.io/en/latest/physicsguide.html)
1748
1755
 
1749
1756
  Parameters
1750
1757
  ----------
1751
1758
  X0 : float
1752
- Initial X coordinate in meters.
1759
+ Initial X coordinate in meters. Default is 0.
1753
1760
  Y0 : float
1754
- Initial Y coordinate in meters.
1761
+ Initial Y coordinate in meters. Default is 0.
1755
1762
  Z0 : float
1756
- Initial Z coordinate in meters.
1763
+ Initial Z coordinate in meters. Default is 0.
1757
1764
  theta0 : float
1758
- Initial theta coordinate in radians.
1765
+ Initial theta coordinate in radians. Default is 0.
1759
1766
  phi0 : float
1760
- Initial phi coordinate in radians.
1767
+ Initial phi coordinate in radians. Default is 0.
1761
1768
  psi0 : float
1762
- Initial psi coordinate in radians.
1769
+ Initial psi coordinate in radians. Default is 0.
1763
1770
  element0 : int or str
1764
- Element at which the given coordinates are defined.
1771
+ Element at which the given coordinates are defined. Default is the
1772
+ first element in the beam line.
1773
+ reverse : bool
1774
+ If True, the survey is computed in the reversed reference frame.
1765
1775
 
1766
1776
  Returns
1767
1777
  -------
1768
1778
  survey : SurveyTable
1769
1779
  Survey table.
1780
+
1781
+ Notes
1782
+ -----
1783
+
1784
+ The output survey table contains the following columns:
1785
+
1786
+ - ``name``: element name (with occurrence counts for repeated names).
1787
+ - ``element_type``: type of the element (e.g. Drift, Marker, Bend).
1788
+ - ``s``: longitudinal coordinate at the element entrance [m].
1789
+ - ``X``, ``Y``, ``Z``: position of the element entrance in the global frame [m].
1790
+ - ``theta``, ``phi``, ``psi``: orientation angles of the local frame
1791
+ (azimuth, elevation, roll) unwrapped along the line [rad].
1792
+ - ``ex``, ``ey``, ``ez``: unit vectors of the local frame expressed in
1793
+ the global frame (they are the columns of ``W``).
1794
+ - ``W``: 3x3 rotation matrices describing the local frame at each
1795
+ element entrance.
1796
+ - ``p0``: position vectors stacked as ``[X, Y, Z]``.
1797
+ - ``isthick``: ``True`` for thick elements, ``False`` for markers.
1798
+ - ``drift_length``: length used while advancing the survey (zero for
1799
+ thin elements) [m].
1800
+ - ``length``: physical length of the element [m].
1801
+ - ``angle``: bending angle of the element [rad].
1802
+ - ``rot_s_rad``: rotation around the longitudinal axis applied before
1803
+ the element [rad].
1804
+ - ``ref_shift_x``, ``ref_shift_y``: alignment shifts applied before the
1805
+ element [m].
1806
+ - ``ref_rot_x_rad``, ``ref_rot_y_rad``, ``ref_rot_s_rad``: alignment
1807
+ rotations applied before the element [rad].
1808
+
1809
+ Examples
1810
+ --------
1811
+ .. code-block:: python
1812
+
1813
+ import xtrack as xt
1814
+
1815
+ # Create a simple line
1816
+ env = xt.Environment(particle_ref=xt.Particles(p0c=1e9))
1817
+ line = env.new_line(length=6, components=[
1818
+ env.new('b1', xt.Bend, length=0.2, angle=0.1, at=1),
1819
+ env.new('q1', xt.Quadrupole, length=0.1, k1=0.5, at=2),
1820
+ env.new('b2', xt.Bend, length=0.2, angle=-0.1, at=3),
1821
+ env.new('q2', xt.Quadrupole, length=0.1, k1=-0.5, at=4),
1822
+ ])
1823
+
1824
+ # Compute the survey
1825
+ sv = line.survey()
1826
+ # sv.X, sv.Y, sv.Z contain the coordinates of the reference
1827
+ # trajectory in the global frame
1828
+
1829
+ # Compute the trajectory of a particle entering with x=1 mm and y=2 mm
1830
+ tw = line.twiss4d(betx=1, bety=1, x=1e-3, y=2e-3)
1831
+ # tw.x, tw.y contain the coordinates of the particle in the local frame
1832
+
1833
+ # Compute the trajectory of the particle in the global frame
1834
+ p_global = tw.x[:, None] * sv.ex + tw.y[:, None] * sv.ey + sv.p0
1835
+
1836
+ X_trajectory = p_global[:, 0]
1837
+ Y_trajectory = p_global[:, 1]
1838
+ Z_trajectory = p_global[:, 2]
1839
+
1770
1840
  """
1771
1841
 
1772
1842
  if not self._has_valid_tracker():