Started refactoring of API. The whole library is being refactored to simplify dependencies of interfaces, and calculations.