本文整理汇总了C++中LAPACK_Z2INT函数的典型用法代码示例。如果您正苦于以下问题:C++ LAPACK_Z2INT函数的具体用法?C++ LAPACK_Z2INT怎么用?C++ LAPACK_Z2INT使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了LAPACK_Z2INT函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: LAPACKE_zgeevx
lapack_int LAPACKE_zgeevx( int matrix_order, char balanc, char jobvl,
char jobvr, char sense, lapack_int n,
lapack_complex_double* a, lapack_int lda,
lapack_complex_double* w, lapack_complex_double* vl,
lapack_int ldvl, lapack_complex_double* vr,
lapack_int ldvr, lapack_int* ilo, lapack_int* ihi,
double* scale, double* abnrm, double* rconde,
double* rcondv )
{
lapack_int info = 0;
lapack_int lwork = -1;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zgeevx", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_order, n, n, a, lda ) ) {
return -7;
}
#endif
/* Allocate memory for working array(s) */
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,2*n) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Query optimal working array(s) size */
info = LAPACKE_zgeevx_work( matrix_order, balanc, jobvl, jobvr, sense, n, a,
lda, w, vl, ldvl, vr, ldvr, ilo, ihi, scale,
abnrm, rconde, rcondv, &work_query, lwork,
rwork );
if( info != 0 ) {
goto exit_level_1;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
/* Call middle-level interface */
info = LAPACKE_zgeevx_work( matrix_order, balanc, jobvl, jobvr, sense, n, a,
lda, w, vl, ldvl, vr, ldvr, ilo, ihi, scale,
abnrm, rconde, rcondv, work, lwork, rwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_1:
LAPACKE_free( rwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zgeevx", info );
}
return info;
}
开发者ID:Bres-Tech,项目名称:libswiftnav,代码行数:60,代码来源:lapacke_zgeevx.c
示例2: LAPACKE_zgelss
lapack_int LAPACKE_zgelss( int matrix_order, lapack_int m, lapack_int n,
lapack_int nrhs, lapack_complex_double* a,
lapack_int lda, lapack_complex_double* b,
lapack_int ldb, double* s, double rcond,
lapack_int* rank )
{
lapack_int info = 0;
lapack_int lwork = -1;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zgelss", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_order, m, n, a, lda ) ) {
return -5;
}
if( LAPACKE_zge_nancheck( matrix_order, MAX(m,n), nrhs, b, ldb ) ) {
return -7;
}
if( LAPACKE_d_nancheck( 1, &rcond, 1 ) ) {
return -10;
}
#endif
/* Allocate memory for working array(s) */
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,5*MIN(m,n)) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Query optimal working array(s) size */
info = LAPACKE_zgelss_work( matrix_order, m, n, nrhs, a, lda, b, ldb, s,
rcond, rank, &work_query, lwork, rwork );
if( info != 0 ) {
goto exit_level_1;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
/* Call middle-level interface */
info = LAPACKE_zgelss_work( matrix_order, m, n, nrhs, a, lda, b, ldb, s,
rcond, rank, work, lwork, rwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_1:
LAPACKE_free( rwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zgelss", info );
}
return info;
}
开发者ID:BOHICAMAN,项目名称:OpenBLAS,代码行数:60,代码来源:lapacke_zgelss.c
示例3: LAPACKE_zgesvd
lapack_int LAPACKE_zgesvd( int matrix_order, char jobu, char jobvt,
lapack_int m, lapack_int n, lapack_complex_double* a,
lapack_int lda, double* s, lapack_complex_double* u,
lapack_int ldu, lapack_complex_double* vt,
lapack_int ldvt, double* superb )
{
lapack_int info = 0;
lapack_int lwork = -1;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
lapack_int i;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zgesvd", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_order, m, n, a, lda ) ) {
return -6;
}
#endif
/* Allocate memory for working array(s) */
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,5*MIN(m,n)) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Query optimal working array(s) size */
info = LAPACKE_zgesvd_work( matrix_order, jobu, jobvt, m, n, a, lda, s, u,
ldu, vt, ldvt, &work_query, lwork, rwork );
if( info != 0 ) {
goto exit_level_1;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
/* Call middle-level interface */
info = LAPACKE_zgesvd_work( matrix_order, jobu, jobvt, m, n, a, lda, s, u,
ldu, vt, ldvt, work, lwork, rwork );
/* Backup significant data from working array(s) */
for( i=0; i<MIN(m,n)-1; i++ ) {
superb[i] = rwork[i];
}
/* Release memory and exit */
LAPACKE_free( work );
exit_level_1:
LAPACKE_free( rwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zgesvd", info );
}
return info;
}
开发者ID:BOHICAMAN,项目名称:OpenBLAS,代码行数:59,代码来源:lapacke_zgesvd.c
示例4: LAPACKE_zhegv
lapack_int LAPACKE_zhegv( int matrix_order, lapack_int itype, char jobz,
char uplo, lapack_int n, lapack_complex_double* a,
lapack_int lda, lapack_complex_double* b,
lapack_int ldb, double* w )
{
lapack_int info = 0;
lapack_int lwork = -1;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zhegv", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_order, n, n, a, lda ) ) {
return -6;
}
if( LAPACKE_zge_nancheck( matrix_order, n, n, b, ldb ) ) {
return -8;
}
#endif
/* Allocate memory for working array(s) */
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,3*n-2) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Query optimal working array(s) size */
info = LAPACKE_zhegv_work( matrix_order, itype, jobz, uplo, n, a, lda, b,
ldb, w, &work_query, lwork, rwork );
if( info != 0 ) {
goto exit_level_1;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
/* Call middle-level interface */
info = LAPACKE_zhegv_work( matrix_order, itype, jobz, uplo, n, a, lda, b,
ldb, w, work, lwork, rwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_1:
LAPACKE_free( rwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zhegv", info );
}
return info;
}
开发者ID:checco74,项目名称:uquantchem,代码行数:56,代码来源:lapacke_zhegv.c
示例5: LAPACKE_zgglse
lapack_int LAPACKE_zgglse( int matrix_order, lapack_int m, lapack_int n,
lapack_int p, lapack_complex_double* a,
lapack_int lda, lapack_complex_double* b,
lapack_int ldb, lapack_complex_double* c,
lapack_complex_double* d, lapack_complex_double* x )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zgglse", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_order, m, n, a, lda ) ) {
return -5;
}
if( LAPACKE_zge_nancheck( matrix_order, p, n, b, ldb ) ) {
return -7;
}
if( LAPACKE_z_nancheck( m, c, 1 ) ) {
return -9;
}
if( LAPACKE_z_nancheck( p, d, 1 ) ) {
return -10;
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zgglse_work( matrix_order, m, n, p, a, lda, b, ldb, c, d, x,
&work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zgglse_work( matrix_order, m, n, p, a, lda, b, ldb, c, d, x,
work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zgglse", info );
}
return info;
}
开发者ID:Bres-Tech,项目名称:libswiftnav,代码行数:54,代码来源:lapacke_zgglse.c
示例6: LAPACKE_zgeqp3
lapack_int LAPACKE_zgeqp3( int matrix_layout, lapack_int m, lapack_int n,
lapack_complex_double* a, lapack_int lda,
lapack_int* jpvt, lapack_complex_double* tau )
{
lapack_int info = 0;
lapack_int lwork = -1;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zgeqp3", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
if( LAPACKE_get_nancheck() ) {
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_layout, m, n, a, lda ) ) {
return -4;
}
}
#endif
/* Allocate memory for working array(s) */
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,2*n) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Query optimal working array(s) size */
info = LAPACKE_zgeqp3_work( matrix_layout, m, n, a, lda, jpvt, tau,
&work_query, lwork, rwork );
if( info != 0 ) {
goto exit_level_1;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
/* Call middle-level interface */
info = LAPACKE_zgeqp3_work( matrix_layout, m, n, a, lda, jpvt, tau, work,
lwork, rwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_1:
LAPACKE_free( rwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zgeqp3", info );
}
return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:54,代码来源:lapacke_zgeqp3.c
示例7: LAPACKE_zunmtr
lapack_int LAPACKE_zunmtr( int matrix_layout, char side, char uplo, char trans,
lapack_int m, lapack_int n,
const lapack_complex_double* a, lapack_int lda,
const lapack_complex_double* tau,
lapack_complex_double* c, lapack_int ldc )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
lapack_int r;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zunmtr", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
r = LAPACKE_lsame( side, 'l' ) ? m : n;
if( LAPACKE_zge_nancheck( matrix_layout, r, r, a, lda ) ) {
return -7;
}
if( LAPACKE_zge_nancheck( matrix_layout, m, n, c, ldc ) ) {
return -10;
}
if( LAPACKE_z_nancheck( m-1, tau, 1 ) ) {
return -9;
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zunmtr_work( matrix_layout, side, uplo, trans, m, n, a, lda,
tau, c, ldc, &work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zunmtr_work( matrix_layout, side, uplo, trans, m, n, a, lda,
tau, c, ldc, work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zunmtr", info );
}
return info;
}
开发者ID:OpenCMISS-Dependencies,项目名称:lapack,代码行数:53,代码来源:lapacke_zunmtr.c
示例8: LAPACKE_zhetrf_aa_2stage
lapack_int LAPACKE_zhetrf_aa_2stage( int matrix_layout, char uplo, lapack_int n,
lapack_complex_double* a,
lapack_int lda, lapack_complex_double* tb,
lapack_int ltb, lapack_int* ipiv, lapack_int* ipiv2 )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zhetrf_aa_2stage", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
if( LAPACKE_get_nancheck() ) {
/* Optionally check input matrices for NaNs */
if( LAPACKE_zhe_nancheck( matrix_layout, uplo, n, a, lda ) ) {
return -5;
}
if( LAPACKE_zge_nancheck( matrix_layout, 4*n, 1, tb, ltb ) ) {
return -7;
}
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zhetrf_aa_2stage_work( matrix_layout, uplo, n,
a, lda, tb, ltb, ipiv, ipiv2,
&work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zhetrf_aa_2stage_work( matrix_layout, uplo, n,
a, lda, tb, ltb, ipiv, ipiv2,
work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zhetrf_aa_2stage", info );
}
return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:51,代码来源:lapacke_zhetrf_aa_2stage.c
示例9: LAPACKE_ztrsen
lapack_int LAPACKE_ztrsen( int matrix_layout, char job, char compq,
const lapack_logical* select, lapack_int n,
lapack_complex_double* t, lapack_int ldt,
lapack_complex_double* q, lapack_int ldq,
lapack_complex_double* w, lapack_int* m, double* s,
double* sep )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_ztrsen", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_lsame( compq, 'v' ) ) {
if( LAPACKE_zge_nancheck( matrix_layout, n, n, q, ldq ) ) {
return -8;
}
}
if( LAPACKE_zge_nancheck( matrix_layout, n, n, t, ldt ) ) {
return -6;
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_ztrsen_work( matrix_layout, job, compq, select, n, t, ldt, q,
ldq, w, m, s, sep, &work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_ztrsen_work( matrix_layout, job, compq, select, n, t, ldt, q,
ldq, w, m, s, sep, work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_ztrsen", info );
}
return info;
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:51,代码来源:lapacke_ztrsen.c
示例10: LAPACKE_zhseqr
lapack_int LAPACKE_zhseqr( int matrix_layout, char job, char compz, lapack_int n,
lapack_int ilo, lapack_int ihi,
lapack_complex_double* h, lapack_int ldh,
lapack_complex_double* w, lapack_complex_double* z,
lapack_int ldz )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zhseqr", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_layout, n, n, h, ldh ) ) {
return -7;
}
if( LAPACKE_lsame( compz, 'i' ) || LAPACKE_lsame( compz, 'v' ) ) {
if( LAPACKE_zge_nancheck( matrix_layout, n, n, z, ldz ) ) {
return -10;
}
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zhseqr_work( matrix_layout, job, compz, n, ilo, ihi, h, ldh,
w, z, ldz, &work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zhseqr_work( matrix_layout, job, compz, n, ilo, ihi, h, ldh,
w, z, ldz, work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zhseqr", info );
}
return info;
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:50,代码来源:lapacke_zhseqr.c
示例11: LAPACKE_zsytri_3
lapack_int LAPACKE_zsytri_3( int matrix_layout, char uplo, lapack_int n,
lapack_complex_double* a, lapack_int lda,
const lapack_complex_double* e, const lapack_int* ipiv )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
lapack_int e_start = LAPACKE_lsame( uplo, 'U' ) ? 1 : 0;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zsytri_3", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
if( LAPACKE_get_nancheck() ) {
/* Optionally check input matrices for NaNs */
if( LAPACKE_zsy_nancheck( matrix_layout, uplo, n, a, lda ) ) {
return -4;
}
if( LAPACKE_z_nancheck( n-1, e + e_start, 1 ) ) {
return -6;
}
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zsytri_3_work( matrix_layout, uplo, n, a, lda, e, ipiv,
&work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for working array(s) */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zsytri_3_work( matrix_layout, uplo, n, a, lda, e, ipiv, work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zsytri_3", info );
}
return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:48,代码来源:lapacke_zsytri_3.c
示例12: LAPACKE_zgetsls
lapack_int LAPACKE_zgetsls( int matrix_layout, char trans, lapack_int m,
lapack_int n, lapack_int nrhs,
lapack_complex_double* a, lapack_int lda,
lapack_complex_double* b, lapack_int ldb )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zgetsls", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_layout, m, n, a, lda ) ) {
return -6;
}
if( LAPACKE_zge_nancheck( matrix_layout, MAX(m,n), nrhs, b, ldb ) ) {
return -8;
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zgetsls_work( matrix_layout, trans, m, n, nrhs, a, lda, b, ldb,
&work_query, lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zgetsls_work( matrix_layout, trans, m, n, nrhs, a, lda, b, ldb,
work, lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zgetsls", info );
}
return info;
}
开发者ID:ChinaQuants,项目名称:OpenBLAS,代码行数:47,代码来源:lapacke_zgetsls.c
示例13: LAPACKE_zungtr
lapack_int LAPACKE_zungtr( int matrix_order, char uplo, lapack_int n,
lapack_complex_double* a, lapack_int lda,
const lapack_complex_double* tau )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zungtr", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_order, n, n, a, lda ) ) {
return -4;
}
if( LAPACKE_z_nancheck( n-1, tau, 1 ) ) {
return -6;
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zungtr_work( matrix_order, uplo, n, a, lda, tau, &work_query,
lwork );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Call middle-level interface */
info = LAPACKE_zungtr_work( matrix_order, uplo, n, a, lda, tau, work,
lwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zungtr", info );
}
return info;
}
开发者ID:Bres-Tech,项目名称:libswiftnav,代码行数:46,代码来源:lapacke_zungtr.c
示例14: LAPACKE_zggevx
lapack_int LAPACKE_zggevx( int matrix_layout, char balanc, char jobvl,
char jobvr, char sense, lapack_int n,
lapack_complex_double* a, lapack_int lda,
lapack_complex_double* b, lapack_int ldb,
lapack_complex_double* alpha,
lapack_complex_double* beta,
lapack_complex_double* vl, lapack_int ldvl,
lapack_complex_double* vr, lapack_int ldvr,
lapack_int* ilo, lapack_int* ihi, double* lscale,
double* rscale, double* abnrm, double* bbnrm,
double* rconde, double* rcondv )
{
lapack_int info = 0;
lapack_int lwork = -1;
/* Additional scalars declarations for work arrays */
lapack_int lrwork;
lapack_logical* bwork = NULL;
lapack_int* iwork = NULL;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zggevx", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
if( LAPACKE_get_nancheck() ) {
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_layout, n, n, a, lda ) ) {
return -7;
}
if( LAPACKE_zge_nancheck( matrix_layout, n, n, b, ldb ) ) {
return -9;
}
}
#endif
/* Additional scalars initializations for work arrays */
if( LAPACKE_lsame( balanc, 's' ) || LAPACKE_lsame( balanc, 'b' ) ) {
lrwork = MAX(1,6*n);
} else {
lrwork = MAX(1,2*n);
}
/* Allocate memory for working array(s) */
if( LAPACKE_lsame( sense, 'b' ) || LAPACKE_lsame( sense, 'e' ) ||
LAPACKE_lsame( sense, 'v' ) ) {
bwork = (lapack_logical*)
LAPACKE_malloc( sizeof(lapack_logical) * MAX(1,n) );
if( bwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
}
if( LAPACKE_lsame( sense, 'b' ) || LAPACKE_lsame( sense, 'n' ) ||
LAPACKE_lsame( sense, 'v' ) ) {
iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * MAX(1,n+2) );
if( iwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
}
rwork = (double*)LAPACKE_malloc( sizeof(double) * lrwork );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_2;
}
/* Query optimal working array(s) size */
info = LAPACKE_zggevx_work( matrix_layout, balanc, jobvl, jobvr, sense, n, a,
lda, b, ldb, alpha, beta, vl, ldvl, vr, ldvr,
ilo, ihi, lscale, rscale, abnrm, bbnrm, rconde,
rcondv, &work_query, lwork, rwork, iwork,
bwork );
if( info != 0 ) {
goto exit_level_3;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_3;
}
/* Call middle-level interface */
info = LAPACKE_zggevx_work( matrix_layout, balanc, jobvl, jobvr, sense, n, a,
lda, b, ldb, alpha, beta, vl, ldvl, vr, ldvr,
ilo, ihi, lscale, rscale, abnrm, bbnrm, rconde,
rcondv, work, lwork, rwork, iwork, bwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_3:
LAPACKE_free( rwork );
exit_level_2:
if( LAPACKE_lsame( sense, 'b' ) || LAPACKE_lsame( sense, 'n' ) ||
LAPACKE_lsame( sense, 'v' ) ) {
LAPACKE_free( iwork );
}
exit_level_1:
if( LAPACKE_lsame( sense, 'b' ) || LAPACKE_lsame( sense, 'e' ) ||
LAPACKE_lsame( sense, 'v' ) ) {
LAPACKE_free( bwork );
//.........这里部分代码省略.........
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:101,代码来源:lapacke_zggevx.c
示例15: LAPACKE_zggsvd3
lapack_int LAPACKE_zggsvd3( int matrix_layout, char jobu, char jobv, char jobq,
lapack_int m, lapack_int n, lapack_int p,
lapack_int* k, lapack_int* l,
lapack_complex_double* a, lapack_int lda,
lapack_complex_double* b, lapack_int ldb,
double* alpha, double* beta,
lapack_complex_double* u, lapack_int ldu,
lapack_complex_double* v, lapack_int ldv,
lapack_complex_double* q, lapack_int ldq,
lapack_int* iwork )
{
lapack_int info = 0;
double* rwork = NULL;
lapack_int lwork = -1;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zggsvd3", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
if( LAPACKE_zge_nancheck( matrix_layout, m, n, a, lda ) ) {
return -10;
}
if( LAPACKE_zge_nancheck( matrix_layout, p, n, b, ldb ) ) {
return -12;
}
#endif
/* Query optimal size for working array */
info = LAPACKE_zggsvd3_work( matrix_layout, jobu, jobv, jobq, m, n, p, k, l,
a, lda, b, ldb, alpha, beta, u, ldu, v, ldv, q,
ldq, &work_query, lwork, rwork, iwork );
if( info != 0 )
goto exit_level_0;
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for working array(s) */
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,2*n) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
/* Call middle-level interface */
info = LAPACKE_zggsvd3_work( matrix_layout, jobu, jobv, jobq, m, n, p, k, l,
a, lda, b, ldb, alpha, beta, u, ldu, v, ldv, q,
ldq, work, lwork, rwork, iwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_1:
LAPACKE_free( rwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zggsvd3", info );
}
return info;
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:62,代码来源:lapacke_zggsvd3.c
示例16: LAPACKE_zuncsd
lapack_int LAPACKE_zuncsd( int matrix_order, char jobu1, char jobu2,
char jobv1t, char jobv2t, char trans, char signs,
lapack_int m, lapack_int p, lapack_int q,
lapack_complex_double* x11, lapack_int ldx11,
lapack_complex_double* x12, lapack_int ldx12,
lapack_complex_double* x21, lapack_int ldx21,
lapack_complex_double* x22, lapack_int ldx22,
double* theta, lapack_complex_double* u1,
lapack_int ldu1, lapack_complex_double* u2,
lapack_int ldu2, lapack_complex_double* v1t,
lapack_int ldv1t, lapack_complex_double* v2t,
lapack_int ldv2t )
{
lapack_int info = 0;
lapack_int lrwork = -1;
lapack_int lwork = -1;
lapack_int* iwork = NULL;
double* rwork = NULL;
lapack_complex_double* work = NULL;
double rwork_query;
lapack_complex_double work_query;
if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zuncsd", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
/* Optionally check input matrices for NaNs */
lapack_int nrows_x11 = ( LAPACKE_lsame( trans, 'n' ) ? p : q);
lapack_int nrows_x12 = ( LAPACKE_lsame( trans, 'n' ) ? p : m-q);
lapack_int nrows_x21 = ( LAPACKE_lsame( trans, 'n' ) ? m-p : q);
lapack_int nrows_x22 = ( LAPACKE_lsame( trans, 'n' ) ? m-p : m-q);
if( LAPACKE_zge_nancheck( matrix_order, nrows_x11, q, x11, ldx11 ) ) {
return -11;
}
if( LAPACKE_zge_nancheck( matrix_order, nrows_x12, m-q, x12, ldx12 ) ) {
return -13;
}
if( LAPACKE_zge_nancheck( matrix_order, nrows_x21, q, x21, ldx21 ) ) {
return -15;
}
if( LAPACKE_zge_nancheck( matrix_order, nrows_x22, m-q, x22, ldx22 ) ) {
return -17;
}
#endif
/* Allocate memory for working array(s) */
iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * MAX(1,m-q) );
if( iwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
/* Query optimal working array(s) size */
info = LAPACKE_zuncsd_work( matrix_order, jobu1, jobu2, jobv1t, jobv2t,
trans, signs, m, p, q, x11, ldx11, x12, ldx12,
x21, ldx21, x22, ldx22, theta, u1, ldu1, u2,
ldu2, v1t, ldv1t, v2t, ldv2t, &work_query,
lwork, &rwork_query, lrwork, iwork );
if( info != 0 ) {
goto exit_level_1;
}
lrwork = (lapack_int)rwork_query;
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for work arrays */
rwork = (double*)LAPACKE_malloc( sizeof(double) * lrwork );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_2;
}
/* Call middle-level interface */
info = LAPACKE_zuncsd_work( matrix_order, jobu1, jobu2, jobv1t, jobv2t,
trans, signs, m, p, q, x11, ldx11, x12, ldx12,
x21, ldx21, x22, ldx22, theta, u1, ldu1, u2,
ldu2, v1t, ldv1t, v2t, ldv2t, work, lwork,
rwork, lrwork, iwork );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_2:
LAPACKE_free( rwork );
exit_level_1:
LAPACKE_free( iwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zuncsd", info );
}
return info;
}
开发者ID:checco74,项目名称:uquantchem,代码行数:91,代码来源:lapacke_zuncsd.c
示例17: LAPACKE_zhbevx_2stage
lapack_int LAPACKE_zhbevx_2stage( int matrix_layout, char jobz, char range, char uplo,
lapack_int n, lapack_int kd,
lapack_complex_double* ab, lapack_int ldab,
lapack_complex_double* q, lapack_int ldq, double vl,
double vu, lapack_int il, lapack_int iu,
double abstol, lapack_int* m, double* w,
lapack_complex_double* z, lapack_int ldz,
lapack_int* ifail )
{
lapack_int info = 0;
lapack_int lwork = -1;
lapack_int* iwork = NULL;
double* rwork = NULL;
lapack_complex_double* work = NULL;
lapack_complex_double work_query;
if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
LAPACKE_xerbla( "LAPACKE_zhbevx_2stage", -1 );
return -1;
}
#ifndef LAPACK_DISABLE_NAN_CHECK
if( LAPACKE_get_nancheck() ) {
/* Optionally check input matrices for NaNs */
if( LAPACKE_zhb_nancheck( matrix_layout, uplo, n, kd, ab, ldab ) ) {
return -7;
}
if( LAPACKE_d_nancheck( 1, &abstol, 1 ) ) {
return -15;
}
if( LAPACKE_lsame( range, 'v' ) ) {
if( LAPACKE_d_nancheck( 1, &vl, 1 ) ) {
return -11;
}
}
if( LAPACKE_lsame( range, 'v' ) ) {
if( LAPACKE_d_nancheck( 1, &vu, 1 ) ) {
return -12;
}
}
}
#endif
/* Query optimal working array(s) size */
info = LAPACKE_zhbevx_2stage_work( matrix_layout, jobz, range, uplo, n, kd, ab,
ldab, q, ldq, vl, vu, il, iu, abstol, m, w, z,
ldz, &work_query, lwork, rwork, iwork, ifail );
if( info != 0 ) {
goto exit_level_0;
}
lwork = LAPACK_Z2INT( work_query );
/* Allocate memory for working array(s) */
iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * MAX(1,5*n) );
if( iwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_0;
}
rwork = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,7*n) );
if( rwork == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_1;
}
work = (lapack_complex_double*)
LAPACKE_malloc( sizeof(lapack_complex_double) * lwork );
if( work == NULL ) {
info = LAPACK_WORK_MEMORY_ERROR;
goto exit_level_2;
}
/* Call middle-level interface */
info = LAPACKE_zhbevx_2stage_work( matrix_layout, jobz, range, uplo, n, kd, ab,
ldab, q, ldq, vl, vu, il, iu, abstol, m, w, z,
ldz, work, lwork, rwork, iwork, ifail );
/* Release memory and exit */
LAPACKE_free( work );
exit_level_2:
LAPACKE_free( rwork );
exit_level_1:
LAPACKE_free( iwork );
exit_level_0:
if( info == LAPACK_WORK_MEMORY_ERROR ) {
LAPACKE_xerbla( "LAPACKE_zhbevx_2stage", info );
}
return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:81,代码来源:lapacke_zhbevx_2stage.c
-
六六分期app的软件客服如何联系?不知道吗?加qq群【895510560】即可!标题:六六分期
阅读:18239|2023-10-27
-
今天小编告诉大家如何处理win10系统火狐flash插件总是崩溃的问题,可能很多用户都不知
阅读:9667|2022-11-06
-
今天小编告诉大家如何对win10系统删除桌面回收站图标进行设置,可能很多用户都不知道
阅读:8175|2022-11-06
-
今天小编告诉大家如何对win10系统电脑设置节能降温的设置方法,想必大家都遇到过需要
阅读:8547|2022-11-06
-
我们在使用xp系统的过程中,经常需要对xp系统无线网络安装向导设置进行设置,可能很多
阅读:8453|2022-11-06
-
今天小编告诉大家如何处理win7系统玩cf老是与主机连接不稳定的问题,可能很多用户都不
阅读:9383|2022-11-06
-
电脑对日常生活的重要性小编就不多说了,可是一旦碰到win7系统设置cf烟雾头的问题,很
阅读:8425|2022-11-06
-
我们在日常使用电脑的时候,有的小伙伴们可能在打开应用的时候会遇见提示应用程序无法
阅读:7858|2022-11-06
-
今天小编告诉大家如何对win7系统打开vcf文件进行设置,可能很多用户都不知道怎么对win
阅读:8410|2022-11-06
-
今天小编告诉大家如何对win10系统s4开启USB调试模式进行设置,可能很多用户都不知道怎
阅读:7394|2022-11-06
|
请发表评论