We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
flipsign
I find the non-standard flipsign function https://docs.julialang.org/en/v1/base/math/#Base.flipsign convenient, e.g. to implement upwind finite differencing stencils. It can be defined as
flipsign(x, y) = copysign(1, y) * x
but can be implemented more efficiently as
flipsign(x, y) = x ^ (y & SIGNMASK)
The text was updated successfully, but these errors were encountered:
If you allow me, I will "merge" this issue with #92 to have all this operators at one place.
Sorry, something went wrong.
No branches or pull requests
I find the non-standard
flipsign
function https://docs.julialang.org/en/v1/base/math/#Base.flipsign convenient, e.g. to implement upwind finite differencing stencils. It can be defined asbut can be implemented more efficiently as
The text was updated successfully, but these errors were encountered: