Vector.Determinant(Vector, Vector) 方法

定义

计算两个向量的行列式。

public:
 static double Determinant(System::Windows::Vector vector1, System::Windows::Vector vector2);
public static double Determinant (System.Windows.Vector vector1, System.Windows.Vector vector2);
static member Determinant : System.Windows.Vector * System.Windows.Vector -> double
Public Shared Function Determinant (vector1 As Vector, vector2 As Vector) As Double

参数

vector1
Vector

要计算的第一个向量。

vector2
Vector

要计算的第二个向量。

返回

Double

vector1vector2 的行列式。

示例

以下示例演示如何计算两 Vector 个结构的确定性。

private Double determinantExample()
{
    Vector vector1 = new Vector(20, 30);
    Vector vector2 = new Vector(45, 70);
    Double determinant;

    // determinant is equal to 50
    determinant = Vector.Determinant(vector1, vector2);

    return determinant;
}

适用于