Finished removing extra functions, and cleaned up code. Ready to begin multidimensional implementation