Comandos Úteis e Simples
Seção 2.8: Os Pacotes do Maple
Session 2.8.3: Units
| > | restart; |
| > | Digits := 5; |
| > | width := convert( 27.0, units, pica, cm ); |
| > | convert( 12.0, units, inch, pica ); |
| > |
| > | restart; |
| > | with( Units ); |
| > | convert(0., temperature, Celsius, kelvin); |
| > | convert( -55., temperature, Celsius, Fahrenheit ); |
| > | convert( -55., temperature, Fahrenheit, Celsius ); |
| > | convert( -40., temperature, Celsius, Fahrenheit ); |
| > | convert( -20., temperature, Celsius, Fahrenheit ); |
| > | convert( 86., temperature, Fahrenheit, Celsius ); |
| > | convert( 42., temperature, Celsius, Fahrenheit ); |
| > | convert( 165., 'units', 'Hp', 'kW' ); |
| > | restart; |
| > | with( Units[Natural] ); |
Warning, the assigned name polar now has a global binding
Warning, these protected names have been redefined and unprotected: *, +, -, /, <, <=, <>, =, Im, Re, ^, abs, arccos, arccosh, arccot, arccoth, arccsc, arccsch, arcsec, arcsech, arcsin, arcsinh, arctan, arctanh, argument, ceil, collect, combine, conjugate, convert, cos, cosh, cot, coth, csc, csch, csgn, diff, eval, evalc, evalr, exp, expand, factor, floor, frac, int, ln, log, log10, max, min, normal, root, round, sec, sech, shake, signum, simplify, sin, sinh, sqrt, surd, tan, tanh, trunc, type, verify
| > | 6*ft + 4.*inches; |
| > | restart; |
| > | with( Units ); |
| > | convert( 1.0, 'units', 'M', 'km/s' ); |
| > | 1/%; |
| > | convert( 1.0, 'units', 'M', 'mi/s' ); |
| > | 1/%; |
| > | restart; |
| > | with(Units): |
| > | GetUnit(megatonne); |
| > | restart; |
| > | convert( 1., units, kg, joule, energy=true ); |
| > | restart; |
| > | with( Units[Natural] ): |
Warning, the assigned name polar now has a global binding
Warning, these protected names have been redefined and unprotected: *, +, -, /, <, <=, <>, =, Im, Re, ^, abs, arccos, arccosh, arccot, arccoth, arccsc, arccsch, arcsec, arcsech, arcsin, arcsinh, arctan, arctanh, argument, ceil, collect, combine, conjugate, convert, cos, cosh, cot, coth, csc, csch, csgn, diff, eval, evalc, evalr, exp, expand, factor, floor, frac, int, ln, log, log10, max, min, normal, root, round, sec, sech, shake, signum, simplify, sin, sinh, sqrt, surd, tan, tanh, trunc, type, verify
| > | mass := 1.0*kg; |
| > | c := 3.00e8 * m/s; |
| > | energy := mass*c^2; |
| > | 3.*V/V(base); |
| > | ln( % ); |
| > | convert( %, units, dB ); |
a gain of 3 volts is a gain of 10 decibels, e.g.,
| > | min( 3*m, 10*ft, 3.2*yd); |
| > | min( 3.*m, 10.*ft, 1.0*x*yd); |
| > | diff( (x^2+3*x+4)*m, x*s ); |
| > | int( %, x*s=4..7); |
| > | plot( sin(x*degrees), x=0..180 ); |
| > | floor( 9.2*s ); |
| > | sin((tau*s)*radian/s); |
| > |
| > |
| > |