The magnetostatic potential due to the magnetization existing in the magnetic media is characterized by a variational principle defined in the whole space. Representing the magnetostatic potential in the exterior of the magnetic media by its values on the boundary of an unbounded exterior space, the variational principle may be re-defined in a finite solution space. Alternatively, if one is willing to determine the potential solution on certain prescribed boundary of a finite space, the variational principle may also be re-defined in the prescribed space. The cost for the savings in the solution space is the representation of the potential in the exterior space for the former case, or the determination of the potential solution on certain prescribed boundary for the second case. © 1982.