Improved memory coalesing in kernals by flipping dipole, Added testing facilities. cleaning up host code