Skip to content

Commit

Permalink
Update rowsum.R
Browse files Browse the repository at this point in the history
  • Loading branch information
pnavaro committed Sep 26, 2024
1 parent da8133e commit fb8fcf3
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions corrections/rowsum.R
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ my.loop <- 20
my.split <- .splitIndices(my.loop, my.size)

my.loop <- unlist(my.split[my.rank+1])
cat("\n", my.loop)

ret <- 0
for(i in my.loop){
Expand All @@ -22,9 +21,7 @@ for(i in my.loop){

res <- mpi.reduce(as.integer(ret), type = 1, op = "sum", dest = 0, comm = 0)

if (my.rank == 0 ) {
cat("\n", res, "\n")
}
if (my.rank == 0 ) { cat("\n", res, "\n") }

invisible(mpi.barrier(comm=0))
invisible(mpi.finalize())

0 comments on commit fb8fcf3

Please sign in to comment.