ECP-WarpX / WarpX

WarpX is an advanced electromagnetic & electrostatic Particle-In-Cell code.
https://ecp-warpx.github.io
Other
292 stars 188 forks source link

Seeking help for abnormal electric feild #4069

Open lijiangdong1999 opened 1 year ago

lijiangdong1999 commented 1 year ago

Hello everyone, now I use warpx to simulate PWFA driven by proton beams. I have already got the microbunch structure, which is followed with theoretical prediction. But the longitudinal electric field is different with my result with lcode. Using the parameters of AWAKE, the longitudinal electric field is about 200MV/m in lcode, but 15MV/m in warpx. Could you please help check the input file to figure out why? Thanks in advance. Attached is my input files and simulation results about microbunch and longitudinal electric field. AWAKE.txt particle1 particle2 field

ax3l commented 1 year ago

Hi @lijiangdong1999,

thank you for reaching out. Debugging these kind of details usually takes a bit of careful detail-to-detail comparisons to figure out. @RemiLehe volunteered to help you, but is on vacation until the end of the month due to summer time.

Can you in the meantime please share a few more details on your setup? For instance:

  1. what is the density (with units) you try to model for the plasma and beam
  2. what is the LCODE input file 2.1. what is the model you use in LCODE - also electromagnetic PIC or an electrostatic model? 2.2. what boundary conditions and initial conditions are used in LCODE?
  3. are there any resolution constraints for your setup, e.g., is the Rb plasma frequency the shortest effect to resolve or something else?
  4. I noticed your input file does not initialize the self-field of the driver beam. How do you like to initialize it? With a Poisson solve (driver.initialize_self_fields = 1), as rigid injection or something else? We have multiple options: https://warpx.readthedocs.io/en/latest/usage/parameters.html#overall-simulation-parameters
  5. Any other details you can share, e.g., a sketch of the setup, paper, or link to the specs of the AWAKE campaign details that you try to model.
lijiangdong1999 commented 1 year ago

Thanks for your reply. I will give you more details about my simulation. 1.the density I try to model for the plasma and beam is the same as AWAKE parameters, 7.76e20 for plasma and 3e11 ppp for proton.

  1. And this is the input file of LCODE. awake-baseline.txt 2.1. I use an electrostatic model, called kinetic plasma model. 2.2. The boundary conditions are perfectly conducting tubes and the initial conditions you can find in awake-baseline.txt.
  2. I don't use any resolution constraints, it is the same as AWAKE experimental condition.
  3. I don't know whether I need to initialize the self-field of the driver beam. Do I need? Thanks again for your reply. If you want to contact me quickly, please send an email to lijiangdong@impcas.ac.cn
lijiangdong1999 commented 1 year ago

Hi @lijiangdong1999,

thank you for reaching out. Debugging these kind of details usually takes a bit of careful detail-to-detail comparisons to figure out. @RemiLehe volunteered to help you, but is on vacation until the end of the month due to summer time.

Can you in the meantime please share a few more details on your setup? For instance:

  1. what is the density (with units) you try to model for the plasma and beam
  2. what is the LCODE input file 2.1. what is the model you use in LCODE - also electromagnetic PIC or an electrostatic model? 2.2. what boundary conditions and initial conditions are used in LCODE?
  3. are there any resolution constraints for your setup, e.g., is the Rb plasma frequency the shortest effect to resolve or something else?
  4. I noticed your input file does not initialize the self-field of the driver beam. How do you like to initialize it? With a Poisson solve (driver.initialize_self_fields = 1), as rigid injection or something else? We have multiple options: https://warpx.readthedocs.io/en/latest/usage/parameters.html#overall-simulation-parameters
  5. Any other details you can share, e.g., a sketch of the setup, paper, or link to the specs of the AWAKE campaign details that you try to model.

These are some details when I use, do you have any suggestions? Thanks in advance.