441 {
442 double *A, *AP;
447
451
453 LDA = *n;
454 A = ( double* )malloc( LDA*LDA*sizeof( double ) );
455 AP = ( double* )malloc( (((LDA+1)*LDA)/2)*sizeof( double ) );
457 for( j=0, k=0; j<*n; j++ )
458 for( i=0; i<j+1; i++, k++ )
459 A[ LDA*i+j ]=ap[ k ];
460 for( i=0, k=0; i<*n; i++ )
461 for( j=i; j<*n; j++, k++ )
462 AP[ k ]=A[ LDA*i+j ];
463
464 }
465 else {
466 for( j=0, k=0; j<*n; j++ )
467 for( i=j; i<*n; i++, k++ )
468 A[ LDA*i+j ]=ap[ k ];
469 for( i=0, k=0; i<*n; i++ )
470 for( j=0; j<i+1; j++, k++ )
471 AP[ k ]=A[ LDA*i+j ];
472 }
474 free(A);
475 free(AP);
476 }
477 else
479}
void cblas_dtpsv(CBLAS_LAYOUT layout, CBLAS_UPLO Uplo, CBLAS_TRANSPOSE TransA, CBLAS_DIAG Diag, const CBLAS_INT N, const double *Ap, double *X, const CBLAS_INT incX)
void get_diag_type(char *type, CBLAS_DIAG *diag)
void get_uplo_type(char *type, CBLAS_UPLO *uplo)
void get_transpose_type(char *type, CBLAS_TRANSPOSE *trans)