ReactionExpression#
- class montepy.data_inputs.tally_multiplier.ReactionExpression(left: ReactionExpression, operator: ReactionOperator, right: ReactionExpression)#
Bases:
objectA binary expression tree for one FM reaction list.
Modeled on
montepy.surfaces.half_space.HalfSpace(left/operator/right,&/|/~there →*/+/-here). Python’s own operator precedence (*binds tighter than+/-) gives MCNP’s “multiply first” reaction-list rule for free:Reaction(16) * Reaction(103) + Reaction(104)builds(16*103) + 104with no custom precedence-climbing code.Added in version 1.6.0b2.
Attributes:
The left side of this expression.
The syntax node for this reaction expression.
The
ReactionOperatorjoining the two sides.The right side of this expression.
- Parameters:
left (ReactionExpression)
operator (ReactionOperator)
right (ReactionExpression)
- property left#
The left side of this expression.
- property operator#
The
ReactionOperatorjoining the two sides.
- property right#
The right side of this expression.