Skip site navigation (1)Skip section navigation (2)

  
 
  

home | help
HPL_dtrsv(3)		      HPL Library Functions		    HPL_dtrsv(3)

NAME
     HPL_dtrsv - x := A^{-1} x.

SYNOPSIS
     #include "hpl.h"

     void HPL_dtrsv( const enum HPL_ORDER ORDER, const enum HPL_UPLO UPLO, const
     enum HPL_TRANS TRANS, const enum HPL_DIAG DIAG, const int N, const double *
     A, const int LDA, double * X, const int INCX );

DESCRIPTION
     HPL_dtrsv solves one of the systems of equations

	 A * x = b,   or   A^T * x = b,

     where b and x are n-element vectors and  A  is an n by n non-unit, or unit,
     upper or lower triangular matrix.

     No  test for  singularity	or  near-singularity  is included  in  this rou-
     tine. Such tests must be performed before calling this routine.

ARGUMENTS
     ORDER   (local input)	     const enum HPL_ORDER
	     On entry, ORDER  specifies the storage format of  the  operands  as
	     follows:
		ORDER = HplRowMajor,
		ORDER = HplColumnMajor.

     UPLO    (local input)	     const enum HPL_UPLO
	     On   entry,   UPLO   specifies  whether  the  upper  or  lower tri-
	     angular  part   of  the  array   A   is  to  be  referenced.   When
	     UPLO==HplUpper,  only  the upper triangular part of A is to be ref-
	     erenced, otherwise only the lower triangular part of  A  is  to  be
	     referenced.

     TRANS   (local input)	     const enum HPL_TRANS
	     On  entry,  TRANS	specifies  the equations  to  be  solved as fol-
	     lows:
		TRANS==HplNoTrans     A   * x = b,
		TRANS==HplTrans       A^T * x = b.

     DIAG    (local input)	     const enum HPL_DIAG
	     On entry,	DIAG  specifies  whether  A  is unit triangular or  not.
	     When DIAG==HplUnit,  A is assumed to be unit triangular, and other-
	     wise, A is not assumed to be unit triangular.

     N	     (local input)	     const int
	     On entry, N specifies the order of the matrix A. N must be at least
	     zero.

     A	     (local input)	     const double *
	     On  entry,  A  points  to an array of size equal to or greater than
	     LDA * n. Before entry with  UPLO==HplUpper,  the leading n by n up-
	     per triangular  part of the array A must contain the upper triangu-
	     lar  matrix and the  strictly  lower  triangular part of A  is  not
	     referenced.   When   UPLO==HplLower   on entry, the  leading n by n
	     lower triangular part of the array A must contain the lower  trian-
	     gular  matrix  and  the  strictly upper triangular part of A is not
	     referenced.

	     Note  that  when  DIAG==HplUnit,  the diagonal elements of   A  not
	     referenced  either,  but are assumed to be unity.

     LDA     (local input)	     const int
	     On  entry,   LDA  specifies  the  leading	dimension  of  A  as de-
	     clared  in  the  calling  (sub) program.  LDA  must  be   at  least
	     MAX(1,n).

     X	     (local input/output)    double *
	     On entry,	X  is an incremented array of dimension  at  least ( 1 +
	     ( n - 1 ) * abs( INCX ) )	that  contains the vector x.  Before en-
	     try,  the	incremented array  X  must contain  the n element right-
	     hand  side  vector b. On exit,  X	is overwritten with the solution
	     vector x.

     INCX    (local input)	     const int
	     On entry, INCX specifies the increment for the elements of X.  INCX
	     must not be zero.

EXAMPLE
     #include "hpl.h"

     int main(int argc, char *argv[])
     {
	double a[2*2], x[2];
	a[0] = 4.0; a[1] = 1.0; a[2] = 2.0; a[3] = 5.0;
	x[0] = 2.0; x[1] = 1.0;
	HPL_dtrsv( HplColumnMajor, HplLower, HplNoTrans,
		   HplNoUnit, a, 2, x, 1 );
	printf("x=[%f,%f]\n", x[0], x[1]);
	exit(0); return(0);
     }

SEE ALSO
     HPL_dger (3), HPL_dgemv (3).

HPL 2.3 			December 2, 2018		    HPL_dtrsv(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=HPL_dtrsv&sektion=3&manpath=FreeBSD+Ports+15.1.quarterly>

home | help