diff options
author | Nao Pross <np@0hm.ch> | 2024-05-11 19:32:34 +0200 |
---|---|---|
committer | Nao Pross <np@0hm.ch> | 2024-05-12 15:18:35 +0200 |
commit | f094e4d91b44fc1e8b5f11aac2dd8073ba024fc8 (patch) | |
tree | 6d43f6a776fa6d15e69a68c330497aedf3422d93 /polymatrix/expression/mixins/derivativeexprmixin.py | |
parent | Delete ParametrizeMatrixExprMixin, update ParametrizeExprMixin to work with a... (diff) | |
download | polymatrix-f094e4d91b44fc1e8b5f11aac2dd8073ba024fc8.tar.gz polymatrix-f094e4d91b44fc1e8b5f11aac2dd8073ba024fc8.zip |
Collapse ExpressionState to a single class
ExpressionState has the usual mixin, whereby one splits the ABC into
smaller parts called mixins, however this class only had one mixin
and it makes no sense to have three classes instead of one. This class
was simply not complex enough to make it worth maintaining all these
files.
I do not see a use case that would extend ExpressionState in a way that
would introduce enough complexity for the mixin structure to be necessary.
But it that were to happen in the future it is easy to reintroduce this
structure I just deleted.
In addition to reducing complexity this also fixes the inconsistent use
of ExpressionStateMixin and ExpressionState across the mixin classes
of Expression.
Diffstat (limited to 'polymatrix/expression/mixins/derivativeexprmixin.py')
-rw-r--r-- | polymatrix/expression/mixins/derivativeexprmixin.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/polymatrix/expression/mixins/derivativeexprmixin.py b/polymatrix/expression/mixins/derivativeexprmixin.py index 31a1e31..dab1b41 100644 --- a/polymatrix/expression/mixins/derivativeexprmixin.py +++ b/polymatrix/expression/mixins/derivativeexprmixin.py @@ -4,7 +4,7 @@ import typing from polymatrix.polymatrix.init import init_poly_matrix from polymatrix.expression.mixins.expressionbasemixin import ExpressionBaseMixin from polymatrix.polymatrix.abc import PolyMatrix -from polymatrix.expressionstate.abc import ExpressionState +from polymatrix.expressionstate import ExpressionState from polymatrix.expression.utils.getderivativemonomials import differentiate_polynomial from polymatrix.expression.utils.getvariableindices import ( get_variable_indices_from_variable, |