Skip to content

Commit 9467d61

Browse files
committed
Remove broadcasting in fill_dual_variables!
- Fixes a bug that showed up in tests with Julia v1.5
1 parent a2936c9 commit 9467d61

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/chordal_decomposition.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ function reverse_decomposition!(ws::COSMO.Workspace{T}, settings::COSMO.Settings
119119

120120
mO = ws.ci.originalM
121121
nO = ws.ci.originalN
122-
122+
@show(nO, mO)
123123
vars = Variables{T}(mO, nO, ws.ci.originalC)
124124
vars.x .= ws.vars.x[1:nO]
125125

@@ -150,9 +150,9 @@ function fill_dual_variables!(ws::COSMO.Workspace{T}, vars::COSMO.Variables{T})
150150
# # to remove the overlaps we take the average of the values for each overlap by dividing by the number of blocks that overlap in a particular entry, i.e. number of 1s in each row of H
151151
rowInd, nnzs = number_of_overlaps_in_rows(H)
152152

153-
for iii=1:length(rowInd)
153+
for iii = 1:length(rowInd)
154154
ri = rowInd[iii]
155-
vars.μ[ri] .= vars.μ[ri] / nnzs[iii]
155+
vars.μ[ri] = vars.μ[ri] / nnzs[iii]
156156
end
157157
return nothing
158158
end

0 commit comments

Comments
 (0)