Question about cancelling out units



Dear Edward,

Thanks a lot! This has solved most of my problems - there was a second
one (maxima did insist in using other units than I am used to, which was
solved by setunits([kilometer,second]). 
For the last problem I had to solve I have a question, though:
Do you - or does anybody else in this list - know if there is a good
reason why unit.mac cannot automatically do a 

assume(kilometer>0,farad>0,ohm>0);

and so on? Without this assumption

sqrt((2*ohm)^2)
results in:
 2|ohm|
instead of:
 2 ohm
since maxima has no way of determining if 2*ohm is positive or negative.
Not defining units to be positive or negative sounds right at the first
sight. But it prevents from optimizing things like (a*|ohm|*a*ohm)/(a*|
ohm|+a*ohm) and tends to provoke errors when a is assigned a value.

---

Just for interest: Both the source of unit.mac and the manual seem to
indicate that

metricexpandall(3);

should enable me to use units like picrofarad or femtogram but in
reality doesn't seem to define these units.
Does anybody know if I got something wrong or if I found a bug? 

Thanks again,
and
Kind regards,

 Gunter.


Am Mittwoch, den 23.01.2013, 11:11 -0800 schrieb Edward A Romana:
> ~~
> 
> Gunter
> 
> First load the units program 
> 
> (%i1) load("C:/~path/bsiunits.mac")$
> [meter,kilogram,second,ampere,kelvin,mol,candela]
> "Type units_help() to display units help"
> 
> For your expression  %e^(numerical_value * unit_dimensionless_group )
>  then 
> 
> (%i2) %e^(1*second/(1*farad*1*ohm));
> (%o2) %e
> 
> Also, the style for units has: the unit name is always singular. The
> nice single letter unit symbols are not used in units,
> does 'm' stand for mass or meters etc. Unit names are somewhat
> verbose.
> 
> 
> 
> 
> ear.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <http://www.math.utexas.edu/pipermail/maxima/attachments/20130202/76f3de4a/attachment.pgp>;