Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

Ratweight Calculator

Ratweight

Function: ratweight (<x_1>, <w_1>, ..., <x_n>, <w_n>)

ratweight (a, 1, b, 1);
 expr1: rat(a + b + 1);
 expr1^2;
 ratwtlvl: 1;
 expr1^2;

Function: ratweight () Assigns a weight <w_i> to the variable <x_i>. This causes a term to be replaced by 0 if its weight exceeds the value of the variable ratwtlvl (default yields no truncation). The weight of a term is the sum of the products of the weight of a variable in the term times its power. For example, the weight of 3 x_1^2 x_2 is 2 w_1 + w_2. Truncation according to ratwtlvl is carried out only when multiplying or exponentiating canonical rational expressions (CRE).

ratweight () returns the cumulative list of weight assignments.

Note: The ratfac and ratweight schemes are incompatible and may not both be used at the same time.

Examples:

          (%i1) ratweight (a, 1, b, 1);
          (%o1)                     [a, 1, b, 1]
          (%i2) expr1: rat(a + b + 1)$
          (%i3) expr1^2;
                            2                  2
          (%o3)/R/         b  + (2 a + 2) b + a  + 2 a + 1
          (%i4) ratwtlvl: 1$
          (%i5) expr1^2;
          (%o5)/R/                  2 b + 2 a + 1

There are also some inexact matches for ratweight. Try ?? ratweight to see them.

(%o1)                                true
(%i2) 

Ratweight Example

Related Examples

ratweight

? ratweight;

Calculate

ratweight-ratwtlvl

ratweight (a, 1, b, 1);

expr1: rat(a + b + 1);

expr1^2;

Calculate

ratweight

? ratweight;

Calculate

ratweight-ratwtlvl

ratweight (a, 1, b, 1);

expr1: rat(a + b + 1);

expr1^2;

Calculate