inverse model patched and tested