diff options
author | 2021-09-22 08:40:10 -0700 | |
---|---|---|
committer | 2021-09-22 08:40:10 -0700 | |
commit | 0f4b2e9fd02bf7b94bf533b310e6947f88d8aba5 (patch) | |
tree | e4ea227fecbdbc723e350eb1d38873e9015cf0ce /Source/Python | |
parent | 39f32c01c580a149ef9f6df39c6bdb0825e59ee3 (diff) | |
download | WarpX-0f4b2e9fd02bf7b94bf533b310e6947f88d8aba5.tar.gz WarpX-0f4b2e9fd02bf7b94bf533b310e6947f88d8aba5.tar.zst WarpX-0f4b2e9fd02bf7b94bf533b310e6947f88d8aba5.zip |
External Poisson solver: wrappers to copy the full domain rho and phi between C++ and Python (#2285)
* added missing parts to allow an external Poisson solver to be used instead of the MLMG solver
* added rho and phi wrappers to fields.py
* added an example of using an external Poisson solver
* need to run PICMI test on 2 processors same as non-PICMI version in order to compare plotfiles
* changes requested during PR review
* pass dictionary to eval statement when calculating boundary potential
Diffstat (limited to 'Source/Python')
-rw-r--r-- | Source/Python/WarpXWrappers.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/Python/WarpXWrappers.cpp b/Source/Python/WarpXWrappers.cpp index 921dc6b4f..42128c76d 100644 --- a/Source/Python/WarpXWrappers.cpp +++ b/Source/Python/WarpXWrappers.cpp @@ -336,6 +336,7 @@ extern "C" int* warpx_getJy_nodal_flag() {return getFieldNodalFlagData( WarpX::GetInstance().getcurrent(0,1) );} int* warpx_getJz_nodal_flag() {return getFieldNodalFlagData( WarpX::GetInstance().getcurrent(0,2) );} int* warpx_getRho_nodal_flag() {return getFieldNodalFlagData( WarpX::GetInstance().getrho_fp(0) );} + int* warpx_getPhi_nodal_flag() {return getFieldNodalFlagData( WarpX::GetInstance().getphi_fp(0) );} #define WARPX_GET_SCALAR(SCALAR, GETTER) \ amrex::Real** SCALAR(int lev, \ @@ -357,6 +358,10 @@ extern "C" WARPX_GET_LOVECTS_SCALAR(warpx_getChargeDensityCPLoVects, WarpX::GetInstance().getrho_cp) WARPX_GET_LOVECTS_SCALAR(warpx_getChargeDensityFPLoVects, WarpX::GetInstance().getrho_fp) + WARPX_GET_SCALAR(warpx_getPhiFP, WarpX::GetInstance().getphi_fp) + + WARPX_GET_LOVECTS_SCALAR(warpx_getPhiFPLoVects, WarpX::GetInstance().getphi_fp) + #define WARPX_GET_FIELD_PML(FIELD, GETTER) \ amrex::Real** FIELD(int lev, int direction, \ int *return_size, int *ncomps, int **ngrowvect, int **shapes) { \ |