Write rmswell bug

For test case 9