Texas Instruments TI89 Developer Guide - Page 866
push_round, Declaration, Categoryies, Description, Inputs, Outputs, Assumptions, Side Effects
UPC - 033317198566
View all Texas Instruments TI89 manuals
Add to My Manuals
Save this manual to your list of manuals |
Page 866 highlights
824 Appendix A: System Routines - Math push_round Declaration: void push_round (EStackIndex val_idx, EStackIndex num_dig_idx) Category(ies): Math Description: Pushes onto the estack the argument rounded to the specified number of digits. Inputs: val_idx - Indexes the input number, list, or matrix. num_dig_idx - Indexes the number of digits after the decimal place to round to or if NULL then uses the default value from the MODE settings. Outputs: None Assumptions: None Side Effects: May expand expression stack, cause heap compression, or throw an error. Availability: On AMS 2.00 and higher. TI-89 / TI-92 Plus Differences: None See Also: None Example: This example creates a static column vector and a static integer then creates a unit vector from the column vector and finally rounds that result to four decimal places. /* static column vector */ static const Quantum colVec[] = {END_TAG, END_TAG,3,1,NONNEGATIVE_INTEGER_TAG,LIST_TAG, END_TAG,2,1,NONNEGATIVE_INTEGER_TAG,LIST_TAG, END_TAG,1,1,NONNEGATIVE_INTEGER_TAG,LIST_TAG, LIST_TAG }; #define colVecIndex ((EStackIndex) (colVec+sizeof(colVec)-1)) static const Quantum Integer4 [] = {4u, 1u, NONNEGATIVE_INTEGER_TAG}; #define Integer4Index ((EStackIndex) (Integer4+2)) push_unitv( colVecIndex ); push_round( top_estack, Integer4Index ); TI-89 / TI-92 Plus Developer Guide Not for Distribution Beta Version January 26, 2001