entity-toolkit / entity

New generation astrophysical plasma simulation code with CPU/GPU portability
https://entity-toolkit.github.io/wiki/
Other
27 stars 2 forks source link

Leftover charge near the axis when strong U_theta #27

Closed haykh closed 1 year ago

haykh commented 1 year ago

Left: SR, right: GR.

alt text alt text

Only occurs when the particle is reflected off the axis with a large-enough $u_\theta$. Pgen to reproduce: -D pgen=debug/deposit with both engines.

haykh commented 1 year ago

The problem is worse when the velocity is high (ultra-relativistic). Comparison of $\nabla\cdot\boldsymbol{E}$ for ultra-relativistic velocity ($u\theta\approx 1$, top), and sub-relativistic ($u\theta\approx 10^{-2}$, bottom). Near the axis the velocity is purely tangential: $\boldsymbol{u} = \hat{\boldsymbol{\theta}} u_\theta$.

PS. A particle flying in the last cell radially without reflecting leaves no charge behind.

highvel lowvel

haykh commented 1 year ago

The problem also scales with the CFL number. Top: CFL = 0.5, bottom -- CFL = 0.01, for $u_\theta\approx 1.0$.

cfl-0p5 cfl-0p01

haykh commented 1 year ago

Solved in the latest PR #29. Two things needed to be redesigned:

Two fixes:

Left: SR, right: GR

alt text alt text
haykh commented 1 year ago

Merged #29