the new model now works, there's still one bug left to fix (sample incoherency). Works nicely for large intervals however.