File tree 2 files changed +17
-0
lines changed
2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change 114
114
ctranspose (A:: Hermitian ) = A
115
115
trace (A:: Hermitian ) = real (trace (A. data))
116
116
117
+ Base. conj (A:: HermOrSym ) = typeof (A)(conj (A. data), A. uplo)
118
+ Base. conj! (A:: HermOrSym ) = typeof (A)(conj! (A. data), A. uplo)
119
+
117
120
# tril/triu
118
121
function tril (A:: Hermitian , k:: Integer = 0 )
119
122
if A. uplo == ' U' && k <= 0
Original file line number Diff line number Diff line change @@ -236,3 +236,17 @@ let A = Symmetric(randn(5,5))
236
236
B = - A
237
237
@test A + B ≈ zeros (5 ,5 )
238
238
end
239
+
240
+ # 17780
241
+ let a = randn (2 ,2 )
242
+ a = a' a
243
+ b = complex (a,a)
244
+ c = Symmetric (b)
245
+ @test conj (c) == conj (Array (c))
246
+ cc = copy (c)
247
+ @test conj! (c) == conj (Array (cc))
248
+ c = Hermitian (b + b' )
249
+ @test conj (c) == conj (Array (c))
250
+ cc = copy (c)
251
+ @test conj! (c) == conj (Array (c))
252
+ end
You can’t perform that action at this time.
0 commit comments