LAPACK  3.7.1
LAPACK: Linear Algebra PACKage

◆ LAPACKE_cuncsd_work()

lapack_int LAPACKE_cuncsd_work ( int  matrix_layout,
char  jobu1,
char  jobu2,
char  jobv1t,
char  jobv2t,
char  trans,
char  signs,
lapack_int  m,
lapack_int  p,
lapack_int  q,
lapack_complex_float x11,
lapack_int  ldx11,
lapack_complex_float x12,
lapack_int  ldx12,
lapack_complex_float x21,
lapack_int  ldx21,
lapack_complex_float x22,
lapack_int  ldx22,
float *  theta,
lapack_complex_float u1,
lapack_int  ldu1,
lapack_complex_float u2,
lapack_int  ldu2,
lapack_complex_float v1t,
lapack_int  ldv1t,
lapack_complex_float v2t,
lapack_int  ldv2t,
lapack_complex_float work,
lapack_int  lwork,
float *  rwork,
lapack_int  lrwork,
lapack_int iwork 
)

Definition at line 36 of file lapacke_cuncsd_work.c.

51 {
52  lapack_int info = 0;
53  /* LAPACK function works with matrices in both layouts. It is supported
54  * through TRANS parameter. So all conversion between layouts can be
55  * completed in LAPACK function. See the table below which describes how
56  * every LAPACKE call is forwarded to corresponding LAPACK call.
57  *
58  * matrix_layout | trans_LAPACKE | -> trans_LAPACK
59  * | (trans) | (ltrans)
60  * -----------------+---------------+----------------
61  * LAPACK_COL_MAJOR | 'N' | -> 'N'
62  * LAPACK_COL_MAJOR | 'T' | -> 'T'
63  * LAPACK_ROW_MAJOR | 'N' | -> 'T'
64  * LAPACK_ROW_MAJOR | 'T' | -> 'T'
65  * (note that for row major layout trans parameter is ignored)
66  */
67  if( matrix_layout == LAPACK_COL_MAJOR ||
68  matrix_layout == LAPACK_ROW_MAJOR ) {
69  char ltrans;
70  if( !LAPACKE_lsame( trans, 't' ) && matrix_layout == LAPACK_COL_MAJOR ) {
71  ltrans = 'n';
72  } else {
73  ltrans = 't';
74  }
75  /* Call LAPACK function and adjust info */
76  LAPACK_cuncsd( &jobu1, &jobu2, &jobv1t, &jobv2t, &ltrans, &signs, &m,
77  &p, &q, x11, &ldx11, x12, &ldx12, x21, &ldx21, x22,
78  &ldx22, theta, u1, &ldu1, u2, &ldu2, v1t, &ldv1t, v2t,
79  &ldv2t, work, &lwork, rwork, &lrwork, iwork, &info );
80  if( info < 0 ) {
81  info = info - 1;
82  }
83  } else {
84  info = -1;
85  LAPACKE_xerbla( "LAPACKE_cuncsd_work", info );
86  }
87  return info;
88 }
void LAPACK_cuncsd(char *jobu1, char *jobu2, char *jobv1t, char *jobv2t, char *trans, char *signs, lapack_int *m, lapack_int *p, lapack_int *q, lapack_complex_float *x11, lapack_int *ldx11, lapack_complex_float *x12, lapack_int *ldx12, lapack_complex_float *x21, lapack_int *ldx21, lapack_complex_float *x22, lapack_int *ldx22, float *theta, lapack_complex_float *u1, lapack_int *ldu1, lapack_complex_float *u2, lapack_int *ldu2, lapack_complex_float *v1t, lapack_int *ldv1t, lapack_complex_float *v2t, lapack_int *ldv2t, lapack_complex_float *work, lapack_int *lwork, float *rwork, lapack_int *lrwork, lapack_int *iwork, lapack_int *info)
#define LAPACK_ROW_MAJOR
Definition: lapacke.h:119
lapack_logical LAPACKE_lsame(char ca, char cb)
Definition: lapacke_lsame.c:36
#define LAPACK_COL_MAJOR
Definition: lapacke.h:120
void LAPACKE_xerbla(const char *name, lapack_int info)
#define lapack_int
Definition: lapacke.h:47
Here is the call graph for this function:
Here is the caller graph for this function: