FORM
4.2.1
|
#include "form3.h"
Go to the source code of this file.
Macros | |
#define | STEP2 |
Functions | |
int | CatchDollar (int par) |
int | AssignDollar (PHEAD WORD *term, WORD level) |
UBYTE * | WriteDollarToBuffer (WORD numdollar, WORD par) |
UBYTE * | WriteDollarFactorToBuffer (WORD numdollar, WORD numfac, WORD par) |
void | AddToDollarBuffer (UBYTE *s) |
void | TermAssign (WORD *term) |
int | PutTermInDollar (WORD *term, WORD numdollar) |
void | WildDollars (PHEAD WORD *term) |
WORD | DolToTensor (PHEAD WORD numdollar) |
WORD | DolToFunction (PHEAD WORD numdollar) |
WORD | DolToVector (PHEAD WORD numdollar) |
WORD | DolToNumber (PHEAD WORD numdollar) |
WORD | DolToSymbol (PHEAD WORD numdollar) |
WORD | DolToIndex (PHEAD WORD numdollar) |
DOLLARS | DolToTerms (PHEAD WORD numdollar) |
LONG | DolToLong (PHEAD WORD numdollar) |
int | ExecInside (UBYTE *s) |
int | InsideDollar (PHEAD WORD *ll, WORD level) |
void | ExchangeDollars (int num1, int num2) |
LONG | TermsInDollar (WORD num) |
LONG | SizeOfDollar (WORD num) |
UBYTE * | PreIfDollarEval (UBYTE *s, int *value) |
WORD * | TranslateExpression (UBYTE *s) |
int | IsSetMember (WORD *buffer, WORD numset) |
int | IsMultipleOf (WORD *buf1, WORD *buf2) |
int | TwoExprCompare (WORD *buf1, WORD *buf2, int oprtr) |
int | DollarRaiseLow (UBYTE *name, LONG value) |
WORD | EvalDoLoopArg (PHEAD WORD *arg, WORD par) |
WORD | TestDoLoop (PHEAD WORD *lhsbuf, WORD level) |
WORD | TestEndDoLoop (PHEAD WORD *lhsbuf, WORD level) |
int | DollarFactorize (PHEAD WORD numdollar) |
void | CleanDollarFactors (DOLLARS d) |
WORD * | TakeDollarContent (PHEAD WORD *dollarbuffer, WORD **factor) |
WORD * | MakeDollarInteger (PHEAD WORD *bufin, WORD **bufout) |
WORD * | MakeDollarMod (PHEAD WORD *buffer, WORD **bufout) |
int | GetDolNum (PHEAD WORD *t, WORD *tstop) |
void | AddPotModdollar (WORD numdollar) |
The routines that deal with the dollar variables. The name administration is to be found in the file names.c
Definition in file dollar.c.
#define STEP2 |
Factors a dollar expression. Notation: d->nfactors becomes nonzero. if the number of factors is one, we leave d->factors zero. Otherwise factors is an array of pointers to the factors. These are pointers of the type FACDOLLAR. fd->where pointer to contents in term notation fd->size size of the buffer fd->where points to fd->type DOLNUMBER or DOLTERMS fd->value value if type is DOLNUMBER and it fits in a WORD.
WORD EvalDoLoopArg | ( | PHEAD WORD * | arg, |
WORD | par | ||
) |
Evaluates one argument of a do loop. Such an argument is constructed from SNUMBERs DOLLAREXPRESSIONs and possibly DOLLAREXPR2s which indicate factors of the preceeding dollar. Hence we have SNUMBER,num DOLLAREXPRESSION,numdollar DOLLAREXPRESSION,numdollar,DOLLAREXPR2,numfactor DOLLAREXPRESSION,numdollar,DOLLAREXPR2,numfactor,DOLLAREXPR2,numfactor etc. Because we have a do-loop at every stage we should have a number. The notation in DOLLAREXPR2 is that >= 0 is number of yet another dollar and < 0 is -n-1 with n the array element or zero. The return value is the (short) number. The routine works its way through the list in a recursive manner.
Definition at line 2646 of file dollar.c.
References EvalDoLoopArg().
Referenced by EvalDoLoopArg().
WORD* MakeDollarInteger | ( | PHEAD WORD * | bufin, |
WORD ** | bufout | ||
) |
For normalizing everything to integers we have to determine for all elements of this argument the LCM of the denominators and the GCD of the numerators. The input argument is in bufin. The number that comes out is the return value. The normalized argument is in bufout.
Definition at line 3622 of file dollar.c.
References EndSort(), Generator(), and NewSort().
WORD* MakeDollarMod | ( | PHEAD WORD * | buffer, |
WORD ** | bufout | ||
) |
Similar to MakeDollarInteger but now with modulus arithmetic using only a one WORD 'prime'. We make the coefficient of the first term in the argument equal to one. Already the coefficients are taken modulus AN.cmod and AN.ncmod == 1
Definition at line 3796 of file dollar.c.
References EndSort(), Generator(), GetModInverses(), and NewSort().