Skip to content

Commit 4e0d678

Browse files
authored
Merge pull request #82 from cgeoga/main
Error fixes for #81
2 parents 88a154f + d654f9d commit 4e0d678

3 files changed

Lines changed: 10 additions & 6 deletions

File tree

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "HMatrices"
22
uuid = "8646bddf-ab1c-4fa7-9c51-ba187d647618"
3-
version = "0.2.12"
3+
version = "0.2.13"
44

55
[deps]
66
Distributed = "8ba89e20-285c-5b6f-9357-94700520ee1b"

src/compressor.jl

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -137,9 +137,13 @@ function _aca_partial(K, irange, jrange, atol, rmax, rtol, istart, buffer_ = not
137137
if isnothing(i)
138138
# ran out of candidate rows. Good case: the matrix is zero. Bad
139139
# case: aca failed
140-
all(j -> iszero(K[first(irange), j]), jrange) &&
141-
all(i -> iszero(K[i, first(jrange)]), irange) ||
142-
@warn "aca possibly failed on $irange × $jrange"
140+
if K isa KernelMatrix
141+
all(j -> iszero(K[first(irange), j]), jrange) &&
142+
all(i -> iszero(K[i, first(jrange)]), irange) ||
143+
@warn "aca possibly failed on $irange × $jrange" maxlog=1
144+
else
145+
@warn "aca possibly failed on $irange × $jrange" maxlog=1
146+
end
143147
break
144148
end
145149
else # δ != 0

src/multiplication.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ Multiplication when the target is a dense matrix. The numbering system in the fo
221221
function _mul_dense!(C::Base.Matrix, A, B, a)
222222
Adata = isleaf(A) ? data(A) : A
223223
Bdata = isleaf(B) ? data(B) : B
224-
if Adata isa HMatrix
224+
if Adata isa HMatrix || Adata isa AdjointHMatrix
225225
if Bdata isa Matrix
226226
_mul131!(C, Adata, Bdata, a)
227227
elseif Bdata isa RkMatrix
@@ -235,7 +235,7 @@ function _mul_dense!(C::Base.Matrix, A, B, a)
235235
elseif Bdata isa HMatrix
236236
_mul113!(C, Adata, Bdata, a)
237237
end
238-
elseif Adata isa RkMatrix
238+
elseif Adata isa RkMatrix || Adata isa AdjointHMatrix
239239
if Bdata isa Matrix
240240
_mul121!(C, Adata, Bdata, a)
241241
elseif Bdata isa RkMatrix

0 commit comments

Comments
 (0)