Meshfree utilities

Approximation base

class edelweissmeshfree.meshfree.approximations.base.basemeshfreeapproximation.BaseMeshfreeApproximation[source]

Base class for meshfree approximations.

In meshfree methods (MLS, RKPM), based on a finite number of kernel (RKPM) or weight (MLS) functions, an approximations can be computed at any point in the domain. This class provides the interface for the computation of such approximations.

Methods

computeShapeFunctionValues(coordinates, ...)

Compute the shape function values at the given coordinates.

abstractmethod computeShapeFunctionValues(coordinates, kernelfunctions)[source]

Compute the shape function values at the given coordinates.

Parameters:
  • coordinates (np.ndarray) – The coordinates at which the shape functions should be evaluated.

  • kernelfunctions (list[BaseKernelFunction]) – The kernel functions that should be used to compute the shape functions.

Returns:

The shape function values at the given coordinates.

Return type:

np.ndarray

Kernel function base

Meshfree kernelfunctions are one of the core ingredients in meshfree methods.

class edelweissmeshfree.meshfree.kernelfunctions.base.basemeshfreekernelfunction.BaseMeshfreeKernelFunction[source]

Base class for meshfree kernel functions. Shape functions are used to interpolate field solutions from the nodes to arbitrary points in the domain. Furthermore, they are the link between the material points and the nodes in meshfree methods.

Each kernel function should be derived from this base class in order to follow the general interface.

Attributes:
center

Get the center of the kernel function.

node

Get the node of the kernel function.

updateCenter

Set the center of the kernel function.

Methods

getCurrentBoundingBox()

Get the bounding box of the kernel function.

isAnyCoordinateInSupport(coords)

Check if any of the given coordinates are in the support of the kernel function.

isCoordinateInCurrentSupport(coords)

Check if the given coordinates are in the support of the kernel function.

abstractmethod getCurrentBoundingBox()[source]

Get the bounding box of the kernel function.

Returns:

The bounding box of the kernel function.

Return type:

tuple[np.ndarray, np.ndarray]

abstractmethod isAnyCoordinateInSupport(coords)[source]

Check if any of the given coordinates are in the support of the kernel function.

Parameters:

coords (ndarray) – The coordinates to check.

Returns:

True if any of the coordinates are in the support of the kernel function, False otherwise.

Return type:

bool

abstractmethod isCoordinateInCurrentSupport(coords)[source]

Check if the given coordinates are in the support of the kernel function.

Parameters:

coords (ndarray) – The coordinates to check.

Returns:

True if the coordinates are in the support of the kernel function, False otherwise.

Return type:

bool

abstract property center: ndarray

Get the center of the kernel function.

Returns:

The center of the kernel function.

Return type:

np.ndarray

abstract property node: Node

Get the node of the kernel function.

Returns:

The node of the kernel function.

Return type:

Node

abstract property updateCenter

Set the center of the kernel function.

Parameters:

center – The center of the kernel function.

Marmot wrappers

Integration helpers

Particle-Kernel-Domains describe the potential interaction between a set of particles and a set of kernel kernel functions. In meshfree methods, particles may convect through the spatial domain, and in general they may interact with different kernel functions at different times. For certain simulations, not all particles should interact with all kernel functions.

Hence, we designate possible interactions between particles and kernel functions by the ParticleKernelDomain class.

class edelweissmeshfree.meshfree.particlekerneldomain.ParticleKernelDomain(particles, meshfreeKernelFunctions)[source]

A class to describe the potential interaction between a set of particles and a set of kernel kernel functions.

Parameters:
Attributes:
meshfreeKernelFunctions
particles

Variationally Consistent Integration is a concept by Chen, Hillman and Ruter (2013) to ensure Galerkin exactness of meshfree methods by employing a Petrov-Galerkin formulation.

It requires the computation of a set of correction terms, depending on the desired order of Galerkin exactness.

The implementation, albeit trivial in concept, does not readily fit into the existing workflow of nonlinear simulations: Before computing the weak form, the correction terms need to be computed, and the weak form needs to be adjusted accordingly. The correction cannot be computed locally (i.e., for each particle during the weak form computation), as it requires global volume and boundary integrals.

class edelweissmeshfree.meshfree.vci.VariationallyConsistentIntegrationManager(particles, meshfreeKernelFunctions, particleBoundaryDefinitions)[source]

A class to describe the potential interaction between a set of particles and a set of kernel kernel functions.

Parameters:
  • particles (list[BaseParticle]) – The list of particles.

  • kernelFunctions – The list of kernel functions.

  • particleBoundaryDefinitions (list[BoundaryParticleDefinition]) – The list of particle boundary definitions used for the boundary integrals.

  • nDim – The number of dimensions of the problem (e.g., 2D or 3D).

  • meshfreeKernelFunctions (list[BaseMeshfreeKernelFunction])

Attributes:
meshfreeKernelFunctions

Methods

computeVCICorrections