-
Notifications
You must be signed in to change notification settings - Fork 5
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
Track electrons through argon with space charge at different pressures? #4
Comments
This should be doable with Warp and optionally with rswarp to extend ionization capabilities. The main reason to want to use rswarp to handle the ionization is to provide functional forms for the cross section and ionization product's energies and angular distribution. Warp currently only supports static values for these items and does not support any setting of a product's vector. If the user has some function for any of these items then rswarp could be of use. |
I think some of these rswarp capabilities have been recently merged into the Warp base code, although I'm not sure exactly what or when. We should verify which version of Warp is being used. |
@cchall and I verified that the rswarp extensions for ionization physics have not yet been added to the Warp base code. It seems that helping the user implies offering some advice or even providing a Warp Python script. |
@bruhwiler a sample script for my issue would of course be very helpful. I am new to warp/rswarp, but I already worked with TraceWin and G4Beamline. |
I have an additional question: Is this effect considered in the code? |
1.1699548.pdf |
Hello @ohinrichs Thanks for the interesting paper. I think the ion macroparticles are created with zero velocity. We are planning to add the option for them to be created with a random velocity, based on the specified temperature of the neutral gas. If you are interested to look in the code, then we can assist. RadiaSoft is in the process of hiring, and we may have someone who can begin working on this in 4 to 6 weeks. For the system described in the paper, there may be complications if the gas temperature varies with position. If the gas temperature is uniform, and is equal to the wall temperature, then Warp should be able to model the problem, after the finite temperature ion capability is implemented. |
Oh I see. I thought giving the added macroparticles an emitted energy would also create a velocity. |
@ohinrichs @bruhwiler We do currently create the ions with zero initial velocity rswarp/examples/ionization/magnetized_cooler.py Lines 178 to 179 in 5b32d9f
However, any callable function could be dropped in and used to set the ion velocities depending on what your model requires. If there is a varying ion temperature it should be possible to register multiple Ionization instances, each in a different volume. If the temperature does not change very rapidly this could be a reasonable solution. It shouldn't be too hard to implement a more elegant solution if necessary though. |
An update on this issue, there is now builtin functionality, as of da49b9c, for creating ion products with a thermal velocity distribution. |
Thank you for the update! |
You may be able to improve the time scaling by adjusting particle weights for the beam/ionization products. In magnetized_cooler.py the beam weight is set automatically by Warp based on the number of macroparticles injected eache step rswarp/examples/ionization/magnetized_cooler.py Lines 149 to 150 in da49b9c
Once a species object is instantiated the weight may be adjusted by setting the sw attribute.
This is the intended behavior for the magnetized_cooler example. If you would like to set reflection this can be done by changing the pbound attributes in top from absorb to reflect: rswarp/examples/ionization/magnetized_cooler.py Lines 78 to 80 in da49b9c
Note that wp.top.pboundxy is not explicitly set here but it can also be set to reflect. The second step if you want reflection is to no longer set any conductors to be scrapers. Comment out or remove appropriate conductors from the list in:rswarp/examples/ionization/magnetized_cooler.py Lines 268 to 269 in da49b9c
Conductors that are not scrapers will still be used appropriate in the field solve but particles will pass through them. Hope this helps! |
A user writes:
The text was updated successfully, but these errors were encountered: