continue working on math engine