Since p and B z are constants along a field line, and functions only of A , hence ∇ ∇ p = d p d A ∇ ∇ A and ∇ ∇ B z = d B z d A ∇ ∇ A . Thus, factoring out ∇ ∇ A and rearranging terms yields the Grad–Shafranov equation : ∇ ∇ 2 A = − − μ μ 0 d d A ( p + B z 2 2 μ μ 0 ) .