fssi3d: Frequency of Sites on a Square Isotropic 3D lattice with...

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

fssi3d() function calculates the relative frequency distribution of isotropic clusters on 3D square lattice with Moore (1,d)-neighborhood.

Usage

1
2
fssi3d(n=1000, x=33, p0=0.2, p1=p0/2, p2=p0/3, 
       set=(x^3+1)/2, all=TRUE, shape=c(1,1))

Arguments

n

a sample size.

x

a linear dimension of 3D square percolation lattice.

p0

a relative fraction (0<p0)&(p0<1) of accessible sites (occupation probability) for percolation lattice.

p1

p0 value, weighted by Minkowski distance: p1=p0/rhoMe1.

p2

p0 value, weighted by Minkowski distance: p2=p0/rhoMe2.

set

a vector of linear indexes of a starting sites subset.

all

logical; if all=TRUE, mark all sites from a starting subset; if all=FALSE, mark only accessible sites from a starting subset.

shape

a vector with two shape parameters of beta-distributed random variables, weighting the percolation lattice sites.

Details

The percolation is simulated on 3D square lattice with uniformly weighted sites and the constant parameters p0, p1, and p2.

The isotropic cluster is formed from the accessible sites connected with initial sites subset set.

Moore (1,d)-neighborhood on 3D square lattice consists of sites, at least one coordinate of which is different from the current site by one: e=c(e0,e1,e2), where
e0=c(-1, 1, -x, x, -x^2, x^2);
e1=colSums(matrix(e0[c(1,3, 2,3, 1,4, 2,4, 1,5, 2,5, 1,6, 2,6, 3,5, 4,5, 3,6, 4,6)], nrow=2));
e2=colMeans(matrix(p0[c(1,3,5, 2,3,5, 1,4,5, 2,4,5, 1,3,6, 2,3,6, 1,4,6, 2,4,6)], nrow=3)).

Minkowski distance between sites a and b depends on the exponent d:
rhoM <- function(a, b, d=1)
if (is.infinite(d)) return(apply(abs(b-a), 2, max))
else return(apply(abs(b-a)^d, 2, sum)^(1/d)).

Minkowski distance for sites from e1 and e2 subsets with the exponent d=1 is equal to rhoMe1=2 and rhoMe2=3.

Each element of the matrix frq is equal to the relative frequency with which the 3D square lattice site belongs to a cluster sample of size n.

Value

rfq

a 3D matrix of relative sampling frequencies for sites of the percolation lattice.

Author(s)

Pavel V. Moskalev <moskalefff@gmail.com>

References

[1] Moskalev, P.V. Percolation modeling of porous structures. Moscow: URSS, 2018. 240 pp; in Russian.

See Also

ssi3d, fssi2d, fssi20, fssi30, fssa2d, fssa3d

Examples

1
2
3
4
5
6
x <- y <- seq(33)
rfq <- fssi3d(n=200, p0=.285)
image(x, y, rfq[,,17], cex.main=1, 
main="Frequencies in the z=17 slice of isotropic (1,1)-clusters")
contour(x, y, rfq[,,17], levels=c(0.2,0.25,0.3), add=TRUE)
abline(h=17, lty=2); abline(v=17, lty=2)

SPSL documentation built on May 2, 2019, 12:34 p.m.