Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

pymrm.coupling

Back to modules overview

Sparse-matrix utilities for multi-domain coupling and interface assembly.

View module source on GitHub

Public API

SymbolTypeSummary
construct_interface_matricesfunctionConstruct implicit interface-coupling matrices for two adjacent domains.
translate_indices_to_larger_arrayfunctionMap flat indices from a local array shape to a larger embedding shape.
update_array_indicesfunctionUpdate sparse-matrix indices for a new embedding shape.
update_csc_array_indicesfunctionUpdate CSC matrix row/column indexing for embedding in a larger domain.
update_csr_array_indicesfunctionUpdate CSR matrix row/column indexing for embedding in a larger domain.

construct_interface_matrices(shapes, x_fs, x_cs = (None, None), ic = ({'a': (1, 1), 'b': (0, 0), 'd': 0}, {'a': (0, 0), 'b': (1, -1), 'd': 0}), axis = 0, shapes_d = (None, None), format = 'csc')

Open dedicated reference page

Construct implicit interface-coupling matrices for two adjacent domains.

Parameters

Returns

View source on GitHub

translate_indices_to_larger_array(linear_indices, shape, new_shape, offset = None)

Open dedicated reference page

Map flat indices from a local array shape to a larger embedding shape.

Parameters

Returns

View source on GitHub

update_array_indices(sparse_mat, shape, new_shape, offset = None)

Open dedicated reference page

Update sparse-matrix indices for a new embedding shape.

Parameters

Returns

View source on GitHub

update_csc_array_indices(sparse_mat, shape, new_shape, offset = None)

Open dedicated reference page

Update CSC matrix row/column indexing for embedding in a larger domain.

.. deprecated:: Use update_array_indices for automatic format dispatch.

View source on GitHub

update_csr_array_indices(sparse_mat, shape, new_shape, offset = None)

Open dedicated reference page

Update CSR matrix row/column indexing for embedding in a larger domain.

View source on GitHub