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:

Multthru Calculator

Multthru

Function: multthru (<expr>)

Function: multthru (<expr_1>, <expr_2>) Multiplies a factor (which should be a sum) of <expr> by the other factors of <expr>. That is, <expr> is <f_1> <f_2> ... <f_n> where at least one factor, say <f_i>, is a sum of terms. Each term in that sum is multiplied by the other factors in the product. (Namely all the factors except <f_i>). multthru does not expand exponentiated sums. This function is the fastest way to distribute products (commutative or noncommutative) over sums. Since quotients are represented as products multthru can be used to divide sums by products as well.

multthru (<expr_1>, <expr_2>) multiplies each term in <expr_2> (which should be a sum or an equation) by <expr_1>. If <expr_1> is not itself a sum then this form is equivalent to multthru (<expr_1>*<expr_2>).

          (%i1) x/(x-y)^2 - 1/(x-y) - f(x)/(x-y)^3;
                                1        x         f(x)
          (%o1)             - ----- + -------- - --------
                              x - y          2          3
                                      (x - y)    (x - y)
          (%i2) multthru ((x-y)^3, %);
                                     2
          (%o2)             - (x - y)  + x (x - y) - f(x)
          (%i3) ratexpand (%);
                                     2
          (%o3)                   - y  + x y - f(x)
          (%i4) ((a+b)^10*s^2 + 2*a*b*s + (a*b)^2)/(a*b*s^2);
                                  10  2              2  2
                           (b + a)   s  + 2 a b s + a  b
          (%o4)            ------------------------------
                                            2
                                       a b s
          (%i5) multthru (%);  /* note that this does not expand (b+a)^10 */
                                                  10
                                 2   a b   (b + a)
          (%o5)                  - + --- + ---------
                                 s    2       a b
                                     s
          (%i6) multthru (a.(b+c.(d+e)+f));
          (%o6)            a . f + a . c . (e + d) + a . b
          (%i7) expand (a.(b+c.(d+e)+f));
          (%o7)         a . f + a . c . e + a . c . d + a . b

(%o1)                                true
(%i2) 

Multthru Example

Related Examples

multthru-ratsimp-xthru

a: 1/(c-d)-c/(c^2-d^2...

xthru(a);

b:ratsimp(a);

Calculate

multthru

eq1: (e1+e2+2*(e3+e4)...

multthru(eq1);

Calculate

multthru-sqrt

expr:1/[1+sqrt(10)+sq...

multthru(expr);

Calculate

multthru

eq1: (e1+e2+2*(e3+e4)...

multthru(eq1);

Calculate

multthru-ratsimp-xthru

a: 1/(c-d)-c/(c^2-d^2...

xthru(a);

b:ratsimp(a);

Calculate

multthru-ratsimp-xthru

a: 1/(c-d)-c/(c^2-d^2...

xthru(a);

b:ratsimp(a);

Calculate

multthru

f:(x1+x2)*(x2+x3)*(x3...

multthru(f);

Calculate

multthru-sqrt

expr:1/[1+sqrt(10)+sq...

multthru(expr);

Calculate