/// <summary> /// Applies this transformation to the given vector. /// </summary> /// <param name="vector"></param> /// <returns></returns> public Vec2d Apply(Vec2d vector) { return(new Vec2d( Vec2d.Dot(Row0, vector), Vec2d.Dot(Row1, vector) )); }
/// <summary> /// Matrix vector multiplication /// </summary> /// <returns></returns> public static Vec2d Multiply(ref Matrix2d matrix, Vec2d vector) { return(new Vec2d( Vec2d.Dot(vector, matrix.Row0), Vec2d.Dot(vector, matrix.Row1) )); }
/// <summary> /// Applies the inverse of this rotation to the given vector. /// </summary> /// <param name="vector"></param> /// <returns></returns> public Vec2d ApplyInverse(Vec2d vector) { return(new Vec2d(Vec2d.Dot(vector, X), Vec2d.Dot(vector, Y))); }