On several locations in the code, precautions are not being taken for not dividing by 0; this will revert the code. These functions can be called with 0 value in the input; this value is not checked for being bigger than 0, which means, in some scenarios, this can potentially trigger a division by zero.
We recommend making sure division by 0 wont occur by checking the variables beforehand and handling this edge case.
