Appendix A: System Routines — Algebra Utilities
271
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
push_but_term
Declaration:
void
push_but_term
(EStackIndex
i
, EStackIndex
j
)
Category(ies):
Algebra Utilities
Description:
Pushes onto the estack the sum of the terms of expression
i
without the
leading term of
j
.
If
i
==
j
and ESTACK(
i
) != ADD_TAG, pushes Float0 if
IS_ARITH_APPROX is true and Integer0 if IS_ARITH_APPROX is false.
Use this function to push all but a selected syntactic term out of an
expression.
If
i
indexes x + y + 3 and
j
indexes the partial reductum y + 3, then
push_but_term(i, j)
pushes x + 3.
Functions such as
index_reductum_with_tag_base
can be used to select
such a term.
Inputs:
i
— Index of the top tag of an internally-simplified algebraic expression.
j
—
i
or the index of one of the reductums of the expression indexed
by
i
.
Outputs:
None
Assumptions:
None
Side Effects:
None
Availability:
All versions of the TI
-
89 / TI
-
92 Plus.
TI
-
89 / TI
-
92 Plus
Differences:
None
See Also: lead_term_index, reductum_index
Example:
void push_but_term (EStackIndex i, EStackIndex j)
{ if (i == j)
push_expression (reductum_index (i));
else
{ push_but_term (reductum_index (i), j);
add_to_top (lead_term_index (i));
}
}