Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Space charge Mayes IPAC2018 benchmark #429

Open
wants to merge 50 commits into
base: development
Choose a base branch
from

Conversation

cemitch99
Copy link
Member

@cemitch99 cemitch99 commented Sep 8, 2023

This PR refers to:

C. E. Mayes, R. D. Ryne, and D. C. Sagan, "3D Space Charge in BMAD," in proc. IPAC2018,
DOI:10.18429/JACoW-IPAC2018-THPAK085

This is a replacement for PR #257
Closes @ChristopherMayes' #256.

Added the expanding Gaussian beam test and plot script corresponding to phase space shown in Fig. 4.

  • add expanding Gaussian beam test
  • add plot script to reproduce Fig. 4
  • add static Gaussian beam field calculation
  • add plot script to reproduce Fig. 1
  • add documentation
  • verify resolution and convergence
  • potentially use IGF solver (with much smaller grid) 3D IGF Solver #605

Figure_1

cemitch99 and others added 3 commits September 8, 2023 11:58
- Modified the initial beam size in the IOTA lens benchmark example.
- Added 2 benchmarks of 3D space charge for initial testing.
- Add documentation for 2 benchmarks with space charge.
- Add a benchmark example with space charge and periodic s-dependent focusing.
- Added an s-dependent example using a Kurth beam without space charge.
- Modified tolerance for IOTA lens benchmark example.
  Reduced tolerance to account for smaller initial beam size and
  improved preservation of invariants of motion.
- Modified tolerances of space charge examples to allow CI tests to
  pass when space charge is not active.

- Modified tolerance for space charge examples.
  These should fail unless space charge is turned on.
Selected numerical values for amr.n_cell, lattice.nslice, and geometry.prob_relative.
@ax3l ax3l mentioned this pull request Sep 9, 2023
4 tasks
@ax3l ax3l added component: tests examples, tests and benchmarks component: space charge Space charge & potential solver labels Sep 9, 2023
@ChristopherMayes
Copy link

Could the plot(s) be created and checked in, or at least put in docs somewhere?

cemitch99 and others added 4 commits September 28, 2023 14:31
Expose the numeric parameters of the multi-grid solver
that we currently use for space charge calculations.
@ax3l
Copy link
Member

ax3l commented Sep 29, 2023

@ChristopherMayes Thank you for your comment. Yes, absolutely. We still finalize a few space charge benchmarks for HB 2023 right now and this is one of them. As stated in your IPAC2018 paper, the non-IGF method starts to fail for large aspect ratios (w/o pushing resolution much further up). We added a preview to the PR description.

We will clean this PR up further once final, e.g., replacing the data files from the analytical solution with results calculated on the fly.

Yes, on the plots, too. The docs will get a readme file for the new case and we will include the plot, similar to https://impactx.readthedocs.io/en/latest/usage/examples/fodo/README.html

pre-commit-ci bot and others added 9 commits March 4, 2024 19:41
Update "beam.energy" -> "beam.kin_energy"
Update "energy" -> "kin_energy"
Update "energy" -> "kin_energy"
Update kin_energy value.
Update sim.prob_relative syntax.
Update sim.prob_relative syntax.
Comment unused parameters.
examples/CMakeLists.txt Outdated Show resolved Hide resolved
cemitch99 and others added 20 commits March 4, 2024 13:01
del.sim -> sim.finalize()
Add access to required field data files.
Correct path.
Correct destination of copy.
Comment field test (debug).
Use large tolerance for now.
Use large tolerance for now.
Remove unnecessary plot lines (use plot_expanding_ipac2018.py instead).
Turn on second test.
Comment call to Ey for testing.
Correct Ey -> Ez
nGrowVect -> n_grow_vect
Turn off analysis for field plot test.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: space charge Space charge & potential solver component: tests examples, tests and benchmarks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants