Update formulas, Add comments, Fix helper functions