src.pydasa.core.basic ===================== .. py:module:: src.pydasa.core.basic .. autoapi-nested-parse:: Module basic.py =========================================== This module provides base classes with common validation logic used across different classes to minimize code duplication in **PyDASA**. **IMPORTANT** - Based on the theory from H. Görtler, *Dimensionalanalyse: Eine Theoririe der physikalischen Dimensionen mit Anwendungen* Classes ------- .. autoapisummary:: src.pydasa.core.basic.SymBasis src.pydasa.core.basic.IdxBasis src.pydasa.core.basic.Foundation Module Contents --------------- .. py:class:: SymBasis Bases: :py:obj:`abc.ABC` Abstract Class to manage the entity's symbolic, sorting, and dimensional domain/framework functionalities in **PyDASA**. Inherits from: - **ABC**: Python Abstract Base Class to indicate that this class is not meant to be instantiated directly. .. py:method:: __post_init__() Post initialization processing and validation for symbolic attributes. .. py:property:: sym :type: str Get the entity's symbol. :returns: Symbol value. :rtype: str .. py:property:: fwk :type: str Get the entity's framework. :returns: Frameworks value. :rtype: str .. py:property:: alias :type: Optional[str] Get the Python variable synonym. :returns: Python variable name. e.g.: `\rho_{1}` -> `rho_1`. :rtype: Optional[str] .. py:method:: clear() Reset symbol, alias, and framework attributes to default values. .. py:class:: IdxBasis Bases: :py:obj:`SymBasis` Basic class to manage index/precedence functionalities in **PyDASA** entities. Inherits from: - **SymBasis**: Inherits symbol and framework validation. .. py:method:: __post_init__() Post initialization processing and validation for index and precedence. .. py:property:: idx :type: int Get the index/precedence value. :returns: Index value. :rtype: int .. py:method:: clear() Reset index and inherited symbol attributes to default values. .. py:class:: Foundation Bases: :py:obj:`IdxBasis` Basic class to manage common attributes and validation logic for dimensional analysis entities in **PyDASA**. Provides common validation logic and attributes shared by dimensional framework/domain, Variable, and Coeffcient classes. Inherits from: - **IdxBasis**: Inherits index, symbol, and framework validation. .. py:attribute:: description :type: str :value: '' Brief summary or description of the entity. .. py:method:: __post_init__() Post initialization and processing for name and description attributes. .. py:property:: name :type: str Get the entity's name. :returns: Name value. :rtype: str .. py:method:: clear() Reset name, description, and inherited attributes to default values. .. py:method:: __str__() Return string representation with all non-private attributes for detailed inspection and logging. :returns: Detailed string representation. :rtype: str .. py:method:: __repr__() Return the entity's str representation. :returns: String representation. :rtype: str