code: public static Vector fromPolar (double magnitude, double angle) {
          return new Vector(magnitude * Math.cos(angle), magnitude * Math.sin(angle));
      }
docs: Creates a new vector from polar coordinates.