There are two prototypes of larfg
available, please see below.
larfg( const int_t n, Scalar >, VectorX& x, Scalar > );
larfg( const int_t n, Scalar& alpha, VectorX& x, Scalar& tau );
larfg (short for $FRIENDLY_NAME)
provides a C++ interface to LAPACK routines SLARFG, DLARFG, CLARFG, and
ZLARFG. larfg generates
a complex elementary reflector H of order n, such that
H' * ( alpha ) = ( beta ), H' * H = I. ( x ) ( 0 )
where alpha and beta are scalars, with beta real, and x is an (n-1)-element complex vector. H is represented in the form
H = I - tau * ( 1 ) * ( 1 v' ) , ( v )
where tau is a complex scalar and v is a complex (n-1)-element vector. Note that H is not hermitian.
If the elements of x are all zero and alpha is real, then tau = 0 and H is taken to be the unit matrix.
Otherwise 1 <= real(tau) <= 2 and abs(tau-1) <= 1 .
The selection of the LAPACK routine is done during compile-time, and
is determined by the type of values contained in type VectorX.
The type of values is obtained through the value_type
meta-function typename value_type<VectorX>::type. The dispatching table below illustrates
to which specific routine the code path will be generated.
Table 1.342. Dispatching of larfg
|
Value type of VectorX |
LAPACK routine |
|---|---|
|
|
SLARFG |
|
|
DLARFG |
|
|
CLARFG |
|
|
ZLARFG |
Defined in header boost/numeric/bindings/lapack/auxiliary/larfg.hpp.
Parameters
The definition of term 1
The definition of term 2
The definition of term 3.
Definitions may contain paragraphs.
#include <boost/numeric/bindings/lapack/auxiliary/larfg.hpp> using namespace boost::numeric::bindings; lapack::larfg( x, y, z );
this will output
[5] 0 1 2 3 4 5