cleaning up code..
cleaned up integral code