Skip to content

Commit 37cfb0c

Browse files
Will KimmererViralBShah
authored andcommitted
Some updates to more recent API.
1 parent 9b8b7f7 commit 37cfb0c

1 file changed

Lines changed: 2 additions & 7 deletions

File tree

‎examples/Sandia.jl‎

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,8 @@ using LinearAlgebra
1212
#A is the input matrix, Output: Triangle Count
1313
function sandia(A)
1414

15-
#extracting lower matrix from input matrix
1615
L = tril(A)
17-
18-
19-
C = mul(L, L, Semirings.PLUS_TIMES, mask=L)
20-
result = reduce(Monoids.PLUS_MONOID, C, dims=:)
21-
22-
return result
16+
C = *(+, *; mask=L)(L, L)
17+
return reduce(+, C, dims=:)
2318

2419
end

0 commit comments

Comments
 (0)