This function uses MATLAB's INTEGRAL2 and INTEGRAL3 functions iteratively to perform integrals of order 4, 5, and 6.
I also thank you for this piece of work. I created a dummy extension for up to 8-D:
Please check if I did the licencing and acknowledgements correctly, and any critics are welcome.
Firstly, thank you for creating such an excellent function for higher-order integration. Believe me, it drastically reduced the complexity for my 4th order optical propagation function.
However, to further speed up the execution, I would like to implement this on GPU. How would you suggest I go about it? Simply converting all the variables into GPU variables isn't enough.
Minor update: fixed a typo in the comments and made a slight efficiency improvement by removing an unnecessary wrapper around the "inner" function where it is passed to arrayfun.