@@ -29,10 +29,10 @@ spectrumBound <- nimbleFunction(
2929 Min <- Inf
3030 Max <- - Inf
3131 for ( i in 1 : q [1 ] ){
32- centre <- A [i ,i ]
33- radius <- sum(abs(A [i ,])) - abs(centre )
34- minC <- centre - radius
35- maxC <- centre + radius
32+ center <- A [i ,i ]
33+ radius <- sum(abs(A [i ,])) - abs(center )
34+ minC <- center - radius
35+ maxC <- center + radius
3636 if (minC < Min ) Min <- minC
3737 if (maxC > Max ) Max <- maxC
3838 }
@@ -94,7 +94,7 @@ expAv <- nimbleFunction(
9494 if (q [2 ] != q [1 ]) stop(" A must be a square matrix." )
9595 if (length(v ) != q [1 ]) stop(" Length of v must be equal to the number of columns of A." )
9696
97- # # Only centre , perform uniformization, if no diag > 0.
97+ # # Only center , perform uniformization, if no diag > 0.
9898 CR <- spectrumBound(A )
9999 diag(A ) <- diag(A ) - CR [1 ]
100100 ans <- v
@@ -209,7 +209,7 @@ expm <- nimbleFunction(
209209 if (dim(A )[1 ] != dim(A )[2 ]) stop(" `A' must be a square matrix" )
210210 # if(dim(tol)[1] > 1) stop("`tol' must be a scalar.")
211211
212- # # Only centre , perform uniformization, if no diag > 0.
212+ # # Only center , perform uniformization, if no diag > 0.
213213 CR <- spectrumBound(A )
214214 Niter <- 1L
215215 C <- CR [1 ]
@@ -249,5 +249,5 @@ expm <- nimbleFunction(
249249
250250 for ( i in 1 : s ) expMsmall <- expMsmall %*% expMsmall
251251 return (expMsmall )
252- }# , buildDerivs = TRUE
252+ } # , buildDerivs = TRUE
253253)
0 commit comments