svd_matrixT_svd_matrixSvdMatrixSvdMatrix (Operator)

Name

svd_matrixT_svd_matrixSvdMatrixSvdMatrix — Berechnet die Singulärwertzerlegung einer Matrix.

Signatur

svd_matrix( : : MatrixID, SVDType, ComputeSingularVectors : MatrixUID, MatrixSID, MatrixVID)

Herror T_svd_matrix(const Htuple MatrixID, const Htuple SVDType, const Htuple ComputeSingularVectors, Htuple* MatrixUID, Htuple* MatrixSID, Htuple* MatrixVID)

void SvdMatrix(const HTuple& MatrixID, const HTuple& SVDType, const HTuple& ComputeSingularVectors, HTuple* MatrixUID, HTuple* MatrixSID, HTuple* MatrixVID)

HMatrix HMatrix::SvdMatrix(const HString& SVDType, const HString& ComputeSingularVectors, HMatrix* MatrixSID, HMatrix* MatrixVID) const

HMatrix HMatrix::SvdMatrix(const char* SVDType, const char* ComputeSingularVectors, HMatrix* MatrixSID, HMatrix* MatrixVID) const

HMatrix HMatrix::SvdMatrix(const wchar_t* SVDType, const wchar_t* ComputeSingularVectors, HMatrix* MatrixSID, HMatrix* MatrixVID) const   (Nur Windows)

static void HOperatorSet.SvdMatrix(HTuple matrixID, HTuple SVDType, HTuple computeSingularVectors, out HTuple matrixUID, out HTuple matrixSID, out HTuple matrixVID)

HMatrix HMatrix.SvdMatrix(string SVDType, string computeSingularVectors, out HMatrix matrixSID, out HMatrix matrixVID)

Beschreibung

Der Operator svd_matrixsvd_matrixSvdMatrixSvdMatrixSvdMatrix berechnet die volle oder reduzierte Singulärwertzerlegung (SVD) der Matrix MatrixMatrixMatrixMatrixmatrix, die durch das Matrix Handle MatrixIDMatrixIDMatrixIDMatrixIDmatrixID gegeben ist. Der Operator gibt das Matrix Handle MatrixSIDMatrixSIDMatrixSIDMatrixSIDmatrixSID der Matrix MatrixSMatrixSMatrixSMatrixSmatrixS mit den Singulärwerten in absteigender Reihenfolge zurück. Optional werden die Matrizen MatrixUMatrixUMatrixUMatrixUmatrixU mit den linken und MatrixVMatrixVMatrixVMatrixVmatrixV mit den rechten Singulärvektoren ebenfalls berechnet und deren Matrix Handles MatrixUIDMatrixUIDMatrixUIDMatrixUIDmatrixUID und MatrixVIDMatrixVIDMatrixVIDMatrixVIDmatrixVID zurückgegeben. Zugriff auf die Elemente der Matrix ist z.B. mit dem Operator get_full_matrixget_full_matrixGetFullMatrixGetFullMatrixGetFullMatrix möglich. Die SVD hat die Form

Ist SVDTypeSVDTypeSVDTypeSVDTypeSVDType = 'full'"full""full""full""full" gesetzt, wird eine volle SVD berechnet.

Ist SVDTypeSVDTypeSVDTypeSVDTypeSVDType = 'reduced'"reduced""reduced""reduced""reduced" gesetzt, wird eine reduzierte SVD berechnet.

Die Matrix MatrixUMatrixUMatrixUMatrixUmatrixU mit den linken Singulärvektoren wird berechnet, wenn ComputeSingularVectorsComputeSingularVectorsComputeSingularVectorsComputeSingularVectorscomputeSingularVectors = 'left'"left""left""left""left" gesetzt ist. Die Matrix MatrixVMatrixVMatrixVMatrixVmatrixV mit den rechten Singulärvektoren wird berechnet, wenn ComputeSingularVectorsComputeSingularVectorsComputeSingularVectorsComputeSingularVectorscomputeSingularVectors = 'right'"right""right""right""right" gesetzt ist. Die Matrizen mit den linken und rechten Singulärvektoren werden berechnet, wenn ComputeSingularVectorsComputeSingularVectorsComputeSingularVectorsComputeSingularVectorscomputeSingularVectors = 'both'"both""both""both""both" gesetzt ist.

Wenn ComputeSingularVectorsComputeSingularVectorsComputeSingularVectorsComputeSingularVectorscomputeSingularVectors = 'none'"none""none""none""none" gesetzt ist, werden keine Matrizen mit den Singulärvektoren berechnet. Die Matrix MatrixSMatrixSMatrixSMatrixSmatrixS ist eine Matrix mit n Zeilen und einer Spalte, wobei n = min(Anzahl der Zeilen der Eingabematrix MatrixMatrixMatrixMatrixmatrix, Anzahl der Spalten der Eingabematrix MatrixMatrixMatrixMatrixmatrix).

Es ist zu beachten, dass in den Beispielen Unterschiede in der Bedeutung der Werte in den Ausgabematrizen zu finden sind: Wenn ein Wert als ganze Zahl dargestellt ist, z.B. 0 oder 1, ist der Wert dieses Elements per Definition dieser bestimmte Wert. Wenn der Wert als Gleitpunktzahl dargestellt ist, z.B. 0.0 oder 1.0, ist der Wert von dem Operator berechnet worden.

Ausführungsinformationen

Parameter

MatrixIDMatrixIDMatrixIDMatrixIDmatrixID (input_control)  matrix HMatrix, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle der Eingabematrix.

SVDTypeSVDTypeSVDTypeSVDTypeSVDType (input_control)  string HTupleHTupleHtuple (string) (string) (HString) (char*)

Berechnungstyp.

Defaultwert: 'full' "full" "full" "full" "full"

Werteliste: 'full'"full""full""full""full", 'reduced'"reduced""reduced""reduced""reduced"

ComputeSingularVectorsComputeSingularVectorsComputeSingularVectorsComputeSingularVectorscomputeSingularVectors (input_control)  string HTupleHTupleHtuple (string) (string) (HString) (char*)

Berechnung der Singulärwerte.

Defaultwert: 'both' "both" "both" "both" "both"

Werteliste: 'both'"both""both""both""both", 'left'"left""left""left""left", 'none'"none""none""none""none", 'right'"right""right""right""right"

MatrixUIDMatrixUIDMatrixUIDMatrixUIDmatrixUID (output_control)  matrix HMatrix, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle mit den linken Singulärvektoren.

MatrixSIDMatrixSIDMatrixSIDMatrixSIDmatrixSID (output_control)  matrix HMatrix, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle mit den Singulärwerten.

MatrixVIDMatrixVIDMatrixVIDMatrixVIDmatrixVID (output_control)  matrix HMatrix, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle mit den rechten Singulärvektoren.

Ergebnis

Sind die Parameterwerte korrekt, dann liefert svd_matrixsvd_matrixSvdMatrixSvdMatrixSvdMatrix den Wert 2 (H_MSG_TRUE). Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Vorgänger

create_matrixcreate_matrixCreateMatrixCreateMatrixCreateMatrix

Nachfolger

get_full_matrixget_full_matrixGetFullMatrixGetFullMatrixGetFullMatrix, get_value_matrixget_value_matrixGetValueMatrixGetValueMatrixGetValueMatrix

Literatur

David Poole: „Linear Algebra: A Modern Introduction“; Thomson; Belmont; 2006.
Gene H. Golub, Charles F. van Loan: „Matrix Computations“; The Johns Hopkins University Press; Baltimore and London; 1996.

Modul

Foundation