Fix some important things; parameterize c_s min; clean up; delete gpu arrays at exit.