misc#

Miscellaneous#

This submodule contains models for calculating general or generic values that are useful for all other pore-scale models, such as scaling values, or generating an array of random numbers.

Functions

blank(target)

Blank model used in PNM format, acting as a placeholder

clip(target, prop, xmax[, xmin])

Clips the given array within the supplied limits

constant(target, value)

Places the given constant value into the target object

difference(target, props)

Subtracts elements 1:N in props from element 0

fraction(target, numerator, denominator)

Calculates the ratio between two values

from_neighbor_pores(target, prop[, mode, ...])

Adopt a value based on the values in neighboring pores

from_neighbor_throats(target, prop[, mode, ...])

Adopt a value from the values found in neighboring throats

generic_distribution(network, seeds, func, ...)

Accepts an object from the Scipy.stats submodule and returns values from the distribution for the given seeds

generic_function(target, prop, func, **kwargs)

Runs an arbitrary function on the given data

invert(target, prop)

Inverts the given array

linear(target, m, b, prop)

Calculates a property as a linear function of a given property

match_histogram(network, bin_centers, ...[, ...])

Generate values corresponding to a given histogram

normal(network, seeds[, mean, stddev, ...])

Produces values from a Weibull distribution given a set of random numbers.

normalize(target, prop[, xmin, xmax])

Normalizes the given array between the supplied limits

polynomial(target, a, prop)

Calculates a property as a polynomial function of a given property

product(target, props)

Calculates the product of multiple property values

random(network, element[, seed, num_range])

Create an array of random numbers of a specified size.

scaled(target, prop, factor)

Scales an existing value by a factor.

summation(target[, props])

Sums the values in the given arrays

weibull(network, seeds, shape, scale, loc)

Produces values from a Weibull distribution given a set of random numbers.