Dear @cbenj33
The automatic flux integrator (“Current Extractor”) works when it is possible to clearly separate an anode and a cathode. It is not suitable for cases with multiple sources.
The reason is that the software chooses the isosurface for the numerical surface integral of the current density J as the surface where the potential equals the average between the two Dirichlet (voltage) boundary conditions. This default choice ensures that the surface is not too close to the electrodes, where the E- and J-field gradients are high, and where small discretization errors could lead to large uncertainties in the integrated flux.
However, there is an option to adjust the isosurface to a different percentage of the potential difference. This setting—“Iso surface level as percentage of the potential difference”—lets you move the surface closer to one electrode (e.g., 10%) or the other (e.g., 90%). A value of 50% corresponds to the default midpoint. I do not recommend placing the surface too close to the electrodes for the reasons explained above.
[image: 1755072017016-flux.png]
The “Surface refinement” option allows you to increase the discretization density on the surface. You can perform a convergence analysis by refining the surface until the extracted current changes by only a few percent or less.
That said, the user can also perform this operation manually. You can create any closed surface that encloses one electrode—or that divides the computational domain into two parts, each containing either the anode or the cathode—and use this surface to interpolate the J-field. After interpolation, the software provides the option to calculate the flux.
I assume you are using the LF Ohmic Current dominated solver. Since you know the voltage applied between the contacts and the current through the electrode for that voltage, you can simply apply Ohm’s law to determine the voltage needed for a desired current. Alternatively, you can use the “Multiplier” function in the Field Data Tools to scale the E- or E-potential field to the desired current by applying the factor:
scaling factor = I_desired/I_measured
In my EM–neuronal coupled simulations, I usually use the multiplier method and link the neuronal simulation via the Analysis/Cache option in the source settings, selecting the multiplier applied to the E-potential.
I hope this clears up your doubts.
All the best!