# Defining Current Density in a FEM model (MATLAB)

I'm attempting to solve the Poisson equation in 3D for a magnetic vector potential in the presence of a current source. To validate my code, I'm initially looking to reproduce the model described in the following pair of papers:

The paper gives the following figure to describe the coil which carries the current:

Alongside the following parameters:

• 20 Amps of current.
• Wire is of type AWG #16 with 861 turns
• Winding Height (Z axis): 8.89cm
• Outer Boundary Cross Section: 15.24 cm x 15.24 cm
• Inner Boundary Cross Section: 10.42 cm x 10.42 cm

I also know that the current density should be homogeneous in a specific element. In this model Jz = 0 throughout and I know J = N*I / A, where A is the cross sectional area, N the number of turns and I the current.

Defining current density in this system can be done by considering the average current density within the winding region, $$J_{0}$$ (then subdividing this into elements). For winding height h, Inner cross section $$L_{1}$$, Outer cross section $$L_{2}$$ with N turns carrying current I:
$$J_{0} = \frac{IN}{h(L_{2} - L_{1})/2}$$.