Fixed main include, added ceiling function