Displaying 1 result from an estimated 1 matches for "gcd2".
Did you mean:
gcc2
2001 Feb 16
1
Sub_scribe and a question
...")
})[3]
cumulate <- cumulate + timing
}
timing <- cumulate/runs
times[2, 3] <- timing
cat(c("Creation of a 1500x1500 Hilbert matrix (matrix calc) (sec): ", =
timing, "\n"))
remove("a", "b")
flush.console()
# (3)
cumulate <- 0; c <- 0
gcd2 <- function(x, y) {if (sum(y > 1.0E-4) =3D=3D 0) x else {y[y =3D=3D =
0] <- x[y =3D=3D 0]; gcd2(y, x %% y)}}
for (i in 1:runs) {
a <- ceiling(runif(35000, max=3D1000))
b <- ceiling(runif(35000, max=3D1000))
timing <- system.time({ =20
c <- gcd2(a, b)...