remove diagonal matrix, added driver and fixed most compilation issues