Change matrix library to Apache Commons Math3 one