##### trsv

###### Prototype

There is one prototype of `trsv` available, please see below.

    trsv( const MatrixA& a, VectorX& x );

###### Description

`trsv` (short for triangular solve system of equations) provides a C++ interface to BLAS routines STRSV, DTRSV, CTRSV, and ZTRSV. `trsv` solves one of the systems of equations

A*x = b, or A'*x = b, or conjg( A' )*x = b,

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

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

The selection of the BLAS routine is done during compile-time, and is determined by the type of values contained in type `MatrixA`. The type of values is obtained through the `value_type` meta-function `typename value_type<MatrixA>::type`. Table X below illustrates to which specific routine this dispatching will take place.

Table 1.80. Dispatching of trsv.

Value type of MatrixA | BLAS routine | CBLAS routine | CUBLAS routine
--- | --- | --- | ---
`float` | STRSV | cblas_strsv | cublasStrsv
`double` | DTRSV | cblas_dtrsv | cublasDtrsv
`complex<float>` | CTRSV | cblas_ctrsv | cublasCtrsv
`complex<double>` | ZTRSV | cblas_ztrsv | Unavailable

The original routines STRSV, DTRSV, CTRSV, and ZTRSV have eight arguments, whereas `trsv` requires two arguments.

Table 1.81. Deduction of arguments of trsv.

###### Definition

Defined in header `boost/numeric/bindings/blas/level2/trsv.hpp`.

###### Parameters or Requirements on Types

Parameters

MatrixA

  The definition of term 1

MatrixB

  The definition of term 2

MatrixC

  The definition of term 3.

  Definitions may contain paragraphs.

###### Complexity

###### Example

    #include <boost/numeric/bindings/blas/level2/trsv.hpp>
    using namespace boost::numeric::bindings;

    blas::trsv( x, y, z );

this will output

    [5] 0 1 2 3 4 5

###### Notes

###### See Also

- Originating Fortran source files strsv.f, dtrsv.f, ctrsv.f, and ztrsv.f at Netlib.