Skip to content
Open
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
5 changes: 0 additions & 5 deletions julia/MOLE.jl/src/BCs/scalarBC.jl
Original file line number Diff line number Diff line change
Expand Up @@ -269,9 +269,6 @@ function addScalarBC!(A::SparseMatrixCSC, b::AbstractVector, bc::ScalarBC2D{T},
# remove rows of A associated to boundary
Abc1 = Abcl .+ Abcr
rowsbc1, _, _ = findnz(Abc1)
# For some reason, the below code doesn't work:
# rows1, cols1, s1 = findnz(A[rowsbc1, :])
# A = A .- sparse(rows1, cols1, s1, size(A, 1), size(A, 2))
A[rowsbc1, :] = spzeros(size(A[rowsbc1, :])) # This does though
# Update matrix A with boundary information
A = A .+ Abc1
Expand All @@ -290,8 +287,6 @@ function addScalarBC!(A::SparseMatrixCSC, b::AbstractVector, bc::ScalarBC2D{T},
# Remove rows of A associated to boundary
Abc2 = Abct .+ Abcb
rowsbc2, _, _ = findnz(Abc2)
# rows2, cols2, s2 = findnz(A[rowsbc2, :])
# A = A .- sparse(rows2, cols2, s2, size(A, 1), size(A, 2))
A[rowsbc2, :] = spzeros(size(A[rowsbc2, :]))
# Update matriz A with boundary information
A = A .+ Abc2
Expand Down