-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
B=0 field output in magnetostatic mode #5242
Comments
Hi @jwestern. That is strange. Could you please provide a bit more information about the simulation:
|
@jwestern could you share an input deck or reproducer so we can take a look at it? Can you share what sort of current source you have? Particle injection? |
@clarkse I'll work on a reproducer. The issue arises either with particles initialized at t=0 or with injection over time. The runtime is slower with magnetostatic mode on, suggesting there is extra work being done. But the field diagnostic output gives B=0. |
@clarkse @roelof-groenewald Here's a reproducer PICMI .py file (I had to rename is .txt in order to attach): |
@jwestern Thank you for sending this over. There appears to be an issue with how the B field is calculated from A when not using an embedded boundary. As a work around you can compile with EB support. There is an example in Examples/Tests/magnetostatic_eb that still passes CI. You can probably adapt it to have a box EB for now. I will look at fixing the bug soon so you don't need to use an embedded boundary. |
@clarkse great, thank you! I'll wait for the bug fix, because compiling with EB support reduces the reliability of the Poisson solve to a level where I cannot use it. |
Thanks for tracking down the issue @jwestern and @clarkse. @jwestern there's a WIP PR that actually fixes this bug (see #5175) but I won't have time in the next few weeks to finish up that PR. If you wanted to you could take a look at how the issue is fixed in that PR and maybe cherry-pick those parts to create an intermediate PR focused on just fixing this bug (without all the other refactoring done in the WIP PR). |
I get zero magnetic field in the field output running with the magnetostatic solver on.
I'm running in electromagnetostatic mode via PICMI. I setup the solver like this:
And I install the field diagnostic like this:
This happens with both GPU and CPU runs.
Does anyone know what's going on? Let me know if other details are needed, such as the creation of
grid
orsim
.The text was updated successfully, but these errors were encountered: