Skip to content

Commit 9591c0d

Browse files
authored
fix: linalg enable det() for xdp kinds (#1113)
2 parents 5a4b3bf + a4d963e commit 9591c0d

File tree

3 files changed

+1
-24
lines changed

3 files changed

+1
-24
lines changed

src/linalg/stdlib_linalg.fypp

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -876,8 +876,7 @@ module stdlib_linalg
876876
!! This interface provides methods for computing the determinant of a matrix.
877877
!! Supported data types include `real` and `complex`.
878878
!!
879-
!!@note The provided functions are intended for square matrices only.
880-
!!@note BLAS/LAPACK backends do not currently support extended precision (``xdp``).
879+
!!@note The provided functions are intended for square matrices only.
881880
!!
882881
!!### Example
883882
!!
@@ -898,10 +897,8 @@ module stdlib_linalg
898897
!!```
899898
!!
900899
#:for rk,rt in RC_KINDS_TYPES
901-
#:if rk!="xdp"
902900
module procedure stdlib_linalg_${rt[0]}$${rk}$determinant
903901
module procedure stdlib_linalg_pure_${rt[0]}$${rk}$determinant
904-
#:endif
905902
#:endfor
906903
end interface det
907904

@@ -920,7 +917,6 @@ module stdlib_linalg
920917
!! Supported data types include real and complex.
921918
!!
922919
!!@note The provided functions are intended for square matrices.
923-
!!@note BLAS/LAPACK backends do not currently support extended precision (``xdp``).
924920
!!
925921
!!### Example
926922
!!
@@ -935,15 +931,12 @@ module stdlib_linalg
935931
!!```
936932
!
937933
#:for rk,rt in RC_KINDS_TYPES
938-
#:if rk!="xdp"
939934
module procedure stdlib_linalg_pure_${rt[0]}$${rk}$determinant
940-
#:endif
941935
#:endfor
942936
end interface operator(.det.)
943937

944938
interface
945939
#:for rk,rt in RC_KINDS_TYPES
946-
#:if rk!="xdp"
947940
module function stdlib_linalg_${rt[0]}$${rk}$determinant(a,overwrite_a,err) result(det)
948941
!> Input matrix a[m,n]
949942
${rt}$, intent(inout), target :: a(:,:)
@@ -960,7 +953,6 @@ module stdlib_linalg
960953
!> Matrix determinant
961954
${rt}$ :: det
962955
end function stdlib_linalg_pure_${rt[0]}$${rk}$determinant
963-
#:endif
964956
#:endfor
965957
end interface
966958

@@ -1216,7 +1208,6 @@ module stdlib_linalg
12161208
!! Preallocated space for both eigenvalues `lambda` and the eigenvector matrices must be user-provided.
12171209
!!
12181210
!!@note The solution is based on LAPACK's general eigenproblem solvers `*GEEV`.
1219-
!!@note BLAS/LAPACK backends do not currently support extended precision (``xdp``).
12201211
!!
12211212
#:for rk,rt,ri in RC_KINDS_TYPES
12221213
#:for ep,ei in EIG_PROBLEM_LIST
@@ -1294,7 +1285,6 @@ module stdlib_linalg
12941285
!! as an optional `type(linalg_state_type)` output flag.
12951286
!!
12961287
!!@note The solution is based on LAPACK's general eigenproblem solvers `*GEEV`.
1297-
!!@note BLAS/LAPACK backends do not currently support extended precision (``xdp``).
12981288
!!
12991289
#:for rk,rt,ri in RC_KINDS_TYPES
13001290
#:for ep,ei in EIG_PROBLEM_LIST
@@ -1349,7 +1339,6 @@ module stdlib_linalg
13491339
!! Preallocated space for both eigenvalues `lambda` and the eigenvector matrix must be user-provided.
13501340
!!
13511341
!!@note The solution is based on LAPACK's eigenproblem solvers `*SYEV`/`*HEEV`.
1352-
!!@note BLAS/LAPACK backends do not currently support extended precision (``xdp``).
13531342
!!
13541343
#:for rk,rt,ri in RC_KINDS_TYPES
13551344
module subroutine stdlib_linalg_eigh_${ri}$(a,lambda,vectors,upper_a,overwrite_a,err)
@@ -1392,7 +1381,6 @@ module stdlib_linalg
13921381
!! as an optional `type(linalg_state_type)` output flag.
13931382
!!
13941383
!!@note The solution is based on LAPACK's eigenproblem solvers `*SYEV`/`*HEEV`.
1395-
!!@note BLAS/LAPACK backends do not currently support extended precision (``xdp``).
13961384
!!
13971385
#:for rk,rt,ri in RC_KINDS_TYPES
13981386
module function stdlib_linalg_eigvalsh_${ri}$(a,upper_a,err) result(lambda)

src/linalg/stdlib_linalg_determinant.fypp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@ submodule (stdlib_linalg) stdlib_linalg_determinant
1313

1414
contains
1515

16-
! BLAS/LAPACK backends do not currently support xdp
1716
#:for rk,rt in RC_KINDS_TYPES
18-
#:if rk!="xdp"
1917
pure module function stdlib_linalg_pure_${rt[0]}$${rk}$determinant(a) result(det)
2018
!!### Summary
2119
!! Compute determinant of a real square matrix (pure interface).
@@ -233,7 +231,6 @@ submodule (stdlib_linalg) stdlib_linalg_determinant
233231

234232
end function stdlib_linalg_${rt[0]}$${rk}$determinant
235233

236-
#:endif
237234
#:endfor
238235

239236
end submodule stdlib_linalg_determinant

test/linalg/test_linalg_determinant.fypp

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,21 +22,16 @@ module test_linalg_determinant
2222
allocate(tests(0))
2323

2424
#:for rk,rt in RC_KINDS_TYPES
25-
#:if rk!="xdp"
2625
call add_test(tests,new_unittest("$eye_det_${rt[0]}$${rk}$",test_${rt[0]}$${rk}$_eye_determinant))
2726
call add_test(tests,new_unittest("$eye_det_multiple_${rt[0]}$${rk}$",test_${rt[0]}$${rk}$_eye_multiple))
28-
#:endif
2927
#:endfor
3028
#:for ck,ct in CMPLX_KINDS_TYPES
31-
#:if ck!="xdp"
3229
call add_test(tests,new_unittest("$complex_det_${rt[0]}$${rk}$",test_${ct[0]}$${ck}$_complex_determinant))
33-
#:endif
3430
#: endfor
3531

3632
end subroutine test_matrix_determinant
3733

3834
#:for rk,rt in RC_KINDS_TYPES
39-
#:if rk!="xdp"
4035
!> Determinant of identity matrix
4136
subroutine test_${rt[0]}$${rk}$_eye_determinant(error)
4237
type(error_type), allocatable, intent(out) :: error
@@ -96,12 +91,10 @@ module test_linalg_determinant
9691
'det(0.01*eye(n))==0.01^n')
9792

9893
end subroutine test_${rt[0]}$${rk}$_eye_multiple
99-
#:endif
10094
#:endfor
10195

10296
!> Determinant of complex identity matrix
10397
#:for ck,ct in CMPLX_KINDS_TYPES
104-
#:if ck!="xdp"
10598
subroutine test_${ct[0]}$${ck}$_complex_determinant(error)
10699
type(error_type), allocatable, intent(out) :: error
107100

@@ -141,7 +134,6 @@ module test_linalg_determinant
141134

142135
end subroutine test_${ct[0]}$${ck}$_complex_determinant
143136

144-
#:endif
145137
#:endfor
146138

147139
! gcc-15 bugfix utility

0 commit comments

Comments
 (0)