First commit of calc functions