You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Update to Documenter@1 and fix failures. Also update Quaternions to
same version used for tests. The old version had larger struct sizes
so revealed a bug in the new ldlt code for the blocksize determination.
This bug was fixed here.
Copy file name to clipboardExpand all lines: src/svd.jl
+6-4Lines changed: 6 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -567,19 +567,21 @@ LinearAlgebra.svdvals!(B::Bidiagonal{T}; tol = eps(T)) where {T<:Real} =
567
567
svdvals!(A [, tol])
568
568
569
569
Generic computation of singular values.
570
+
571
+
# Examples
570
572
```jldoctest
571
573
julia> using LinearAlgebra, GenericLinearAlgebra, Quaternions
572
574
573
575
julia> n = 20;
574
576
575
577
julia> H = [big(1)/(i + j - 1) for i in 1:n, j in 1:n]; # The Hilbert matrix
576
578
577
-
julia> Float64(svdvals(H)[end]/svdvals(Float64.(H))[end] - 1) # The relative error of the LAPACK based solution in 64 bit floating point.
578
-
-0.9999999999447275
579
+
julia> round(svdvals(H)[end]/svdvals(Float64.(H))[end] - 1, sigdigits=8) # The relative error of the LAPACK based solution rounded to eight significant digits.
580
+
-1.0
579
581
580
582
julia> A = qr([Quaternion(randn(4)...) for i in 1:3, j in 1:3]).Q *
581
583
Diagonal([3, 2, 1]) *
582
-
qr([Quaternion(randn(4)...) for i in 1:3, j in 1:3]).Q'; # A quaternion matrix with the singular value 1, 2, and 3.
584
+
qr([Quaternion(randn(4)...) for i in 1:3, j in 1:3]).Q';
583
585
584
586
julia> svdvals(A) ≈ [3, 2, 1]
585
587
true
@@ -617,7 +619,7 @@ A generic singular value decomposition (SVD). The implementation only uses Julia
0 commit comments