dedalus.core.subsystems

Classes for manipulating pencils.

Module Contents

logger
build_subsystems(solver)

Build local subsystem objects.

build_subproblems(solver, subsystems, build_matrices=None)

Build subproblem matrices with progress logger.

build_subproblem_matrices(solver, subproblems, matrices)
class Subsystem(solver, group)

Class representing a subset of the global coefficient space. I.e. the multidimensional generalization of a pencil.

Each subsystem is described by a “group” tuple containing a group index (for each separable axis) or None (for each coupled axis).

coeff_slices(domain)
coeff_shape(domain)
coeff_size(domain)
field_slices(field)
field_shape(field)
field_size(field)
gather(fields)

Gather and concatenate subsystem data in from multiple fields.

scatter(data_input, fields)

Scatter concatenated subsystem data out to multiple fields.

class Subproblem(solver, subsystems, group)

Object representing one coupled subsystem of a problem.

Subproblems are identified by their group multi-index, which identifies the corresponding group of each separable dimension of the problem.

This is the generalization of ‘pencils’ from a problem with exactly one coupled dimension.

coeff_slices(domain)
coeff_shape(domain)
coeff_size(domain)
field_slices(field)
field_shape(field)
field_size(field)
gather(fields)

Gather and concatenate subproblem data in from multiple fields.

scatter(data_input, fields)

Scatter concatenated subproblem data out to multiple fields.

inclusion_matrices(bases)

List of inclusion matrices.

valid_modes(field)
check_condition(eqn)
build_matrices(names)

Build problem matrices.

expand_matrices(matrices)
left_permutation(subproblem, equations, bc_top, interleave_components)

Left permutation acting on equations. bc_top determines if lower-dimensional equations are placed at the top or bottom of the matrix.

Input ordering:

Equations > Components > Modes

Output ordering with interleave_components=True:

Modes > Components > Equations

Output ordering with interleave_components=False:

Modes > Equations > Components

right_permutation(subproblem, variables, tau_left, interleave_components)

Right permutation acting on variables. tau_left determines if lower-dimensional variables are placed at the left or right of the matrix.

Input ordering:

Variables > Components > Modes

Output ordering with interleave_components=True:

Modes > Components > Variables

Output ordering with interleave_components=False:

Modes > Variables > Components