File tree 2 files changed +15
-0
lines changed
2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -1865,6 +1865,11 @@ end
1865
1865
# SIAM J. Sci. Comput., 34(4), (2012) C153–C169. doi: 10.1137/110852553
1866
1866
# Algorithm 5.1
1867
1867
Base. @propagate_inbounds function _sqrt_pow_diag_block_2x2! (A, A0, s)
1868
+ if iszero (s)
1869
+ A[1 ,1 ] -= 1
1870
+ A[2 ,2 ] -= 1
1871
+ return A
1872
+ end
1868
1873
_sqrt_real_2x2! (A, A0)
1869
1874
if isone (s)
1870
1875
A[1 ,1 ] -= 1
Original file line number Diff line number Diff line change 885
885
@test V == Diagonal ([1 , 1 ])
886
886
end
887
887
888
+ @testset " log_quasitriu with internal scaling s=0 (issue #54833)" begin
889
+ M = [0.9949357359852791 - 0.015567763143324862 - 0.09091193493947397 - 0.03994428739762443 0.07338356301650806 ;
890
+ 0.011813655598647289 0.9968988574699793 - 0.06204555000202496 0.04694097614450692 0.09028834462782365 ;
891
+ 0.092737943594701 0.059546719185135925 0.9935850721633324 0.025348893985651405 - 0.018530261590167685 ;
892
+ 0.0369187299165628 - 0.04903571106913449 - 0.025962938675946543 0.9977767446862031 0.12901494726320517 ;
893
+ 0.0 0.0 0.0 0.0 1.0 ]
894
+
895
+ @test exp (log (M)) ≈ M
896
+ end
897
+
888
898
end # module TestTriangular
You can’t perform that action at this time.
0 commit comments