https://github.com/cran/ReacTran
Tip revision: 72984f188f682cc270e18126009c8e56b7aab80d authored by Karline Soetaert on 10 August 2011, 00:00:00 UTC
version 1.3.2
version 1.3.2
Tip revision: 72984f1
fiadeiro.R
##==============================================================================
## The Fiadeiro and Veronis scheme: advective finite difference weights (AFDW)
##==============================================================================
fiadeiro <- function(v, D, dx.aux=NULL, grid=list(dx.aux=dx.aux)) {
Pe <- abs(v)*grid$dx.aux/D
sigma <- (1+(1/tanh(Pe)-1/Pe))/2
return(sigma)
}