LAPACK  3.6.1 LAPACK: Linear Algebra PACKage
 int main ( int argc, const char * argv[] )

Definition at line 66 of file example_DGELS_rowmajor.c.

67 {
68  /* Locals */
69  double A[5][3] = {1,1,1,2,3,4,3,5,2,4,2,5,5,4,3};
70  double b[5][2] = {-10,-3,12,14,14,12,16,16,18,16};
71  lapack_int info,m,n,lda,ldb,nrhs;
72  int i,j;
73
74  /* Initialization */
75  m = 5;
76  n = 3;
77  nrhs = 2;
78  lda = 3;
79  ldb = 2;
80
81  /* Print Entry Matrix */
82  print_matrix_rowmajor( "Entry Matrix A", m, n, *A, lda );
83  /* Print Right Rand Side */
84  print_matrix_rowmajor( "Right Hand Side b", n, nrhs, *b, ldb );
85  printf( "\n" );
86
87  /* Executable statements */
88  printf( "LAPACKE_dgels (row-major, high-level) Example Program Results\n" );
89  /* Solve least squares problem*/
90  info = LAPACKE_dgels(LAPACK_ROW_MAJOR,'N',m,n,nrhs,*A,lda,*b,ldb);
91
92  /* Print Solution */
93  print_matrix_rowmajor( "Solution", n, nrhs, *b, ldb );
94  printf( "\n" );
95  exit( 0 );
96 } /* End of LAPACKE_dgels Example */
lapack_int LAPACKE_dgels(int matrix_layout, char trans, lapack_int m, lapack_int n, lapack_int nrhs, double *a, lapack_int lda, double *b, lapack_int ldb)
Definition: lapacke_dgels.c:36
#define LAPACK_ROW_MAJOR
Definition: lapacke.h:119
#define lapack_int
Definition: lapacke.h:47
void print_matrix_rowmajor(char *desc, lapack_int m, lapack_int n, double *mat, lapack_int ldm)

Here is the call graph for this function: