Appendix A: System Routines — Math
769
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
push_comb
Declaration:
void
push_comb
(EStackIndex
i
, EStackIndex
j
)
Category(ies):
Math
Description:
Let
i
index expression z, and let
j
index expression k. Pushes onto the
estack: 0 for integer k < 0; otherwise z ! / (k !
†
(z - k!)).
For integer k >= 0 this is z
†
(z - 1)* . . . *(z - k + 1) / k!. If z is also integer
and z >= k, this is the number of combinations of z items taken k at a time.
Reference: Graham, Knuth & Patashnik, “Concrete Mathematics”,
section 5.1, Addison-Wesley.
Inputs:
i
,
j
— Indices of the top tags of internally-simplified algebraic
expressions or aggregates thereof.
Outputs:
None
Assumptions:
None
Side Effects:
None
Availability:
On AMS 2.02 and higher.
TI
-
89 / TI
-
92 Plus
Differences:
None
See Also: push_perm, push_factorial
Example:
push_quantum_as_nonnegative_int (4u);
i = top_estack;
push_quantum_as_nonnegative_int (2u);
push_comb (i, top_estack); /* Pushes a tagged integer 6 */