These functions allow fast and easy optimisation of simple magnetic field-generating coil primitives: loops, saddles, and ellipses. One may select arrangements and geometries of these primitives to generate desired magnetic fields, which is done by utilising exact field harmonic expressions generated by specific sets of the primitives.