CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   Magnetic Field Unphysical Results at Processor Boundaries (https://www.cfd-online.com/Forums/openfoam-programming-development/245925-magnetic-field-unphysical-results-processor-boundaries.html)

schradc November 2, 2022 23:08

Magnetic Field Unphysical Results at Processor Boundaries
 
5 Attachment(s)
Hello,

I am trying to calculate the magnetic field induced by a current density field given by

\nabla^{2}\vec{B}=-\mu\nabla\times\vec{J}

Where B is the magnetic field, J is the current density and mu is the magnetic permiability.

I have implemented this equation as

Code:

solve(fvm::laplacian(B) == -magPerm * fvc::curl(Je));
I set up a simple case with uniform current density traveling down a circular conductor. The anticipated results are a magnetic field which approaches 0 on the centerline and increases in strength to the outer surface. Additionally, the magnetic field is expected to have a clockwise rotation.

This expected behavior is observed when run in serial as shown in the first two images.

However, when run in parallel, I get unphysical results with a pattern consistent with the borders between processors. The subdomains for the 4 processors can be seen in the third attachment and the magnetic field results in the last two figures.

Does anyone have any ideas as to why this behavior would occur in parallel? Is there anything wrong with the line I implemented?

Many thanks.


All times are GMT -4. The time now is 02:21.