-
-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
missing matrix exponentiation methods for \euler
#579
Comments
I can't recall, but one thing that occurs to me is that it might cause a lot of method ambiguities? |
Why? The type on the first argument is |
It is, but the other argument is as general as it gets so this would be ambiguous with |
Oh yeah, I didn't think of that, that could be bad. So, I suppose what it should be is for T ∈ (AbstractIrrational, Rational, Integer, Number, Complex)
Base.:^(::Irrational{:ℯ}, x::T) = exp(x)
Base.:^(::Irrational{:ℯ}, x::AbstractArray{T}) = exp(x)
end Could probably make it just I can put in a PR if nobody foresees any other obvious potential issues. |
Wow, there's even a comment right there that says it was to avoid ambiguities for |
Is there any reason for this? Currently the following is defined in
base/mathconstants.jl
:Is there any reason why this is not simply
The text was updated successfully, but these errors were encountered: