Table of Contents

NAME

QccMatrixNullspace - generate orthonormal basis for nullspace of matrix

SYNOPSIS

#include "libQccPack.h"

int QccMatrixNullspace(const QccMatrix matrix1, int num_rows, i num_cols, QccMatrix matrix2, int *num_cols2);

DESCRIPTION

QccMatrixNullspace() creates an orthonormal basis for the nullspace of matrix1 which is a matrix of size num_rows x num_cols. This orthonormal basis is returned as the columns of matrix2; that is, the columns of matrix2 span the space that is orthogonal to the space spanned by the columns of matrix1. matrix2 must be allocated to be of size num_cols x num_cols prior to calling QccMatrixNullspace() (Note: this is not num_rows x num_cols!)

The number of basis vectors in the orthogonal nullspace basis is returned as num_cols2; num_cols2 will be less than num_cols. matrix2 will contain num_cols - num_cols2 columns of zeros. If matrix1 is of full rank, num_cols2 will be zero, and matrix2 will be all zero.

QccMatrixNullspace() is implemented via a call to QccMatrixSVD(3) to generate the singular value decomposition of matrix1. Then, the right singular vectors corresponding to zero singular values, if any, are returned in matrix2.

SEE ALSO

QccMatrixSVD(3) , QccMatrix(3) , QccPack(3)

AUTHOR

Copyright (C) 1997-2021 James E. Fowler


Table of Contents



Get QccPack at SourceForge.net. Fast, secure and Free Open Source software downloads