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:

Logcontract Calculator

Logcontract

Function: logcontract (<expr>) Recursively scans the expression <expr>, transforming subexpressions of the form a1*log(b1) + a2*log(b2) + c into log(ratsimp(b1^a1 * b2^a2)) + c

e1: 2*(2*a*log(y)+a*log(x));
logcontract(e1);
e2:-4*log(4)/3  + log(3)+ 2 *log(2) + 1;
 logcontract(e2);

          (%i1) 2*(a*log(x) + 2*a*log(y))$
          (%i2) logcontract(%);
                                           2  4
          (%o2)                     a log(x  y )

If you do declare(n,integer); then logcontract(2*a*n*log(x)); gives a*log(x^(2*n)). The coefficients that "contract" in this manner are those such as the 2 and the n here which satisfy featurep(coeff,integer). The user can control which coefficients are contracted by setting the option logconcoeffp to the name of a predicate function of one argument. E.g. if you like to generate SQRTs, you can do logconcoeffp:logconfun$ logconfun(m):=featurep(m,integer) or ratnump(m)$ . Then logcontract(1/2*log(x)); will give log(sqrt(x)).

(%o1)                                true
(%i2) 

Logcontract Example

Related Examples

logcontract-solve

log2(x):=log(x)/log(2);

f:log2(x+1)+log2(X-5);

g:logcontract(f);

Calculate

logcontract

logcontract(log(a)+lo...

Calculate

logcontract

f:log2(x+1)+log2(x-5)=4;

g:logcontract(f);

Calculate

logcontract

logcontract(log(z/a) ...

Calculate

logcontract

f:log2(x+1)+log2(x-5);

g:logcontract(f);

v:slove(g=4,x);

Calculate

logcontract-solve

f:log2(x+1)+log2(x-5)=4;

g:logcontract(f);

v:solve(g=4,x);

Calculate

logcontract-solve

log2(x):=log(x)/log(2);

f:log2(x+1);

log2(x-5);

Calculate

logcontract-solve

f:log2(x+1)+log2(X-5);

g:logcontract(f);

v:solve(g=4,x);

Calculate

logcontract

f:log2(x+1)+log2(x-5)=4;

g:logcontract(f);

Calculate

logcontract-solve

log2(x):=log(x)/log(2);

f:log2(x+1)+log2(x-5);

g:logcontract(f);

Calculate