[GRASS-user] Calculate Composite Curve Number without a BASH script?

is it possible to find the area weighted CN without resorting to writing a script to loop through all the watersheds? can it be done with map algebra? with cross product overlay? with r.coin? (somehow)

The equation:

CNcomposite = sum(CN*CNarea) / sum(CNarea)

so I have to find the total area of cells of each CN value per a watershed. I can do it with r.mask and r.stats but that is manually one by one and must be processed externally in a spreadsheet