Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions src/decompression.jl
Original file line number Diff line number Diff line change
Expand Up @@ -459,25 +459,24 @@ function decompress_single_color!(
(; S) = ag
uplo == :F && check_same_pattern(A, S)

offset = (c - 1) * S.n
lower_index = offset + 1
lower_index = (c - 1) * S.n + 1
upper_index = c * S.n
rvS = rowvals(S)
for j in group[c]
for k in nzrange(S, j)
# Check if the color c is used to recover A[i,j] / A[j,i]
if lower_index <= compressed_indices[k] <= upper_index
l = compressed_indices[k] - offset
i = rvS[k]
if i == j
# Recover the diagonal coefficients of A
A[i, i] = b[l]
A[i, i] = b[i]
else
# Recover the off-diagonal coefficients of A
if in_triangle(i, j, uplo)
A[i, j] = b[l]
A[i, j] = b[i]
end
if in_triangle(j, i, uplo)
A[j, i] = b[l]
A[j, i] = b[i]
end
end
end
Expand Down