Negligible terms in polynomials



Mmm... I think it's not the right way. I gave a bad example.
The real problem is this: I have a vector containing some polynomials, 
wich represent the displacements of some points of a structure (I'm 
writing a didactic software to solve structures in a symbolic way). In 
this vector, displacements are the combination of two kinds of 
deformation, axial and flexional, the first dependin on A (area), the 
second on I (momentum of inertia). So, in example:

(%i1) u:matrix( [M*l^2/(E*I) + q*l/(E*A)] , [q*l/(E*A)] )$

that is the matrix (a column vector) of displacements. The first term 
depends on both  flexional and axial deformation, the second only on the 
axial one. Do not care about the meanings of the symbols, they are all 
assumed > 0. Now, I say that axial deformation is negligible with 
respect to flexional one. I can do this by saying A>>I. The resulting 
vector should be:

u2: matrix( [ M*l^2/(E*I)] , [q*l/(E*A)])$

where only the first term has been modified, because in it there are 
both flexional and axial deformation effects. The second term is 
unchanged because the axial one is the only deformation present.
I can map rat over all the elements of u, but then? Using tellrat is not 
possible, because it would set the second element of the matrix to zero, 
nor it it possible to use ratweight, because it has effect only on 
further multiplications or exponentiations, but I have not to do 
operations on u, and it will eliminate also terms that sholud be keeped. 
I only have to neglect some terms with respect to others, element by 
element in u.
Sorry for the long email... any idea?
Thanks, Stefano




Alexey Beshenov ha scritto:
> On Thursday 08 January 2009 02:05:24 Stefano Ferri wrote:
>   
>> How could I indicate to Maxima that in a polynomial some terms are
>> negiglible with respect to others?
>> In example, if
>>
>> expr: a+b;
>>
>> how could I make a>>b, so expr will be simplified to a? I should do
>> this in a sum like the one shown, so I think I cannot use
>> ratweights because there are not multiplications or
>> exponentiations. Thanks.
>>     
>
> Try tellrat:
>
> (%i1) expr : rat(a+b)$
> (%i2) tellrat (b)$
> (%i3) expr;
> (%o3)/R/                    b + a
> (%i4) expr, algebraic;
> (%o4)/R/                      a
>
>
> Or you can do it manually:
>
> (%i1) set_to_zero (expr,[terms]) :=
>         at (expr, map (lambda([x],x=0), terms))$
> (%i2) set_to_zero (a+b+c+d+e, b,d);
> (%02)                     e + c + a 
>
>