1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146
|
COMMENT:
/* rh.doc SYMMETRICA */
NAME:
is_scalar_reihe
SYNOPSIS:
INT is_scalar_reihe(OP a)
DESCRIPTION:
checks wether a is a object of the kind REIHE with
only constant term.
NAME:
max_degree_reihe
SYNOPSIS:
INT max_degree_reihe(OP a,b)
DESCRIPTION:
you enter a REIHE object a, and the output is the
degree of maximal coefficent, which is computed up to now.
NAME:
m_function_reihe
SYNOPSIS:
INT m_function_reihe(INT (*f)(); OP a);
DESCRIPTION:
you enter a function f, which computes an coefficent
of the series, which is specified by an paramter of the function.
The result is a object a of type REIHE. The syntax of the function
f is described now in detail:
INT f(OP a,b)
a is a INTEGER object which gives the common degree of the
coefficents, which should be computed. The result b must be of
the type POLYNOM object. This POLYNOM object is homogenous of
the entered degree.
EXAMPLE:
the following routine computes the series
sum over all partitions, entered in exponent notation
#include "def.h"
#include "macro.h"
INT co_part(a,b) OP a,b;
{
if (S_I_I(a) == 0L)
m_iindex_iexponent_monom(0L,0L,b);
else
{
OP c = callocobject();
OP d;
INT i;
makevectorofpart(a,c);
init(POLYNOM,b);
for (i=0;i<S_V_LI(c);i++)
{
d = callocobject();
m_s_po(S_PA_S(S_V_I(c,i)),d);
insert(d,b,NULL,NULL);
}
freeall(c);
}
return OK;
}
main()
{
OP a;
anfang();
a = callocobject();
m_function_reihe(co_part,a); println(a);
freeall(a);
ende();
}
NAME:
random_reihe
SYNOPSIS:
INT random_reihe(OP a)
DESCRIPTION:
builds a one-parameter series with random INTEGER
coefficents.
NAME:
scan_reihe
SYNOPSIS:
scan_reihe(OP a)
DESCRIPTION:
this is the function which is called by scan if you
enter the type REIHE. Up to now you can only select between
a fixed number of special series.
NAME:
select_coeff_reihe
SYNOPSIS:
INT select_coeff_reihe(OP a,b,c)
DESCRIPTION:
you enter a REIHE object a, and an VECTOR object b, which must
have INTEGER entries, this integer vector is treated as an
exponent vector,
the output is the coefficent which is the object c. This is a copy
of the coefficent in the series.
NAME:
select_degree_reihe
SYNOPSIS:
INT select_degree_reihe(OP a,b,c)
DESCRIPTION:
you enter a REIHE object a, and an INTEGER object b.
The output are the entries of the series a, which have the given
degree b. In most cases the output is a POLYNOM object c.
NAME:
t_REIHE_POLYNOM
SYNOPSIS:
INT t_REIHE_POLYNOM(OP a,b)
DESCRIPTION:
COMMENT:
standard routines
-----------------
add
add_apply
addinvers
comp lexicographic comparision
fprint
fprintln
freeall
freeself
hoch
length number of computed entries in the series not equal zero
mult
mult_apply
objectread MISSING
objectwrite MISSING
print
println
scan you only can enter fixed series
|