MCFlowMace / CRESana

Analytic CRES signal modeling
2 stars 1 forks source link

Feature/asymmetric trap #9

Closed renereimann closed 8 months ago

renereimann commented 8 months ago

Implementation extended to allow for asymmetric trap shapes. The field lines can now be calculated in positive and negative direction starting from z=0, zmax can be evaluated on the positive z branch and negative z branch, ArbritraryTrap has additional keyword argument symmetric_trap that defaults to true to have backward compatibility. Simulation of trajectory is calculated individually for positive and negative z branch both starting at z=0. Solutions are combined and forwarded. Tests show that for symmetric fields the same solutions are returned in both symmetric_trap modes. Testing asymmetric traps show expected behaviour. Time in asymmetric mode takes double the time it takes for the symmetric mode.