| Summary: | magnetic field does not take effect, trajectory keeps straight line | ||
|---|---|---|---|
| Product: | Examples/Advanced | Reporter: | yyg_pku |
| Component: | purging_magnet | Assignee: | John Apostolakis <John.Apostolakis> |
| Status: | RESOLVED REMIND | ||
| Severity: | major | CC: | Alberto.Ribon |
| Priority: | P4 | ||
| Version: | 10.6 | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Attachments: |
Qt window of the application after /run/beamOn 1
Modified include and source files adding a new volume for the core of the field |
||
|
Description
yyg_pku
2020-07-13 17:11:38 CEST
Thank you for the report. I have investigated on a different machine. The problem is likely due to the sampling of the length of interaction -- a random number is used. If the magnetic field is sampled only at points at which it is zero, the integration will proceed incorrectly in a manner similar to the one that you have indicated. We need to ensure that tracks always 'sense' the finite field. One way is to create a volume around the region of non-zero field - in particular the region in which the material is vacuum or a gas. ( In those regions the length to the next interaction is large. ) When we caused the track to stop at a volume boundary, it must sample the field at multiple points before that boundary in the step that leads to the boundary. And in the next steps also it will sample the magnetic field, and thus be deflected. As a first step I have created a modified version of the example, which uses the extent of the magnetic field (as read in). We cannot enclose the full region of the magnetic field in a new volume -- it overlaps with an existing volume of the setup (Gap1). So this first modification creates a volume around the central axis - along which the beam is sent. Future refinements could either identify the exact region of the field which is does not overlap with other volumes or else create a parallel geometry with a volume that fully encloses the magnetic field. Created attachment 662 [details]
Modified include and source files adding a new volume for the core of the field
Hello. Did this work? Can you please let us know if you are still experiencing problem(s) ? |