basix.variants

Functions to manipulate variant types.

Functions

dpc_variant_to_string(variant)

Convert a Basix DPCVariant enum to a string.

lagrange_variant_to_string(variant)

Convert a Basix LagrangeVariant enum to a string.

string_to_dpc_variant(variant)

Convert a string to a Basix DPCVariant enum.

string_to_lagrange_variant(variant)

Convert a string to a Basix LagrangeVariant enum.

basix.variants.dpc_variant_to_string(variant: basix._basixcpp.DPCVariant) str

Convert a Basix DPCVariant enum to a string.

Parameters

variant – The DPC variant

Returns

The DPC variant as a string.

basix.variants.lagrange_variant_to_string(variant: basix._basixcpp.LagrangeVariant) str

Convert a Basix LagrangeVariant enum to a string.

Parameters

variant – The Lagrange variant

Returns

The Lagrange variant as a string.

basix.variants.string_to_dpc_variant(variant: str) basix._basixcpp.DPCVariant

Convert a string to a Basix DPCVariant enum.

Parameters

variant – The DPC variant as a string.

Returns

The DPC variant

basix.variants.string_to_lagrange_variant(variant: str) basix._basixcpp.LagrangeVariant

Convert a string to a Basix LagrangeVariant enum.

Parameters

variant – The Lagrange variant as a string.

Returns

The Lagrange variant