Hi, I noted that in your code, it is suitable for 2 input situations, if I want to extend it to 3D or even more situations. Which part of your code should I modify? Regards, Peng