coordinates.coordinate_systems.CartesianCoordinateSystem2D.set_expression#

CartesianCoordinateSystem2D.set_expression(expression_name: str, expression: Symbol | Expr | MutableDenseMatrix | MutableDenseNDimArray | ImmutableDenseMatrix | ImmutableDenseNDimArray, overwrite: bool = False)#

Set a symbolic expression at the instance level.

Parameters:
  • expression_name (str) – The name of the symbolic expression to register.

  • expression (sympy expression) – The symbolic expression to register.

  • overwrite (bool, optional) – If True, overwrite an existing expression with the same name. Defaults to False.

Raises:

ValueError – If the expression name already exists and overwrite is False.