Cleanup

- Code cleanup
- Obsolete slow routines removed
- Nx, Ny, etc are hard-coded
minor corrections: limits on graphs