I'm somewhat new to recursion using Matlab, and I'm running into an error using R2021a. The controlling code is written in a live script file. I'll attach a picture of it (and the error I'm getting) below as well as the code for the function. Hopefully you all can point me in the right direction, because honestly, I'm out of ideas. I know the input data is in the right format and contains values that should work.
Cheers and thanks for your help!