Help using r.mapcalc

You can write a script in mapcalc to do that. AN
easy one would be:

temp = if(your_map==1, eqn_for_1, if(your_map == 2, eqn_for_2, if(your_map==3,
eqn_for_3)))

This should do it but I think you have to be carefull, because you
have many inserted if's. Make sure you have the right closing parantehses.
Depending on you map layer this might take a long time also. If you recognize I
am trying to use if(x,a,b). I used some thing like this a while back.

So good luck

Nalneesh Gaur