piclas-framework / piclas

PICLas is a parallel, three-dimensional PIC-DSMC solver developed cooperatively by the Institute of Space Systems, Institute of Aerodynamics and Gas Dynamics at the University of Stuttgart and the spin-off boltzplatz. PICLas is a flexible particle-based plasma simulation suite.
https://piclas.readthedocs.io
GNU General Public License v3.0
74 stars 17 forks source link

Cannot use cross-section data with regular DSMC #23

Closed BillyTheKidPhysicist closed 2 months ago

BillyTheKidPhysicist commented 6 months ago

I'm not sure if this is a bug, but I cannot implement cross-section data between DSMC particles. If I have two species, 1 and 2, I can produce the expected behaviour of collisions between species 1 and 2 if species 1 is a background gas of density n with provided cross section data. If instead I make species 1 DSMC particles of density n there appears to be no collisions of any kind, even elastic. I also have to circumvent the error that this cross-section collisions are only implemented with background gas. The documentation states "It should be noted that this model is not limited to the utilization with MCC or a background gas and can be used with conventional DSMC as an alternative chemistry model". This leads me to believe I should be able to use the cross-section data with DSMC particles. I am ensuring that I am using the flag UseCollXSec=T for all species in the DSMC.ini. Thank you very much

BillyTheKidPhysicist commented 6 months ago

I was able to implement the feature by changing dsmc_collision_prob.f90. It appears to give nearly the same results for a simple test case.

pnizenkov commented 2 months ago

Currently, you can only use the cross-section data for the probability of a chemical reaction in DSMC, however, the regular collision has to be performed using the standard collision modelling, thus the abort. If you like, you can share your extension together with a small test case so we could implement it in an upcoming release.

pnizenkov commented 2 months ago

Closing due to inactivity.