added calcRcgw for the rcgw task