Hi All,<br><br>please any python programmer could explain me the correct use of r.mapcalc in this case.<br>In my python script I have a formula like this:<br><br>n = 0.016 * (resolution ** 0.46)<br><br>(resolution is the cellsize of the input map).<br>
and I have to calculate a map with:<br><br>grass.mapcalc(&quot;mti = log((exp($rast1 , n)) / $rast2)&quot;, rast1 = &#39;r_accumulation&#39;, rast2 = &#39;r_slope&#39;)<br><br>but since n is not a map, i get the error:<br>
<br>Invalid map &lt;n&gt;<br>Parse error<br>ERROR: An error occurred while running r.mapcalc<br><br>How can I use the &#39;n&#39; in r.mapcalc?<br><br>Thank you in advance,<br><br>Margherita<br>