While using the built-in relieff method, I am getting an error : " Undefined function exp for input arguments of type int64 ".
14 次查看(过去 30 天)
显示 更早的评论
While using the relieff method, I am getting an error : " Undefined function exp for input arguments of type int64 ". What are the possible reasons for this? I know that undefined function errors come when the method is not in the path. But here I am calling a built-in function, which is supposed to be in the path.
0 个评论
回答(1 个)
Walter Roberson
2017-7-5
You are calling a built-in function, but you are calling it passing in something that is a 64 bit integer data type, and that is not an operation that has been built-in. If you are certain that the integer does not exceed 2^53 then you can exp(double(TheVariable)) . But keep in mind that exp(708) is about as large as you can go without hitting infinity, and since the output is required to be the same data type as the input, exp() of an int64 would be required an integer data type representation of infinity, which does not exist.
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Argument Definitions 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!