<T>LAPACK 0.1.1
C++ Template Linear Algebra PACKage
Loading...
Searching...
No Matches
potrf.hpp
Go to the documentation of this file.
1
3//
4// Copyright (c) 2021-2023, University of Colorado Denver. All rights reserved.
5//
6// This file is part of <T>LAPACK.
7// <T>LAPACK is free software: you can redistribute it and/or modify it under
8// the terms of the BSD 3-Clause license. See the accompanying LICENSE file.
9
10#ifndef TLAPACK_LEGACY_POTRF_HH
11#define TLAPACK_LEGACY_POTRF_HH
12
14
15namespace tlapack {
16namespace legacy {
17
25 template <class uplo_t, typename T>
26 int potrf(uplo_t uplo, idx_t n, T* A, idx_t lda)
27 {
28 using internal::create_matrix;
29
30 // check arguments
31 tlapack_check_false(uplo != Uplo::Lower && uplo != Uplo::Upper);
32
33 // Matrix views
34 auto A_ = create_matrix(A, n, n, lda);
35
36 return potrf_blocked(uplo, A_);
37 }
38
39} // namespace legacy
40} // namespace tlapack
41
42#endif // TLAPACK_LEGACY_POTRF_HH
int potrf_blocked(uplo_t uplo, matrix_t &A, const BlockedCholeskyOpts &opts)
Computes the Cholesky factorization of a Hermitian positive definite matrix A using a blocked algorit...
Definition potrf_blocked.hpp:66
#define tlapack_check_false(cond)
Throw an error if cond is true.
Definition exceptionHandling.hpp:113
int potrf(uplo_t uplo, idx_t n, T *A, idx_t lda)
Computes the Cholesky factorization of a Hermitian positive definite matrix A using a blocked algorit...
Definition potrf.hpp:26
Computes the Cholesky factorization of a Hermitian positive definite matrix A.
typename traits::real_type_traits< Types..., int >::type real_type
The common real type of the list of types.
Definition scalar_type_traits.hpp:113