cleared up code, tested floats and doubles, also wrote a simple tutorial in readme