The <basfunc.h> Header File

Routines for executing TI-Basic functions

Very few of the functions from this header file are documented as of now. Of course, the ones which are undocumented have not been tested, either. It is very likely that there are errors in this file, so use it with care.

However, we thought it might be a good idea to provide a header file for all of the built-in TI-Basic functions which have a documented entry in the jump table. This way, you can easily search for particular symbolic math functions if you need them. If you use a function from this header file, please document it, too.

Many functions from this header file require their arguments to have some specific format. They usually have to be internally simplified, which can be achieved with the push_internal_simplify function from estack.h, and the result is an internally simplified expression as well. For optional arguments, you can usually pass NULL_INDEX.

If you do not want to accept the AMS dependency of these functions, you can usually construct an expression using their appropriate tags, and then call push_internal_simplify.

Functions

did_push_anti_deriv
Executes TI-Basic 'ò' function.
did_push_series
Executes TI-Basic 'taylor' function.
push_1st_derivative
Executes TI-Basic '' function.
push_abs
Executes TI-Basic 'abs' function.
push_acos
Executes TI-Basic 'cos-1' function.
push_acosh
Executes TI-Basic 'cosh-1' function.
push_approx
Executes TI-Basic 'approx' function.
push_asin
Executes TI-Basic 'sin-1' function.
push_asinh
Executes TI-Basic 'sinh-1' function.
push_atan
Executes TI-Basic 'tan-1' function.
push_atanh
Executes TI-Basic 'tanh-1' function.
push_augment
Executes TI-Basic 'augment' function.
push_ceiling
Executes TI-Basic 'ceiling' function.
push_char
Executes TI-Basic 'char' function.
push_coldim
Executes TI-Basic 'colDim' function.
push_colnorm
Executes TI-Basic 'colNorm' function.
push_comb
Executes TI-Basic 'nCr' function.
push_comdenom
Executes TI-Basic 'comDenom' function.
push_conj
Executes TI-Basic 'conj' function.
push_cos
Executes TI-Basic 'cos' function.
push_cosh
Executes TI-Basic 'cosh' function.
push_cross_product
Executes TI-Basic 'crossP' function.
push_csolve
Executes TI-Basic 'cSolve' function.
push_cumsum
Executes TI-Basic 'cumSum' function.
push_czeros
Executes TI-Basic 'cZeros' function.
push_def_int
Executes TI-Basic 'ò' function.
push_denominator
Executes TI-Basic 'getDenom' function.
push_dense_poly_eval
Executes TI-Basic 'polyEval(' function.
push_desolve
Executes TI-Basic 'deSolve' function.
push_determinant
Executes TI-Basic 'det' function.
push_diag
Executes TI-Basic 'diag' function.
push_dimension
Executes TI-Basic 'dim' function.
push_div_dif_1c
Executes TI-Basic 'nDeriv(' function.
push_div_dif_1f
Executes TI-Basic 'avgRC(' function.
push_dotproduct
Executes TI-Basic 'dotP' function.
push_eigvc
Executes TI-Basic 'eigVc' function.
push_eigvl
Executes TI-Basic 'eigVl' function.
push_exp
Executes TI-Basic 'e^' function.
push_expand
Executes TI-Basic 'expand' function.
push_extended_prod
Executes TI-Basic 'Õ' function.
push_factor
Executes TI-Basic 'factor' function.
push_floor
Executes TI-Basic 'floor' function.
push_fractional_part
Executes TI-Basic 'fPart' function.
push_gcd_numbers
Executes TI-Basic 'gcd' function.
push_getfold
Executes TI-Basic 'getFold' function.
push_getkey
Executes TI-Basic 'getKey' function.
push_getmode
Executes TI-Basic 'getMode' function.
push_gettype
Executes TI-Basic 'getType' function.
push_identity_mat
Executes TI-Basic 'identity' function.
push_im
Executes TI-Basic 'imag' function.
push_instring
Executes TI-Basic 'inString' function.
push_integer_gcd
Executes TI-Basic 'gcd' function.
push_integer_lcm
Executes TI-Basic 'lcm' function.
push_integer_part
Executes TI-Basic 'iPart' function.
push_integer_quotient
Executes TI-Basic 'intDiv' function.
push_integer_remainder
Executes TI-Basic 'remain' function.
push_is_prime
Executes TI-Basic 'isPrime' function.
push_left
Executes TI-Basic 'left' function.
push_lim
Executes TI-Basic 'limit' function.
push_list_to_mat
Executes TI-Basic 'list>mat' function.
push_ln
Executes TI-Basic 'ln' function.
push_log10
Executes TI-Basic 'log' function.
push_mat_to_list
Executes TI-Basic 'mat>list' function.
push_matnorm
Executes TI-Basic 'matNorm' function.
push_max1
Executes TI-Basic 'max' function for a single matrix.
push_max2
Executes TI-Basic 'max' function.
push_max
Executes TI-Basic 'fMax' function.
push_mean
Executes TI-Basic 'mean' function.
push_median
Executes TI-Basic 'median' function.
push_mid
Executes TI-Basic 'mid' function.
push_min1
Executes TI-Basic 'min' function for a single matrix.
push_min2
Executes TI-Basic 'min' function.
push_min
Executes TI-Basic 'fMin' function.
push_mod
Executes TI-Basic 'mod' function.
push_mrow
Executes TI-Basic 'mRow' function.
push_mrowadd
Executes TI-Basic 'mRowAdd' function.
push_newlist
Executes TI-Basic 'newList' function.
push_newmat
Executes TI-Basic 'newMat' function.
push_nint
Executes TI-Basic 'nInt' function.
push_nsolve
Executes TI-Basic 'nSolve' function.
push_nth_derivative
Executes TI-Basic '' function.
push_numerator
Executes TI-Basic 'getNum' function.
push_ord
Executes TI-Basic 'ord' function.
push_part
Executes TI-Basic 'part' function.
push_perm
Executes TI-Basic 'nPr' function.
push_phase
Executes TI-Basic 'R>Pq' function for a complex number (?).
push_prodlist
Executes TI-Basic 'product' function.
push_pttest
Executes TI-Basic 'ptTest' function.
push_pxltest
Executes TI-Basic 'pxlTest' function.
push_r_cis
Executes TI-Basic 'R>Pq' function (?).
push_rand
Executes TI-Basic 'rand' function.
push_randmat
Executes TI-Basic 'randMat' function.
push_randnorm
Executes TI-Basic 'randNorm' function.
push_randpoly
Executes TI-Basic 'randPoly' function.
push_re
Executes TI-Basic 'real' function.
push_rec_to_angle
Executes TI-Basic 'R>Pq' function.
push_red_row_ech
Executes TI-Basic 'rref' function.
push_right
Executes TI-Basic 'right' function.
push_rotate
Executes TI-Basic 'rotate' function.
push_round
Executes TI-Basic 'round' function.
push_row_echelon
Executes TI-Basic 'ref' function.
push_rowadd
Executes TI-Basic 'rowAdd' function.
push_rowdim
Executes TI-Basic 'rowDim' function.
push_rownorm
Executes TI-Basic 'rowNorm' function.
push_rowswap
Executes TI-Basic 'rowSwap' function.
push_sequence
Executes TI-Basic 'seq' function.
push_setfold
Executes TI-Basic 'setFold' function.
push_setgraph
Executes TI-Basic 'setGraph' function.
push_setmode
Executes TI-Basic 'setMode' function.
push_settable
Executes TI-Basic 'setTable' function.
push_shift
Executes TI-Basic 'shift' function.
push_sign
Executes TI-Basic 'sign' function.
push_simult
Executes TI-Basic 'simult' function.
push_sin2
Executes TI-Basic 'sin' and 'cos' functions.
push_sin
Executes TI-Basic 'sin' function.
push_sinh
Executes TI-Basic 'sinh' function.
push_solve
Executes TI-Basic 'solve' function.
push_sqrt
Executes TI-Basic 'Ö' function.
push_stddev
Executes TI-Basic 'stdDev' function.
push_str_to_expr
Executes TI-Basic 'expr' function.
push_string
Executes TI-Basic 'string' function.
push_submat
Executes TI-Basic 'subMat' function.
push_sumlist
Executes TI-Basic 'sum' function.
push_summation
Executes TI-Basic 'S' function.
push_switch
Executes TI-Basic 'switch' function.
push_tan
Executes TI-Basic 'tan' function.
push_tanh
Executes TI-Basic 'tanh' function.
push_unitv
Executes TI-Basic 'unitV' function.
push_variance
Executes TI-Basic 'variance' function.
push_when
Executes TI-Basic 'when' function.
push_zeros
Executes TI-Basic 'zeros' function.

Constants

NULL_INDEX
Describes an empty expression stack index.

Predefined Types

CESI
Represents a pointer to a constant expression.
ESI
Represents an index of a value on the TIOS expression stack.
ESQ
Represents a quantum within an expression.
EStackIndex
Represents an index of a value on the TIOS expression stack.
Quantum
Represents a quantum within an expression.
SYM_STR
Represents a pointer to the terminating zero byte of a string.

Note: All functions from this header file get parameters from the expression stack, so this header file must be used in conjunction with estack.h. You need to learn about the usage of the expression stack before using any function from this header file. All functions defined here execute particular TI-Basic functions. They sometimes may be useful to perform some operations which can not be implemented in C easily. But note that if you use functions from this header file too much, this will decrease the performance of your program significantly. In an extreme case, it will in fact decrease to that of a TI-Basic program! So use functions from this header file only if it is really necessary. Also note that these functions act exactly like the appropriate TI-Basic commands (including throwing errors if something is wrong), so the use of an error tracking mechanism from the error.h header file is highly recommended.

See also: bascmd.h, basop.h


did_push_anti_deriv

AMS 2.02 or higher

short did_push_anti_deriv(CESI expr, CESI var, short closed_form_only_flag);

Executes TI-Basic 'ò' function.

did_push_anti_deriv integrates 'expr' with respect to variable 'var'. If the closed-form-only flag is TRUE, it pushes a result to the estack only if it can find a closed form integral. It returns TRUE if it pushed a result to the estack, FALSE otherwise.


did_push_series

AMS 2.02 or higher

short did_push_series(CESI expr, CESI var, CESI exporder, CESI exppt, short push_only_first_nonzero_term_flag);

Executes TI-Basic 'taylor' function.

did_push_series does a Taylor series expansion of 'expr' with respect to variable 'var' about the point 'exppt' to order 'exporder'. If push_only_first_nonzero_term_flag is TRUE, it pushes only the first nonzero term. It returns TRUE if it pushed a result (not containing a SERIES_TAG) to the estack, FALSE otherwise.


push_1st_derivative

AMS 2.02 or higher

void push_1st_derivative (CESI, CESI);

Executes TI-Basic '' function.


push_abs

AMS 2.02 or higher

void push_abs (CESI);

Executes TI-Basic 'abs' function.


push_acos

AMS 2.02 or higher

void push_acos (CESI);

Executes TI-Basic 'cos-1' function.


push_acosh

AMS 2.02 or higher

void push_acosh (CESI);

Executes TI-Basic 'cosh-1' function.


push_approx

AMS 2.00 or higher

void push_approx (CESI);

Executes TI-Basic 'approx' function.


push_asin

AMS 2.02 or higher

void push_asin (CESI);

Executes TI-Basic 'sin-1' function.


push_asinh

AMS 2.02 or higher

void push_asinh (CESI);

Executes TI-Basic 'sinh-1' function.


push_atan

AMS 2.02 or higher

void push_atan (CESI);

Executes TI-Basic 'tan-1' function.


push_atanh

AMS 2.02 or higher

void push_atanh (CESI);

Executes TI-Basic 'tanh-1' function.


push_augment

AMS 2.00 or higher

void push_augment (CESI, CESI);

Executes TI-Basic 'augment' function.


push_ceiling

AMS 2.02 or higher

void push_ceiling (CESI);

Executes TI-Basic 'ceiling' function.


push_char

AMS 2.00 or higher

void push_char (CESI);

Executes TI-Basic 'char' function.


push_coldim

AMS 2.00 or higher

void push_coldim (CESI);

Executes TI-Basic 'colDim' function.


push_colnorm

AMS 2.00 or higher

void push_colnorm (CESI);

Executes TI-Basic 'colNorm' function.


push_comb

AMS 2.02 or higher

void push_comb (CESI, CESI);

Executes TI-Basic 'nCr' function.


push_comdenom

AMS 2.02 or higher

void push_comdenom (CESI, CESI);

Executes TI-Basic 'comDenom' function.


push_conj

AMS 2.02 or higher

void push_conj (CESI);

Executes TI-Basic 'conj' function.


push_cos

AMS 2.02 or higher

void push_cos (CESI);

Executes TI-Basic 'cos' function.


push_cosh

AMS 2.02 or higher

void push_cosh (CESI);

Executes TI-Basic 'cosh' function.


push_cross_product

AMS 2.00 or higher

void push_cross_product (CESI, CESI);

Executes TI-Basic 'crossP' function.


push_csolve

AMS 2.02 or higher

void push_csolve (CESI, CESI);

Executes TI-Basic 'cSolve' function.

Please see push_czeros entry for an important note for all solver ROM calls.


push_cumsum

AMS 2.00 or higher

void push_cumsum (CESI);

Executes TI-Basic 'cumSum' function.


push_czeros

AMS 2.02 or higher

void push_czeros (CESI, CESI);

Executes TI-Basic 'cZeros' function.

Important note for all solver ROM calls:

When czeros( ) is executed on the command line, the OS provides special treatment for the specified "variable of interest". Part of the "special treatment" is temporarily to promote the "variable of interest" to the top of the ordering. Directly calling push_czeros( ) bypasses this special treatment. This affects solver ROM calls such as push_zeros, push_solve, push_czeros, push_csolve, push_min, push_max, and push_desolve.

For example, the following code for attempting to find an inverse of sqrt(x/(1-x)) gives no solutions:

 push_quantum(X_VAR_TAG);
 var = top_estack;
 push_difference(Integer1Index,var);
 expr = top_estack;
 push_quantum(X_VAR_TAG);
 divide_top(expr);
 push_sqrt(top_estack);	//sqrt(x/(1-x))
 push_zstr("solveaux"); top_estack--;
 solvevar = top_estack;	//Auxiliary solve variable
 push_substitute_simplify(expr,var,solvevar);
 push_difference(top_estack,var);    //(expr|x=solveaux)-x
 push_czeros(top_estack,solvevar);

The simplest and most reliable way around this is to do:

 push_expression(var);
 push_expression(expr);
 push_quantum(CZEROS_TAG);
 push_simplify(top_estack);

The above information was obtained from TI.


push_def_int

AMS 2.02 or higher

void push_def_int (CESI, CESI, CESI, CESI);

Executes TI-Basic 'ò' function.


push_denominator

AMS 2.02 or higher

void push_denominator (CESI);

Executes TI-Basic 'getDenom' function.


push_dense_poly_eval

AMS 2.00 or higher

void push_dense_poly_eval (ESI coeflist, ESI expr);

Executes TI-Basic 'polyEval(' function.

The list 'coeflist' represents the coefficients of a polynomial in descending order. push_dense_poly_eval pushes the polynomial evaluated at 'expr'. 'expr' need not be a number, or even a variable.


push_desolve

AMS 2.02 or higher

void push_desolve (CESI);

Executes TI-Basic 'deSolve' function.

Please see push_czeros entry for an important note for all solver ROM calls.


push_determinant

AMS 2.00 or higher

void push_determinant (CESI, CESI);

Executes TI-Basic 'det' function.


push_diag

AMS 2.00 or higher

void push_diag (CESI);

Executes TI-Basic 'diag' function.


push_dimension

AMS 2.00 or higher

void push_dimension (CESI);

Executes TI-Basic 'dim' function.


push_div_dif_1c

AMS 2.02 or higher

void push_div_dif_1c (ESI expr, ESI var, ESI h);

Executes TI-Basic 'nDeriv(' function.

push_div_dif_1c pushes to the estack the 1st-order centered or symmetric difference of 'expr' with respect to variable 'var' with stepsize 'h'. You can obtain higher-order differences by repeated application, just as you can with derivatives.

See also: push_div_dif_1f


push_div_dif_1f

AMS 2.02 or higher

void push_div_dif_1f (ESI expr, ESI var, ESI h);

Executes TI-Basic 'avgRC(' function.

push_div_dif_1f pushes to the estack the 1st-order forward difference of 'expr' with respect to variable 'var' with stepsize 'h'. You can obtain higher-order differences by repeated application, just as you can with derivatives.

See also: push_div_dif_1c


push_dotproduct

AMS 2.00 or higher

void push_dotproduct (CESI, CESI);

Executes TI-Basic 'dotP' function.


push_eigvc

AMS 2.00 or higher

void push_eigvc (CESI);

Executes TI-Basic 'eigVc' function.


push_eigvl

AMS 2.00 or higher

void push_eigvl (CESI);

Executes TI-Basic 'eigVl' function.


push_exp

AMS 2.02 or higher

void push_exp (CESI);

Executes TI-Basic 'e^' function.


push_expand

AMS 2.02 or higher

void push_expand (CESI, CESI, short);

Executes TI-Basic 'expand' function.


push_extended_prod

AMS 2.02 or higher

void push_extended_prod (CESI, CESI, CESI, CESI);

Executes TI-Basic 'Õ' function.


push_factor

AMS 2.02 or higher

void push_factor (CESI, CESI, short);

Executes TI-Basic 'factor' function.


push_floor

AMS 2.02 or higher

void push_floor (CESI);

Executes TI-Basic 'floor' function.


push_fractional_part

AMS 2.02 or higher

void push_fractional_part (CESI);

Executes TI-Basic 'fPart' function.


push_gcd_numbers

AMS 2.02 or higher

void push_gcd_numbers (CESI, CESI);

Executes TI-Basic 'gcd' function.


push_getfold

AMS 1.01 or higher

void push_getfold (void);

Executes TI-Basic 'getFold' function.


push_getkey

AMS 1.01 or higher

void push_getkey (void);

Executes TI-Basic 'getKey' function.

push_getkey pushes tke key code of a pressed key to the expression stack. It pushes 0 if no key is pressed. The pushed value is exactly the same as a value returned from the TI-Basic getKey function (it is mainly the same value as returned from ngetchx, but not always: for example, codes for arrow keys are different).


push_getmode

AMS 1.01 or higher

void push_getmode (CESI ModeNameString);

Executes TI-Basic 'getMode' function.

push_getmode assumes that ModeNameString points to the tag of a string expression (usually STR_TAG). If it points to a specific mode name string, it pushes a new string containing the current setting for that mode to the expressions stack. See push_setmode for a list of legal mode name strings.

If the mode name string is "ALL", push_getmode pushes a list of string pairs containing the settings of all the modes to the expression stack. So, you can restore all mode settings later at once using push_setmode.


push_gettype

AMS 1.01 or higher

void push_gettype (CESI);

Executes TI-Basic 'getType' function.


push_identity_mat

AMS 2.00 or higher

void push_identity_mat (CESI);

Executes TI-Basic 'identity' function.


push_im

AMS 2.02 or higher

void push_im (CESI);

Executes TI-Basic 'imag' function.


push_instring

AMS 1.01 or higher

void push_instring (CESI, CESI, CESI);

Executes TI-Basic 'inString' function.


push_integer_gcd

AMS 2.02 or higher

void push_integer_gcd (CESI, CESI);

Executes TI-Basic 'gcd' function.


push_integer_lcm

AMS 2.02 or higher

void push_integer_lcm (CESI, CESI);

Executes TI-Basic 'lcm' function.


push_integer_part

AMS 2.02 or higher

void push_integer_part (CESI);

Executes TI-Basic 'iPart' function.


push_integer_quotient

AMS 2.02 or higher

void push_integer_quotient (CESI, CESI);

Executes TI-Basic 'intDiv' function.


push_integer_remainder

AMS 2.02 or higher

void push_integer_remainder (CESI, CESI);

Executes TI-Basic 'remain' function.


push_is_prime

AMS 2.02 or higher

void push_is_prime (CESI);

Executes TI-Basic 'isPrime' function.


push_left

AMS 2.00 or higher

void push_left (CESI, CESI);

Executes TI-Basic 'left' function.


push_lim

AMS 2.02 or higher

void push_lim (CESI, CESI, CESI, CESI);

Executes TI-Basic 'limit' function.


push_list_to_mat

AMS 2.00 or higher

void push_list_to_mat (CESI, CESI);

Executes TI-Basic 'list>mat' function.


push_ln

AMS 2.02 or higher

void push_ln (CESI);

Executes TI-Basic 'ln' function.


push_log10

AMS 2.02 or higher

void push_log10 (CESI);

Executes TI-Basic 'log' function.


push_mat_to_list

AMS 2.00 or higher

void push_mat_to_list (CESI);

Executes TI-Basic 'mat>list' function.


push_matnorm

AMS 2.00 or higher

void push_matnorm (CESI);

Executes TI-Basic 'matNorm' function.


push_max1

AMS 2.02 or higher

void push_max1 (CESI);

Executes TI-Basic 'max' function for a single matrix.


push_max2

AMS 2.02 or higher

void push_max2 (CESI, CESI);

Executes TI-Basic 'max' function.


push_max

AMS 2.02 or higher

void push_max (CESI, CESI);

Executes TI-Basic 'fMax' function.

Please see push_czeros entry for an important note for all solver ROM calls.


push_mean

AMS 2.00 or higher

void push_mean (CESI);

Executes TI-Basic 'mean' function.


push_median

AMS 2.00 or higher

void push_median (CESI);

Executes TI-Basic 'median' function.


push_mid

AMS 2.00 or higher

void push_mid (CESI, CESI, CESI);

Executes TI-Basic 'mid' function.


push_min1

AMS 2.02 or higher

void push_min1 (CESI);

Executes TI-Basic 'min' function for a single matrix.


push_min2

AMS 2.02 or higher

void push_min2 (CESI, CESI);

Executes TI-Basic 'min' function.


push_min

AMS 2.02 or higher

void push_min (CESI, CESI);

Executes TI-Basic 'fMin' function.

Please see push_czeros entry for an important note for all solver ROM calls.


push_mod

AMS 2.02 or higher

void push_mod (CESI, CESI);

Executes TI-Basic 'mod' function.


push_mrow

AMS 2.00 or higher

void push_mrow (CESI, CESI, CESI);

Executes TI-Basic 'mRow' function.


push_mrowadd

AMS 2.00 or higher

void push_mrowadd (CESI, CESI, CESI, CESI);

Executes TI-Basic 'mRowAdd' function.


push_newlist

AMS 2.00 or higher

void push_newlist (CESI);

Executes TI-Basic 'newList' function.


push_newmat

AMS 2.00 or higher

void push_newmat (CESI, CESI);

Executes TI-Basic 'newMat' function.


push_nint

AMS 2.02 or higher

void push_nint (CESI, CESI, CESI, CESI);

Executes TI-Basic 'nInt' function.


push_nsolve

AMS 2.02 or higher

void push_nsolve (CESI, CESI);

Executes TI-Basic 'nSolve' function.


push_nth_derivative

AMS 2.02 or higher

void push_nth_derivative (CESI, CESI, CESI);

Executes TI-Basic '' function.


push_numerator

AMS 2.02 or higher

void push_numerator (CESI);

Executes TI-Basic 'getNum' function.


push_ord

AMS 2.00 or higher

void push_ord (CESI);

Executes TI-Basic 'ord' function.


push_part

AMS 1.01 or higher

void push_part ();

Executes TI-Basic 'part' function.


push_perm

AMS 2.02 or higher

void push_perm (CESI, CESI);

Executes TI-Basic 'nPr' function.


push_phase

AMS 2.02 or higher

void push_phase (CESI);

Executes TI-Basic 'R>Pq' function for a complex number (?).


push_prodlist

AMS 2.00 or higher

void push_prodlist (CESI);

Executes TI-Basic 'product' function.


push_pttest

AMS 1.01 or higher

void push_pttest (CESI, CESI);

Executes TI-Basic 'ptTest' function.


push_pxltest

AMS 1.01 or higher

void push_pxltest (CESI, CESI);

Executes TI-Basic 'pxlTest' function.


push_r_cis

AMS 2.02 or higher

void push_r_cis (CESI, CESI);

Executes TI-Basic 'R>Pq' function (?).


push_rand

AMS 1.01 or higher

void push_rand (CESI Range);

Executes TI-Basic 'rand' function.

push_rand pushes a random number on the expression stack. Range should point either to END_TAG, or to an integer expression. If Range points to END_TAG, push_rand pushes a floating point number between 0 and 1. If Range points to an integer value n, push_rand pushes an integer number between 1 and n if n is positive, or between -n and -1 if n is negative.

Note: This function calls the TI-Basic random number generator, so it has nothing to do with the random number generator from stdlib.h (i.e. with the functions rand, random, randomize, and srand). You can use the function cmd_randseed (instead of srand) to set the seed for the TI-Basic random number generator. Note also that push_rand is much slower than the random number generator implemented in stdlib.h.

See also: cmd_randseed, rand, random


push_randmat

AMS 2.00 or higher

void push_randmat (CESI, CESI);

Executes TI-Basic 'randMat' function.


push_randnorm

AMS 2.00 or higher

void push_randnorm (CESI, CESI);

Executes TI-Basic 'randNorm' function.


push_randpoly

AMS 1.01 or higher

void push_randpoly (CESI, CESI);

Executes TI-Basic 'randPoly' function.


push_re

AMS 2.02 or higher

void push_re (CESI);

Executes TI-Basic 'real' function.


push_rec_to_angle

AMS 2.02 or higher

void push_rec_to_angle (CESI, CESI);

Executes TI-Basic 'R>Pq' function.


push_red_row_ech

AMS 2.00 or higher

void push_red_row_ech (CESI, CESI);

Executes TI-Basic 'rref' function.


push_right

AMS 2.00 or higher

void push_right (CESI, CESI);

Executes TI-Basic 'right' function.


push_rotate

AMS 2.00 or higher

void push_rotate (CESI, CESI);

Executes TI-Basic 'rotate' function.


push_round

AMS 2.00 or higher

void push_round (CESI, CESI);

Executes TI-Basic 'round' function.


push_row_echelon

AMS 2.00 or higher

void push_row_echelon (CESI, CESI);

Executes TI-Basic 'ref' function.


push_rowadd

AMS 2.00 or higher

void push_rowadd (CESI, CESI, CESI);

Executes TI-Basic 'rowAdd' function.


push_rowdim

AMS 2.00 or higher

void push_rowdim (CESI);

Executes TI-Basic 'rowDim' function.


push_rownorm

AMS 2.00 or higher

void push_rownorm (CESI);

Executes TI-Basic 'rowNorm' function.


push_rowswap

AMS 2.00 or higher

void push_rowswap (CESI, CESI, CESI);

Executes TI-Basic 'rowSwap' function.


push_sequence

AMS 2.00 or higher

void push_sequence (CESI, CESI, CESI, CESI, CESI);

Executes TI-Basic 'seq' function.


push_setfold

AMS 1.01 or higher

void push_setfold (CESI);

Executes TI-Basic 'setFold' function.


push_setgraph

AMS 1.01 or higher

void push_setgraph (CESI ModeNameString, CESI SettingString);

Executes TI-Basic 'setGraph' function.

push_setgraph assumes that ModeNameString points to the tag of a string expression (usually STR_TAG). It sets the appropriate Graph mode to the new string pointed to by SettingString (it should also point to the string tag), and pushes the previous setting string of that mode to the expression stack. Possible mode strings and settings strings are listed in the table below:

Mode namePossible settings
"Coordinates""RECT", "POLAR", "OFF"
"Graph Order""SEQ", "SIMUL" (not available in SEQUENCE, 3D or DIFF EQUATIONS graph mode)
"Grid""OFF", "ON" (not available in 3D graph mode)
"Axes""OFF", "ON" (not 3D graph mode)
"OFF", "AXES", "BOX" (3D graph mode)
"Leading Cursor""OFF", "ON" (not available in 3D graph mode)
"Labels""OFF", "ON"
"Style""WIRE FRAME", "HIDDEN SURFACE", "CONTOUR LEVELS", "WIRE AND CONTOUR", "IMPLICIT PLOT" (applies only to 3D graph mode)
"Seq Axes""TIME", "WEB", "U1-VS-U2" (applies only to SEQUENCE graph mode)
"DE Axes""TIME", "T-VS-Y'", "Y-VS-Y'", "Y1-VS-Y2", "Y1-VS-Y2'", "Y1'-VS-Y2'" (applies only to DIFF EQUATIONS graph mode)
"Solution Method""RK", "EULER" (applies only to DIFF EQUATIONS graph mode)
"Fields""SLPFLD", "DIRFLD", "FLDOFF" (applies only to DIFF EQUATIONS graph mode)


push_setmode

AMS 1.01 or higher

void push_setmode (CESI ModeNameStringOrList, CESI SettingString);

Executes TI-Basic 'setMode' function.

push_setmode assumes that ModeNameStringOrList points to the tag of a string expression (usually to STR_TAG), or to a list expression (usually to LIST_TAG). If it points to a string, push_setmode sets the appropriate mode to the new string pointed to by SettingString (it should also point to the string tag), and pushes the previous setting string of that mode to the expression stack. Possible mode strings and settings strings are listed in the table below:

Mode namePossible settings
"Graph""FUNCTION", "PARAMETRIC", "POLAR", "SEQUENCE", "3D", "DIFF EQUATIONS"
"Display Digits""FIX 0", "FIX 1", ..., "FIX 12", "FLOAT 1", "FLOAT 2", ..., "FLOAT 12"
"Angle""RADIAN", "DEGREE"
"Exponential Format""NORMAL", "SCIENTIFIC", "ENGINEERING"
"Complex Format""REAL", "RECTANGULAR", "POLAR"
"Vector Format""RECTANGULAR", "CYLINDRICAL", "SPHERICAL"
"Pretty Print""OFF", "ON"
"Split Screen""FULL", "TOP-BOTTOM", "LEFT-RIGHT"
"Split 1 App""Home", "Y=Editor", "Window Editor", "Graph", "Table", "Data/Matrix Editor", "Program Editor", "Text Editor", "Numeric Solver"
"Split 2 App""Home", "Y=Editor", "Window Editor", "Graph", "Table", "Data/Matrix Editor", "Program Editor", "Text Editor", "Numeric Solver"
"Number of Graphs""1", "2"
"Graph2""FUNCTION", "PARAMETRIC", "POLAR", "SEQUENCE", "3D", "DIFF EQUATIONS"
"Exact/Approx""AUTO", "EXACT", "APPROXIMATE"
"Base""DEC", "HEX", "BIN"

If ModeNameStringOrList points to a list, this list is assumed to contain pairs of keyword strings. push_setmode will then set them all at once (SettingString is ignored in this case). This is recommended for multiple mode changes.

Note: push_setmode may cause switching of the current application. See the events.h header file for more info.


push_settable

AMS 1.01 or higher

void push_settable (CESI ModeNameString, CESI SettingString);

Executes TI-Basic 'setTable' function.

push_settable assumes that ModeNameString points to the tag of a string expression (usually STR_TAG). It sets the appropriate table parameter to the new string pointed to by SettingString (it should also point to the string tag), and pushes the previous setting string of that parameter to the expression stack. Possible parameter name strings and settings strings are listed in the table below:

Parameter namePossible settings
"Graph <-> Table""OFF", "ON"
"Independent""AUTO", "ASK"


push_shift

AMS 2.00 or higher

void push_shift (CESI, CESI);

Executes TI-Basic 'shift' function.


push_sign

AMS 2.02 or higher

void push_sign (CESI);

Executes TI-Basic 'sign' function.


push_simult

AMS 2.00 or higher

void push_simult (CESI, CESI, CESI);

Executes TI-Basic 'simult' function.


push_sin2

AMS 2.02 or higher

void push_sin2 (CESI, CESI);

Executes TI-Basic 'sin' and 'cos' functions.


push_sin

AMS 2.02 or higher

void push_sin (CESI);

Executes TI-Basic 'sin' function.


push_sinh

AMS 2.02 or higher

void push_sinh (CESI);

Executes TI-Basic 'sinh' function.


push_solve

AMS 2.02 or higher

void push_solve (CESI, CESI);

Executes TI-Basic 'solve' function.

Please see push_czeros entry for an important note for all solver ROM calls.


push_sqrt

AMS 2.02 or higher

void push_sqrt (CESI);

Executes TI-Basic 'Ö' function.


push_stddev

AMS 2.00 or higher

void push_stddev (CESI);

Executes TI-Basic 'stdDev' function.


push_str_to_expr

AMS 1.01 or higher

void push_str_to_expr (CESI);

Executes TI-Basic 'expr' function.

See also: push_string, push_parse_text


push_string

AMS 1.01 or higher

void push_string (CESI expr);

Executes TI-Basic 'string' function.

push_string converts the expression pointed to by expr to a string and pushes this string on the expression stack. For example, after executing the code

push_shortint (100);
push_quantum_pair (VAR_X_TAG, ADD_TAG);
push_string (top_estack);

the string "x+100" will be pushed on the expression stack. See top_estack and Tags for more info about this example.

Of course, expr may point to a string containing a variable name, but it must not point to an ordinary string. Otherwise the string is truncated at the first space (but not after the 8th character). If you only want to push a string (not an expression converted to a string), a method which always works would be:

push_expr_quantum (expr, STR_TAG);

See also: push_str_to_expr, push_zstr, display_statements


push_submat

AMS 2.00 or higher

void push_submat (CESI, CESI, CESI, CESI, CESI);

Executes TI-Basic 'subMat' function.


push_sumlist

AMS 2.00 or higher

void push_sumlist (CESI);

Executes TI-Basic 'sum' function.


push_summation

AMS 2.02 or higher

void push_summation (CESI, CESI, CESI, CESI);

Executes TI-Basic 'S' function.


push_switch

AMS 1.01 or higher

void push_switch (CESI WinNum);

Executes TI-Basic 'switch' function.

push_switch expects that WinNum points to an integer expression. If this integer is 0, push_switch pushes the active window number (1 for left or top window, 2 for right or bottom window) to the expression stack. If this integer is 1 or 2, push_switch activates window 1 or 2 and pushes the previously active window number to the expressions stack. If WinNum points to END_TAG, push_switch switches windows and pushes the previously active window number to the expression stack. Of course, window switching is ignored if the calculator is not displaying a split screen.


push_tan

AMS 2.02 or higher

void push_tan (CESI);

Executes TI-Basic 'tan' function.


push_tanh

AMS 2.02 or higher

void push_tanh (CESI);

Executes TI-Basic 'tanh' function.


push_unitv

AMS 2.00 or higher

void push_unitv (CESI);

Executes TI-Basic 'unitV' function.


push_variance

AMS 2.00 or higher

void push_variance (CESI);

Executes TI-Basic 'variance' function.


push_when

AMS 2.02 or higher

void push_when (CESI);

Executes TI-Basic 'when' function.


push_zeros

AMS 2.02 or higher

void push_zeros (CESI, CESI);

Executes TI-Basic 'zeros' function.

Please see push_czeros entry for an important note for all solver ROM calls.


Return to the main index