ansys.materials.manager._models._common.polynomial
#
Module Contents#
Classes#
Provides the polynomial model for a property. |
Attributes#
- ansys.materials.manager._models._common.polynomial.TYPE_CHECKING = False#
- class ansys.materials.manager._models._common.polynomial.Polynomial(name: str, coefficients: numpy.ndarray, sample_points: Optional[numpy.ndarray] = None)#
Bases:
ansys.materials.manager._models._common._base._BaseModel
Provides the polynomial model for a property.
This class represents a property as a polynomial with a series of coefficients. These are stored in ascending powers of the parameters.
Create a polynomial model for a property.
This model represents an nth order polynomial. The coefficients are stored and entered in ascending order. For some packages, the polynomial is evaluated and then interpolated. In these cases sample points may be provided and should cover the range of interest.
For example, providing
[3., 4., 1.]
represents this equation:\[\]f(x) = 3 + 4x + x^{2}
This property is created in the default unit system of the solver. Ensure that you provide values in the correct units.
- Parameters:
- name: str
Name of the property to model as a constant.
- coefficients: np.ndarray
Values of the coefficients for the polynomial model, provided in ascending powers of the parameter.
- sample_points: Optional[np.ndarray]
Values of the parameter to use for interpolation, which are required for some packages.
- property coefficients: numpy.ndarray#
Values of the
x
array.
- applicable_packages: SupportedPackage.MAPDL | SupportedPackage.FLUENT#
- write_model(material: ansys.materials.manager.material.Material, pyansys_session: Any) None #
Write this model to MAPDL.
This method Should make some effort to validate the model state before writing.
- Parameters:
- material: Material
Material object to associate with this model.
- pyansys_session: Any
Configured instance of the PyAnsys session.