libflame  revision_anchor
Functions
FLA_QR_UT_unb_var1.c File Reference

(r)

Functions

FLA_Error FLA_QR_UT_unb_var1 (FLA_Obj A, FLA_Obj t)
 

Function Documentation

◆ FLA_QR_UT_unb_var1()

FLA_Error FLA_QR_UT_unb_var1 ( FLA_Obj  A,
FLA_Obj  t 
)

References FLA_Apply_H2_UT(), FLA_Cont_with_1x3_to_1x2(), FLA_Cont_with_3x3_to_2x2(), FLA_Househ2_UT(), FLA_Obj_min_dim(), FLA_Part_1x2(), FLA_Part_2x2(), FLA_Repart_1x2_to_1x3(), and FLA_Repart_2x2_to_3x3().

Referenced by FLA_QR_UT_internal().

14 {
15  FLA_Obj ATL, ATR, A00, a01, A02,
16  ABL, ABR, a10t, alpha11, a12t,
17  A20, a21, A22;
18 
19  FLA_Obj tLt, tRt, t0t, tau1, t2t;
20 
21 
22  FLA_Part_2x2( A, &ATL, &ATR,
23  &ABL, &ABR, 0, 0, FLA_TL );
24 
25  FLA_Part_1x2( t, &tLt, &tRt, 0, FLA_LEFT );
26 
27  while ( FLA_Obj_min_dim( ABR ) > 0 ){
28 
29  FLA_Repart_2x2_to_3x3( ATL, /**/ ATR, &A00, /**/ &a01, &A02,
30  /* ************* */ /* ************************** */
31  &a10t, /**/ &alpha11, &a12t,
32  ABL, /**/ ABR, &A20, /**/ &a21, &A22,
33  1, 1, FLA_BR );
34 
35  FLA_Repart_1x2_to_1x3( tLt, /**/ tRt, &t0t, /**/ &tau1, &t2t,
36  1, FLA_RIGHT );
37 
38  /*------------------------------------------------------------*/
39 
40  // Compute tau11 and u21 from alpha11 and a21 such that tau11 and u21
41  // determine a Householder transform H such that applying H from the
42  // left to the column vector consisting of alpha11 and a21 annihilates
43  // the entries in a21 (and updates alpha11).
44  FLA_Househ2_UT( FLA_LEFT,
45  alpha11,
46  a21, tau1 );
47 
48  // / a12t \ = H / a12t \
49  // \ A22 / \ A22 /
50  //
51  // where H is formed from tau11 and u21.
52  FLA_Apply_H2_UT( FLA_LEFT, tau1, a21, a12t,
53  A22 );
54 
55  /*------------------------------------------------------------*/
56 
57  FLA_Cont_with_3x3_to_2x2( &ATL, /**/ &ATR, A00, a01, /**/ A02,
58  a10t, alpha11, /**/ a12t,
59  /* ************** */ /* ************************ */
60  &ABL, /**/ &ABR, A20, a21, /**/ A22,
61  FLA_TL );
62 
63  FLA_Cont_with_1x3_to_1x2( &tLt, /**/ &tRt, t0t, tau1, /**/ t2t,
64  FLA_LEFT );
65  }
66 
67  return FLA_SUCCESS;
68 }
FLA_Error FLA_Househ2_UT(FLA_Side side, FLA_Obj chi_1, FLA_Obj x2, FLA_Obj tau)
Definition: FLA_Househ2_UT.c:16
FLA_Error FLA_Repart_1x2_to_1x3(FLA_Obj AL, FLA_Obj AR, FLA_Obj *A0, FLA_Obj *A1, FLA_Obj *A2, dim_t nb, FLA_Side side)
Definition: FLA_View.c:267
FLA_Error FLA_Repart_2x2_to_3x3(FLA_Obj ATL, FLA_Obj ATR, FLA_Obj *A00, FLA_Obj *A01, FLA_Obj *A02, FLA_Obj *A10, FLA_Obj *A11, FLA_Obj *A12, FLA_Obj ABL, FLA_Obj ABR, FLA_Obj *A20, FLA_Obj *A21, FLA_Obj *A22, dim_t mb, dim_t nb, FLA_Quadrant quadrant)
Definition: FLA_View.c:142
FLA_Error FLA_Apply_H2_UT(FLA_Side side, FLA_Obj tau, FLA_Obj u2, FLA_Obj a1, FLA_Obj A2)
Definition: FLA_Apply_H2_UT.c:13
FLA_Error FLA_Part_2x2(FLA_Obj A, FLA_Obj *A11, FLA_Obj *A12, FLA_Obj *A21, FLA_Obj *A22, dim_t mb, dim_t nb, FLA_Quadrant quadrant)
Definition: FLA_View.c:17
Definition: FLA_type_defs.h:158
FLA_Error FLA_Cont_with_1x3_to_1x2(FLA_Obj *AL, FLA_Obj *AR, FLA_Obj A0, FLA_Obj A1, FLA_Obj A2, FLA_Side side)
Definition: FLA_View.c:475
FLA_Error FLA_Cont_with_3x3_to_2x2(FLA_Obj *ATL, FLA_Obj *ATR, FLA_Obj A00, FLA_Obj A01, FLA_Obj A02, FLA_Obj A10, FLA_Obj A11, FLA_Obj A12, FLA_Obj *ABL, FLA_Obj *ABR, FLA_Obj A20, FLA_Obj A21, FLA_Obj A22, FLA_Quadrant quadrant)
Definition: FLA_View.c:304
FLA_Error FLA_Part_1x2(FLA_Obj A, FLA_Obj *A1, FLA_Obj *A2, dim_t nb, FLA_Side side)
Definition: FLA_View.c:110
dim_t FLA_Obj_min_dim(FLA_Obj obj)
Definition: FLA_Query.c:153