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

Segmentation Fault during 2D Charge Deposition #31

Open
clairehansel3 opened this issue Jul 6, 2020 · 2 comments
Open

Segmentation Fault during 2D Charge Deposition #31

clairehansel3 opened this issue Jul 6, 2020 · 2 comments

Comments

@clairehansel3
Copy link

I have been experiencing a segmentation fault when running my simulation. Recompiling QuickPIC with debug information shows an invalid array access in the function PPGPPOST2L in part2d_lib77.f:

x = sq(nn,mm) + amx*amy

Print debugging shows values of nn and mm both less than 1 and greater than the length of the array. My input file is below:

qpinput.txt

@lifei07
Copy link
Contributor

lifei07 commented Jul 6, 2020

Hello, I think the issue may be caused by the super large beam density (and thus a very high beam current) you used. If the beam current is too large, the background electrons will be accelerated to a relatively large gamma when they flow to the back of the wake bubble. Therefore, the "effective" time step of these plasma particles, which is defined as dt*gamma/(gamma-pz) in the quasi-static approximation (QSA), may become tremendously huge so that it crashes the simulation run. Unfortunately this is a long-standing issue in QuickPIC and other QSA PIC codes, and we don't expect to resolve it in the foreseeable future. If you have to simulate such a high beam current, there is a workaround. Since the plasma particles crashing the codes appearing at the very rear of the bubble, you may shorten the simulation window a little bit to truncate before those particles reaching the very rear of the bubble. Hope this helps.

Fei

@vdecyk
Copy link

vdecyk commented Jul 7, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants