Round the calculated machine duration up
Correct graph grid drawing algorithm

Solve rounding problems and incorrect indices for loops.
Add proper console logging for chart drawing