Skip to content
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

lmul! should be required for in-place application of plans #77

Open
dlfivefifty opened this issue Jul 23, 2018 · 3 comments
Open

lmul! should be required for in-place application of plans #77

dlfivefifty opened this issue Jul 23, 2018 · 3 comments

Comments

@dlfivefifty
Copy link
Member

Overall, I like the overriding of * for planned transforms. But it is a bit odd that * modifies what you multiply in the following:

P = plan_fft!(x); P * x 

I would propose deprecating plan_fft!, and instead only have plan_fft with the following usage for the in-place variants:

P = plan_fft(x); lmul!(P, x)
@stevengj
Copy link
Member

This won’t work, because the plan has to know it is in-place when it is created. In-place FFT algorithms are different from out-of-place algorithms.

@dlfivefifty
Copy link
Member Author

Ah ok. So then I guess the proposal would be:

P = plan_fft!(x)
P * x # equivalent to the current P * copy(x)
lmul!(P, x) # equivalent to the current P * x

@stevengj
Copy link
Member

Yes, that sounds reasonable.

@dlfivefifty dlfivefifty changed the title Should lmul! be used instead of plan_fft!,etc.? lmul! should be required for in-place application of plans Jul 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants