code: static Vector2d scale(final Tuple2d vector, final double factor) {
          final Vector2d cpy = new Vector2d(vector);
          cpy.scale(factor);
          return cpy;
      }
docs: Scale a vector by a given factor, the input vector is not modified.
  
  @param vector a vector to scale
  @param factor how much the input vector should be scaled
  @return scaled vector