added magrspline and magzspline for general use