Fixed webkit issue with buttons, removed useless import
Added additional math functions to REST backend