Warwick-Plasma / epoch

Particle-in-cell code for plasma physics simulations
https://epochpic.github.io
GNU General Public License v3.0
184 stars 58 forks source link

Regarding issues related to the dist_fn_block module #733

Open bear-maker opened 3 weeks ago

bear-maker commented 3 weeks ago

Dear Professor Thank you very much for your help during this period. I have taken your advice and tilted the target as shown in the following picture. The x-y coordinate axis is correspondingly converted to x '- y' (rotated 45 °). My current question is: Can I output the momentum distribution function in the direction of x '- px' through the dist_fn_block module;

FE(4G2O_C Z DZPXE8APC)B

I have only found the distribution function settings for x-px as shown in the following figure. I am looking forward to your answer, Professor. Sincerely thank you for your help and wish you a happy life.

L)ZL_2ZUV3VKC`6{F3S(~@X

Status-Mirror commented 3 weeks ago

Good question! I've not thought about this as a possible feature before, but I can see cases where it would be useful.

Currently the dist_fn block lacks this ability. If you're confident with FORTRAN, you could add this capability yourself into the general_dist_fn subroutine of src/io/dist_fn.F90.

The easier solution would be to dump the x, y, px, py and weight values of each particle, and write post-processing code to manually bin them. This will require a lot more CPU memory than the dist_fn output though.

I'll mark this as a potential enhancement, but our developers are currently busy so I wouldn't expect this within the next few weeks.

Hope this helps, Stuart

bear-maker commented 3 weeks ago

Good question! I've not thought about this as a possible feature before, but I can see cases where it would be useful.

Currently the dist_fn block lacks this ability. If you're confident with FORTRAN, you could add this capability yourself into the general_dist_fn subroutine of src/io/dist_fn.F90.

The easier solution would be to dump the x, y, px, py and weight values of each particle, and write post-processing code to manually bin them. This will require a lot more CPU memory than the dist_fn output though.

I'll mark this as a potential enhancement, but our developers are currently busy so I wouldn't expect this within the next few weeks.

Hope this helps, Stuart

Thank you very much for your patient response during this period, Professor. We look forward to your ability to create even better software.