• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ LAPACKE_dge_nancheck函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中LAPACKE_dge_nancheck函数的典型用法代码示例。如果您正苦于以下问题:C++ LAPACKE_dge_nancheck函数的具体用法?C++ LAPACKE_dge_nancheck怎么用?C++ LAPACKE_dge_nancheck使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了LAPACKE_dge_nancheck函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: LAPACKE_dtrsyl

lapack_int LAPACKE_dtrsyl( int matrix_order, char trana, char tranb,
                           lapack_int isgn, lapack_int m, lapack_int n,
                           const double* a, lapack_int lda, const double* b,
                           lapack_int ldb, double* c, lapack_int ldc,
                           double* scale )
{
    if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dtrsyl", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_dge_nancheck( matrix_order, m, m, a, lda ) ) {
        return -7;
    }
    if( LAPACKE_dge_nancheck( matrix_order, n, n, b, ldb ) ) {
        return -9;
    }
    if( LAPACKE_dge_nancheck( matrix_order, m, n, c, ldc ) ) {
        return -11;
    }
#endif
    return LAPACKE_dtrsyl_work( matrix_order, trana, tranb, isgn, m, n, a, lda,
                                b, ldb, c, ldc, scale );
}
开发者ID:2php,项目名称:netlib-java,代码行数:25,代码来源:lapacke_dtrsyl.c


示例2: LAPACKE_dtpmqrt

lapack_int LAPACKE_dtpmqrt( int matrix_layout, char side, char trans,
                            lapack_int m, lapack_int n, lapack_int k,
                            lapack_int l, lapack_int nb, const double* v,
                            lapack_int ldv, const double* t, lapack_int ldt,
                            double* a, lapack_int lda, double* b,
                            lapack_int ldb )
{
    lapack_int ncols_a, nrows_a;
    lapack_int nrows_v;
    lapack_int lwork;
    lapack_int info = 0;
    double* work = NULL;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dtpmqrt", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        ncols_a = LAPACKE_lsame( side, 'L' ) ? n :
                             ( LAPACKE_lsame( side, 'R' ) ? k : 0 );
        nrows_a = LAPACKE_lsame( side, 'L' ) ? k :
                             ( LAPACKE_lsame( side, 'R' ) ? m : 0 );
        nrows_v = LAPACKE_lsame( side, 'L' ) ? m :
                             ( LAPACKE_lsame( side, 'R' ) ? n : 0 );
        if( LAPACKE_dge_nancheck( matrix_layout, nrows_a, ncols_a, a, lda ) ) {
            return -13;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, m, n, b, ldb ) ) {
            return -15;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, nb, k, t, ldt ) ) {
            return -11;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, nrows_v, k, v, ldv ) ) {
            return -9;
        }
    }
#endif
    /* Allocate memory for working array(s) */
    lwork = LAPACKE_lsame( side, 'L' ) ? MAX(1,nb) * MAX(1,n) :
                       ( LAPACKE_lsame( side, 'R' ) ? MAX(1,m) * MAX(1,nb) : 0 );
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dtpmqrt_work( matrix_layout, side, trans, m, n, k, l, nb, v,
                                 ldv, t, ldt, a, lda, b, ldb, work );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dtpmqrt", info );
    }
    return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:58,代码来源:lapacke_dtpmqrt.c


示例3: LAPACKE_dsygvd

lapack_int LAPACKE_dsygvd( int matrix_layout, lapack_int itype, char jobz,
                           char uplo, lapack_int n, double* a, lapack_int lda,
                           double* b, lapack_int ldb, double* w )
{
    lapack_int info = 0;
    lapack_int liwork = -1;
    lapack_int lwork = -1;
    lapack_int* iwork = NULL;
    double* work = NULL;
    lapack_int iwork_query;
    double work_query;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dsygvd", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_dge_nancheck( matrix_layout, n, n, a, lda ) ) {
        return -6;
    }
    if( LAPACKE_dge_nancheck( matrix_layout, n, n, b, ldb ) ) {
        return -8;
    }
#endif
    /* Query optimal working array(s) size */
    info = LAPACKE_dsygvd_work( matrix_layout, itype, jobz, uplo, n, a, lda, b,
                                ldb, w, &work_query, lwork, &iwork_query,
                                liwork );
    if( info != 0 ) {
        goto exit_level_0;
    }
    liwork = (lapack_int)iwork_query;
    lwork = (lapack_int)work_query;
    /* Allocate memory for work arrays */
    iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * liwork );
    if( iwork == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_1;
    }
    /* Call middle-level interface */
    info = LAPACKE_dsygvd_work( matrix_layout, itype, jobz, uplo, n, a, lda, b,
                                ldb, w, work, lwork, iwork, liwork );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_1:
    LAPACKE_free( iwork );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dsygvd", info );
    }
    return info;
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:57,代码来源:lapacke_dsygvd.c


示例4: LAPACKE_dormbr

lapack_int LAPACKE_dormbr( int matrix_layout, char vect, char side, char trans,
                           lapack_int m, lapack_int n, lapack_int k,
                           const double* a, lapack_int lda, const double* tau,
                           double* c, lapack_int ldc )
{
    lapack_int info = 0;
    lapack_int lwork = -1;
    double* work = NULL;
    double work_query;
    lapack_int nq, ar, ac;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dormbr", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        nq = LAPACKE_lsame( side, 'l' ) ? m : n;
        ar = LAPACKE_lsame( vect, 'q' ) ? nq : MIN(nq,k);
        ac = LAPACKE_lsame( vect, 'q' ) ? MIN(nq,k) : nq;
        if( LAPACKE_dge_nancheck( matrix_layout, ar, ac, a, lda ) ) {
            return -8;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, m, n, c, ldc ) ) {
            return -11;
        }
        if( LAPACKE_d_nancheck( MIN(nq,k), tau, 1 ) ) {
            return -10;
        }
    }
#endif
    /* Query optimal working array(s) size */
    info = LAPACKE_dormbr_work( matrix_layout, vect, side, trans, m, n, k, a,
                                lda, tau, c, ldc, &work_query, lwork );
    if( info != 0 ) {
        goto exit_level_0;
    }
    lwork = (lapack_int)work_query;
    /* Allocate memory for work arrays */
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dormbr_work( matrix_layout, vect, side, trans, m, n, k, 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_dormbr", info );
    }
    return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:55,代码来源:lapacke_dormbr.c


示例5: LAPACKE_dgbrfs

lapack_int LAPACKE_dgbrfs( int matrix_layout, char trans, lapack_int n,
                           lapack_int kl, lapack_int ku, lapack_int nrhs,
                           const double* ab, lapack_int ldab, const double* afb,
                           lapack_int ldafb, const lapack_int* ipiv,
                           const double* b, lapack_int ldb, double* x,
                           lapack_int ldx, double* ferr, double* berr )
{
    lapack_int info = 0;
    lapack_int* iwork = NULL;
    double* work = NULL;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dgbrfs", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_dgb_nancheck( matrix_layout, n, n, kl, ku, ab, ldab ) ) {
        return -7;
    }
    if( LAPACKE_dgb_nancheck( matrix_layout, n, n, kl, kl+ku, afb, ldafb ) ) {
        return -9;
    }
    if( LAPACKE_dge_nancheck( matrix_layout, n, nrhs, b, ldb ) ) {
        return -12;
    }
    if( LAPACKE_dge_nancheck( matrix_layout, n, nrhs, x, ldx ) ) {
        return -14;
    }
#endif
    /* Allocate memory for working array(s) */
    iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * MAX(1,n) );
    if( iwork == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    work = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,3*n) );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_1;
    }
    /* Call middle-level interface */
    info = LAPACKE_dgbrfs_work( matrix_layout, trans, n, kl, ku, nrhs, ab, ldab,
                                afb, ldafb, ipiv, b, ldb, x, ldx, ferr, berr,
                                work, iwork );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_1:
    LAPACKE_free( iwork );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dgbrfs", info );
    }
    return info;
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:54,代码来源:lapacke_dgbrfs.c


示例6: LAPACKE_dbdsqr

lapack_int LAPACKE_dbdsqr( int matrix_layout, char uplo, lapack_int n,
                           lapack_int ncvt, lapack_int nru, lapack_int ncc,
                           double* d, double* e, double* vt, lapack_int ldvt,
                           double* u, lapack_int ldu, double* c,
                           lapack_int ldc )
{
    lapack_int info = 0;
    double* work = NULL;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dbdsqr", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( ncc != 0 ) {
        if( LAPACKE_dge_nancheck( matrix_layout, n, ncc, c, ldc ) ) {
            return -13;
        }
    }
    if( LAPACKE_d_nancheck( n, d, 1 ) ) {
        return -7;
    }
    if( LAPACKE_d_nancheck( n-1, e, 1 ) ) {
        return -8;
    }
    if( nru != 0 ) {
        if( LAPACKE_dge_nancheck( matrix_layout, nru, n, u, ldu ) ) {
            return -11;
        }
    }
    if( ncvt != 0 ) {
        if( LAPACKE_dge_nancheck( matrix_layout, n, ncvt, vt, ldvt ) ) {
            return -9;
        }
    }
#endif
    /* Allocate memory for working array(s) */
    work = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,4*n) );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dbdsqr_work( matrix_layout, uplo, n, ncvt, nru, ncc, d, e, vt,
                                ldvt, u, ldu, c, ldc, work );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dbdsqr", info );
    }
    return info;
}
开发者ID:OpenCMISS-Dependencies,项目名称:lapack,代码行数:53,代码来源:lapacke_dbdsqr.c


示例7: LAPACKE_dgemlq

lapack_int LAPACKE_dgemlq( int matrix_layout, char side, char trans,
                           lapack_int m, lapack_int n, lapack_int k,
                           const double* a, lapack_int lda,
                           const double* t, lapack_int tsize,
                           double* c, lapack_int ldc )
{
    lapack_int info = 0;
    lapack_int lwork = -1;
    double* work = NULL;
    double work_query;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dgemlq", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        if( LAPACKE_dge_nancheck( matrix_layout, k, m, a, lda ) ) {
            return -7;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, m, n, c, ldc ) ) {
            return -10;
        }
        if( LAPACKE_d_nancheck( tsize, t, 1 ) ) {
            return -9;
        }
    }
#endif
    /* Query optimal working array(s) size */
    info = LAPACKE_dgemlq_work( matrix_layout, side, trans, m, n, k, a, lda,
                                t, tsize, c, ldc, &work_query, lwork );
    if( info != 0 ) {
        goto exit_level_0;
    }
    lwork = (lapack_int)work_query;
    /* Allocate memory for work arrays */
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dgemlq_work( matrix_layout, side, trans, m, n, k, a, lda,
                                t, tsize, c, ldc, work, lwork );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dgemlq", info );
    }
    return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:52,代码来源:lapacke_dgemlq.c


示例8: LAPACKE_dgglse

lapack_int LAPACKE_dgglse( int matrix_order, lapack_int m, lapack_int n,
                           lapack_int p, double* a, lapack_int lda, double* b,
                           lapack_int ldb, double* c, double* d, double* x )
{
    lapack_int info = 0;
    lapack_int lwork = -1;
    double* work = NULL;
    double work_query;
    if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dgglse", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_dge_nancheck( matrix_order, m, n, a, lda ) ) {
        return -5;
    }
    if( LAPACKE_dge_nancheck( matrix_order, p, n, b, ldb ) ) {
        return -7;
    }
    if( LAPACKE_d_nancheck( m, c, 1 ) ) {
        return -9;
    }
    if( LAPACKE_d_nancheck( p, d, 1 ) ) {
        return -10;
    }
#endif
    /* Query optimal working array(s) size */
    info = LAPACKE_dgglse_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_int)work_query;
    /* Allocate memory for work arrays */
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dgglse_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_dgglse", info );
    }
    return info;
}
开发者ID:2php,项目名称:netlib-java,代码行数:51,代码来源:lapacke_dgglse.c


示例9: LAPACKE_dptrfs

lapack_int LAPACKE_dptrfs( int matrix_order, lapack_int n, lapack_int nrhs,
                           const double* d, const double* e, const double* df,
                           const double* ef, const double* b, lapack_int ldb,
                           double* x, lapack_int ldx, double* ferr,
                           double* berr )
{
    lapack_int info = 0;
    double* work = NULL;
    if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dptrfs", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_dge_nancheck( matrix_order, n, nrhs, b, ldb ) ) {
        return -8;
    }
    if( LAPACKE_d_nancheck( n, d, 1 ) ) {
        return -4;
    }
    if( LAPACKE_d_nancheck( n, df, 1 ) ) {
        return -6;
    }
    if( LAPACKE_d_nancheck( n-1, e, 1 ) ) {
        return -5;
    }
    if( LAPACKE_d_nancheck( n-1, ef, 1 ) ) {
        return -7;
    }
    if( LAPACKE_dge_nancheck( matrix_order, n, nrhs, x, ldx ) ) {
        return -10;
    }
#endif
    /* Allocate memory for working array(s) */
    work = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,2*n) );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dptrfs_work( matrix_order, n, nrhs, d, e, df, ef, b, ldb, x,
                                ldx, ferr, berr, work );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dptrfs", info );
    }
    return info;
}
开发者ID:checco74,项目名称:uquantchem,代码行数:50,代码来源:lapacke_dptrfs.c


示例10: LAPACKE_dgelss

lapack_int LAPACKE_dgelss( int matrix_layout, lapack_int m, lapack_int n,
                           lapack_int nrhs, double* a, lapack_int lda,
                           double* b, lapack_int ldb, double* s, double rcond,
                           lapack_int* rank )
{
    lapack_int info = 0;
    lapack_int lwork = -1;
    double* work = NULL;
    double work_query;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dgelss", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_dge_nancheck( matrix_layout, m, n, a, lda ) ) {
        return -5;
    }
    if( LAPACKE_dge_nancheck( matrix_layout, MAX(m,n), nrhs, b, ldb ) ) {
        return -7;
    }
    if( LAPACKE_d_nancheck( 1, &rcond, 1 ) ) {
        return -10;
    }
#endif
    /* Query optimal working array(s) size */
    info = LAPACKE_dgelss_work( matrix_layout, m, n, nrhs, a, lda, b, ldb, s,
                                rcond, rank, &work_query, lwork );
    if( info != 0 ) {
        goto exit_level_0;
    }
    lwork = (lapack_int)work_query;
    /* Allocate memory for work arrays */
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dgelss_work( matrix_layout, m, n, nrhs, a, lda, b, ldb, s,
                                rcond, rank, work, lwork );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dgelss", info );
    }
    return info;
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:49,代码来源:lapacke_dgelss.c


示例11: LAPACKE_dgesvj

lapack_int LAPACKE_dgesvj( int matrix_order, char joba, char jobu, char jobv,
                           lapack_int m, lapack_int n, double* a,
                           lapack_int lda, double* sva, lapack_int mv,
                           double* v, lapack_int ldv, double* stat )
{
    lapack_int info = 0;
    lapack_int lwork = MAX(6,m+n);
    double* work = NULL;
    lapack_int i;
    if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dgesvj", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    lapack_int nrows_v = LAPACKE_lsame( jobv, 'v' ) ? n :
                         ( LAPACKE_lsame( jobv, 'a' ) ? mv : 1);
    if( LAPACKE_dge_nancheck( matrix_order, m, n, a, lda ) ) {
        return -7;
    }
    if( LAPACKE_lsame( jobv, 'a' ) || LAPACKE_lsame( jobv, 'v' ) ) {
        if( LAPACKE_dge_nancheck( matrix_order, nrows_v, n, v, ldv ) ) {
            return -11;
        }
    }
#endif
    /* Allocate memory for working array(s) */
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    work[0] = stat[0];  /* Significant if jobu = 'c' */
    /* Call middle-level interface */
    info = LAPACKE_dgesvj_work( matrix_order, joba, jobu, jobv, m, n, a, lda,
                                sva, mv, v, ldv, work, lwork );
    /* Backup significant data from working array(s) */
    for( i=0; i<6; i++ ) {
        stat[i] = work[i];
    }
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dgesvj", info );
    }
    return info;
}
开发者ID:Bres-Tech,项目名称:libswiftnav,代码行数:48,代码来源:lapacke_dgesvj.c


示例12: LAPACKE_dgg_nancheck

lapack_logical LAPACKE_dgg_nancheck( int matrix_order, lapack_int m,
                                      lapack_int n,
                                      const double *a,
                                      lapack_int lda )
{
    return LAPACKE_dge_nancheck( matrix_order, m, n, a, lda );
}
开发者ID:2php,项目名称:netlib-java,代码行数:7,代码来源:lapacke_dgg_nancheck.c


示例13: LAPACKE_dlarft

lapack_int LAPACKE_dlarft( int matrix_order, char direct, char storev,
                           lapack_int n, lapack_int k, const double* v,
                           lapack_int ldv, const double* tau, double* t,
                           lapack_int ldt )
{
    if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dlarft", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    lapack_int ncols_v = LAPACKE_lsame( storev, 'c' ) ? k :
                         ( LAPACKE_lsame( storev, 'r' ) ? n : 1);
    lapack_int nrows_v = LAPACKE_lsame( storev, 'c' ) ? n :
                         ( LAPACKE_lsame( storev, 'r' ) ? k : 1);
    if( LAPACKE_d_nancheck( k, tau, 1 ) ) {
        return -8;
    }
    if( LAPACKE_dge_nancheck( matrix_order, nrows_v, ncols_v, v, ldv ) ) {
        return -6;
    }
#endif
    return LAPACKE_dlarft_work( matrix_order, direct, storev, n, k, v, ldv, tau,
                                t, ldt );
}
开发者ID:checco74,项目名称:uquantchem,代码行数:25,代码来源:lapacke_dlarft.c


示例14: LAPACKE_dgelq2

lapack_int LAPACKE_dgelq2( int matrix_layout, lapack_int m, lapack_int n,
                           double* a, lapack_int lda, double* tau )
{
    lapack_int info = 0;
    double* work = NULL;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dgelq2", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        if( LAPACKE_dge_nancheck( matrix_layout, m, n, a, lda ) ) {
            return -4;
        }
    }
#endif
    /* Allocate memory for working array(s) */
    work = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,m) );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    /* Call middle-level interface */
    info = LAPACKE_dgelq2_work( matrix_layout, m, n, a, lda, tau, work );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dgelq2", info );
    }
    return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:33,代码来源:lapacke_dgelq2.c


示例15: LAPACKE_dsfrk

lapack_int LAPACKE_dsfrk( int matrix_layout, char transr, char uplo, char trans,
                          lapack_int n, lapack_int k, double alpha,
                          const double* a, lapack_int lda, double beta,
                          double* c )
{
    lapack_int ka, na;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dsfrk", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    ka = LAPACKE_lsame( trans, 'n' ) ? k : n;
    na = LAPACKE_lsame( trans, 'n' ) ? n : k;
    if( LAPACKE_dge_nancheck( matrix_layout, na, ka, a, lda ) ) {
        return -8;
    }
    if( LAPACKE_d_nancheck( 1, &alpha, 1 ) ) {
        return -7;
    }
    if( LAPACKE_d_nancheck( 1, &beta, 1 ) ) {
        return -10;
    }
    if( LAPACKE_dpf_nancheck( n, c ) ) {
        return -11;
    }
#endif
    return LAPACKE_dsfrk_work( matrix_layout, transr, uplo, trans, n, k, alpha,
                               a, lda, beta, c );
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:30,代码来源:lapacke_dsfrk.c


示例16: LAPACKE_dpbsvx

lapack_int LAPACKE_dpbsvx( int matrix_layout, char fact, char uplo, lapack_int n,
                           lapack_int kd, lapack_int nrhs, double* ab,
                           lapack_int ldab, double* afb, lapack_int ldafb,
                           char* equed, double* s, double* b, lapack_int ldb,
                           double* x, lapack_int ldx, double* rcond,
                           double* ferr, double* berr )
{
    lapack_int info = 0;
    lapack_int* iwork = NULL;
    double* work = NULL;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dpbsvx", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        if( LAPACKE_dpb_nancheck( matrix_layout, uplo, n, kd, ab, ldab ) ) {
            return -7;
        }
        if( LAPACKE_lsame( fact, 'f' ) ) {
            if( LAPACKE_dpb_nancheck( matrix_layout, uplo, n, kd, afb, ldafb ) ) {
                return -9;
            }
        }
        if( LAPACKE_dge_nancheck( matrix_layout, n, nrhs, b, ldb ) ) {
            return -13;
        }
        if( LAPACKE_lsame( fact, 'f' ) && LAPACKE_lsame( *equed, 'y' ) ) {
            if( LAPACKE_d_nancheck( n, s, 1 ) ) {
                return -12;
            }
        }
    }
#endif
    /* Allocate memory for working array(s) */
    iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * MAX(1,n) );
    if( iwork == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    work = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,3*n) );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_1;
    }
    /* Call middle-level interface */
    info = LAPACKE_dpbsvx_work( matrix_layout, fact, uplo, n, kd, nrhs, ab, ldab,
                                afb, ldafb, equed, s, b, ldb, x, ldx, rcond,
                                ferr, berr, work, iwork );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_1:
    LAPACKE_free( iwork );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dpbsvx", info );
    }
    return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:60,代码来源:lapacke_dpbsvx.c


示例17: LAPACKE_dtfsm

lapack_int LAPACKE_dtfsm( int matrix_layout, char transr, char side, char uplo,
                          char trans, char diag, lapack_int m, lapack_int n,
                          double alpha, const double* a, double* b,
                          lapack_int ldb )
{
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dtfsm", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( IS_D_NONZERO(alpha) ) {
        if( LAPACKE_dtf_nancheck( matrix_layout, transr, uplo, diag, n, a ) ) {
            return -10;
        }
    }
    if( LAPACKE_d_nancheck( 1, &alpha, 1 ) ) {
        return -9;
    }
    if( IS_D_NONZERO(alpha) ) {
        if( LAPACKE_dge_nancheck( matrix_layout, m, n, b, ldb ) ) {
            return -11;
        }
    }
#endif
    return LAPACKE_dtfsm_work( matrix_layout, transr, side, uplo, trans, diag, m,
                               n, alpha, a, b, ldb );
}
开发者ID:4ker,项目名称:OpenBLAS,代码行数:28,代码来源:lapacke_dtfsm.c


示例18: LAPACKE_dstedc

lapack_int LAPACKE_dstedc( int matrix_order, char compz, lapack_int n,
                           double* d, double* e, double* z, lapack_int ldz )
{
    lapack_int info = 0;
    lapack_int liwork = -1;
    lapack_int lwork = -1;
    lapack_int* iwork = NULL;
    double* work = NULL;
    lapack_int iwork_query;
    double work_query;
    if( matrix_order != LAPACK_COL_MAJOR && matrix_order != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dstedc", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    /* Optionally check input matrices for NaNs */
    if( LAPACKE_d_nancheck( n, d, 1 ) ) {
        return -4;
    }
    if( LAPACKE_d_nancheck( n-1, e, 1 ) ) {
        return -5;
    }
    if( LAPACKE_lsame( compz, 'i' ) || LAPACKE_lsame( compz, 'v' ) ) {
        if( LAPACKE_dge_nancheck( matrix_order, n, n, z, ldz ) ) {
            return -6;
        }
    }
#endif
    /* Query optimal working array(s) size */
    info = LAPACKE_dstedc_work( matrix_order, compz, n, d, e, z, ldz,
                                &work_query, lwork, &iwork_query, liwork );
    if( info != 0 ) {
        goto exit_level_0;
    }
    liwork = (lapack_int)iwork_query;
    lwork = (lapack_int)work_query;
    /* Allocate memory for work arrays */
    iwork = (lapack_int*)LAPACKE_malloc( sizeof(lapack_int) * liwork );
    if( iwork == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    work = (double*)LAPACKE_malloc( sizeof(double) * lwork );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_1;
    }
    /* Call middle-level interface */
    info = LAPACKE_dstedc_work( matrix_order, compz, n, d, e, z, ldz, work,
                                lwork, iwork, liwork );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_1:
    LAPACKE_free( iwork );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dstedc", info );
    }
    return info;
}
开发者ID:checco74,项目名称:uquantchem,代码行数:60,代码来源:lapacke_dstedc.c


示例19: LAPACKE_dggbak

lapack_int LAPACKE_dggbak( int matrix_layout, char job, char side, lapack_int n,
                           lapack_int ilo, lapack_int ihi, const double* lscale,
                           const double* rscale, lapack_int m, double* v,
                           lapack_int ldv )
{
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dggbak", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        if( LAPACKE_d_nancheck( n, lscale, 1 ) ) {
            return -7;
        }
        if( LAPACKE_d_nancheck( n, rscale, 1 ) ) {
            return -8;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, n, m, v, ldv ) ) {
            return -10;
        }
    }
#endif
    return LAPACKE_dggbak_work( matrix_layout, job, side, n, ilo, ihi, lscale,
                                rscale, m, v, ldv );
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:26,代码来源:lapacke_dggbak.c


示例20: LAPACKE_dsgesv

lapack_int LAPACKE_dsgesv( int matrix_layout, lapack_int n, lapack_int nrhs,
                           double* a, lapack_int lda, lapack_int* ipiv,
                           double* b, lapack_int ldb, double* x, lapack_int ldx,
                           lapack_int* iter )
{
    lapack_int info = 0;
    float* swork = NULL;
    double* work = NULL;
    if( matrix_layout != LAPACK_COL_MAJOR && matrix_layout != LAPACK_ROW_MAJOR ) {
        LAPACKE_xerbla( "LAPACKE_dsgesv", -1 );
        return -1;
    }
#ifndef LAPACK_DISABLE_NAN_CHECK
    if( LAPACKE_get_nancheck() ) {
        /* Optionally check input matrices for NaNs */
        if( LAPACKE_dge_nancheck( matrix_layout, n, n, a, lda ) ) {
            return -4;
        }
        if( LAPACKE_dge_nancheck( matrix_layout, n, nrhs, b, ldb ) ) {
            return -7;
        }
    }
#endif
    /* Allocate memory for working array(s) */
    swork = (float*)LAPACKE_malloc( sizeof(float) * MAX(1,n) * MAX(1,n+nrhs) );
    if( swork == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_0;
    }
    work = (double*)LAPACKE_malloc( sizeof(double) * MAX(1,n) * MAX(1,nrhs) );
    if( work == NULL ) {
        info = LAPACK_WORK_MEMORY_ERROR;
        goto exit_level_1;
    }
    /* Call middle-level interface */
    info = LAPACKE_dsgesv_work( matrix_layout, n, nrhs, a, lda, ipiv, b, ldb, x,
                                ldx, work, swork, iter );
    /* Release memory and exit */
    LAPACKE_free( work );
exit_level_1:
    LAPACKE_free( swork );
exit_level_0:
    if( info == LAPACK_WORK_MEMORY_ERROR ) {
        LAPACKE_xerbla( "LAPACKE_dsgesv", info );
    }
    return info;
}
开发者ID:Reference-LAPACK,项目名称:lapack,代码行数:47,代码来源:lapacke_dsgesv.c



注:本文中的LAPACKE_dge_nancheck函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ LAPACKE_dge_trans函数代码示例发布时间:2022-05-30
下一篇:
C++ LAPACKE_d_nancheck函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap