How to force matlab to call a regular function rather than class method when they are overloaded?
问题 Assume I have an object X of class MyClass . MyClass has a method compute , and when I call U = compute(X,...) , matlab automatically calls the class method. However, what I actually want is to call another function also called compute whose parameters start with a MyClass object though. How do I force matlab to call this regular function rather than go into the class method? 回答1: There is no way to do this without making some changes either to the function's name or location. If you check