-
Notifications
You must be signed in to change notification settings - Fork 23
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
Inverse functions #15
Comments
@mschauer, thank you for noting this. I was pretty busy when you contributed this comment, and it fell off my radar--sorry for my slow response! I think that the suggestion sounds reasonable. I'm not sure if or when I'll have a chance to look at this, but if you have time and want to explore contributing something like this to Match.jl, I'd be happy to consider it. |
Macros cannot be extended, but immutable Inverse end
f(x) = x^2
f(::Inverse, x) = sqrt(x) that is, using the inverse function as a method of the original. This probably has ambiguity problems, and it doesn't strike me as very Julian. |
This is very similar to #92. |
Treating as a dup of #92, which is probably closer to how we would handle this. |
I am thinking since a while, that it would be nice and very julian to match general functional expressions if the inverse of the function is provided, for example
would translate into
where
@inversefun
can be extended.The text was updated successfully, but these errors were encountered: