Update compute.c

Fixed a few small errors and updated comments