comcalc in rails