diff options
author | 2017-03-28 11:11:12 -0700 | |
---|---|---|
committer | 2017-03-28 11:11:12 -0700 | |
commit | 85d6218a3a8838521c495c12bf00942085bc3c8c (patch) | |
tree | 190f2acc98019f325a0f595b54103a0eade478d3 /Python/pywarpx | |
parent | 6151dc4888aa6c9571aaf06a89e795bb1f20caf7 (diff) | |
download | WarpX-85d6218a3a8838521c495c12bf00942085bc3c8c.tar.gz WarpX-85d6218a3a8838521c495c12bf00942085bc3c8c.tar.zst WarpX-85d6218a3a8838521c495c12bf00942085bc3c8c.zip |
updating the python-ctypes branch for recent changes in master
Diffstat (limited to 'Python/pywarpx')
-rw-r--r-- | Python/pywarpx/AMReX.py | 3 | ||||
-rw-r--r-- | Python/pywarpx/Particles.py | 15 |
2 files changed, 17 insertions, 1 deletions
diff --git a/Python/pywarpx/AMReX.py b/Python/pywarpx/AMReX.py index e84c240af..0cf9290b8 100644 --- a/Python/pywarpx/AMReX.py +++ b/Python/pywarpx/AMReX.py @@ -6,7 +6,7 @@ from .Geometry import geometry from .Algo import algo from .Langmuirwave import langmuirwave from .Interpolation import interpolation -from .Particles import particles +from .Particles import particles, electrons import ctypes from ._libwarpx import libwarpx @@ -23,6 +23,7 @@ class AMReX(object): argv += langmuirwave.attrlist() argv += interpolation.attrlist() argv += particles.attrlist() + argv += electrons.attrlist() amrex_init(argv) diff --git a/Python/pywarpx/Particles.py b/Python/pywarpx/Particles.py index a11da823d..a166b029e 100644 --- a/Python/pywarpx/Particles.py +++ b/Python/pywarpx/Particles.py @@ -1,3 +1,18 @@ from .Bucket import Bucket particles = Bucket('particles') + +electrons = Bucket('electrons') +electrons.charge = "-q_e" +electrons.mass = "m_e" +electrons.injection_style = "python" + +positrons = Bucket('positrons') +positrons.charge = "q_e" +positrons.mass = "m_e" +positrons.injection_style = "python" + +protons = Bucket('protons') +protons.charge = "q_e" +protons.mass = "m_p" +protons.injection_style = "python" |