MCPcopy Create free account
hub / github.com/FEniCS/dolfinx / _create_expression

Method _create_expression

python/dolfinx/fem/function.py:208–218  ·  view source on GitHub ↗
(dtype)

Source from the content-addressed store, hash-verified

206 raise RuntimeError("Expressions with more that one Argument not allowed.")
207
208 def _create_expression(dtype):
209 if np.issubdtype(dtype, np.float32):
210 return _cpp.fem.create_expression_float32
211 elif np.issubdtype(dtype, np.float64):
212 return _cpp.fem.create_expression_float64
213 elif np.issubdtype(dtype, np.complex64):
214 return _cpp.fem.create_expression_complex64
215 elif np.issubdtype(dtype, np.complex128):
216 return _cpp.fem.create_expression_complex128
217 else:
218 raise NotImplementedError(f"Type {dtype} not supported.")
219
220 _entity_maps = (
221 [entity_map._cpp_object for entity_map in entity_maps]

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected