AngouriMath

Navigation

← Back to list of members

PerfectSquare

 Property

Summary

PerfectSquareRules(AngouriMath.Entity), as data.

Remarks

One rule, and it is here to settle a question rather than for its own sake. The
switch arm is x is Sumf or Minusf — an alternation of node types,
which Node``1(AngouriMath.Core.Transformations.Matching.MatchPattern[]) cannot say and which was recorded as needing
an addition to the matcher.
It does not. A typed hole with a predicate says it:
Any<Entity>(name, e => e is Sumf or Minusf) matches either and binds the
whole node, which is exactly what the arm does. The same shape covers every other
construct on that list — var x and not Integer(1) is a predicate,
Rational and not Integer is a predicate on a typed hole, and
not Set and not Matrix is a predicate. So the matcher was never the thing
standing in the way of those sets.

























Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 4378 pages online