[GRASSLIST:5514] Re: A problem with computation in r.mapcalc

Daren Zywicki daren.zywicki at gtri.gatech.edu
Sun Feb 9 16:44:36 EST 2003


I think you need to use the exp(x,y) command instead of the 10^y 
notation.  So for power of ten, use exp(10,y) for 10^y.

Daren



At 08:59 PM 2/8/2003 +0000, Miha STAUT wrote:
>Hi all,
>
>I have a problem computing this with r.mapcalc:
>
>r.mapcalc < avg # piping
>avg=10*log((
>10^(rast1/10-12)*6.863636
>+10^(rast2/10-12)*2.909091
>+10^(rast3/10-12)*3.742424
>+10^(rast4/10-12)*2.333333
>+10^(rast5/10-12)*2.318182
>+10^(rast6/10-12)*3.590909
>+10^(rast7/10-12)*0.969697
>+10^(rast8/10-12)*2.435484
>)
>*10^12/30.84457
>,10)
>
>The process of computing seems to finish OK, but the new map gives only 
>NAs. Why can that be? The problem appearently lies in the 10^rast. All the 
>rasters have values between 0 and 140. The final map should not have 
>excessively high values.
>
>How should I surround the problem?
>
>Thanks in advance, Miha
>
>_________________________________________________________________
>The new MSN 8: smart spam protection and 2 months FREE*
>http://join.msn.com/?page=features/junkmail

____________________________________________________
Daren J. Zywicki, PhD
Georgia Tech Research Institute
Sensors and Electromagnetic Applications Lab (SEAL)
____________________________________________________




More information about the grass-user mailing list