How many redistributions are done when using Fourier and Chebychev bases?

14 views
Skip to first unread message

Thomas Baumann

unread,
Jun 18, 2025, 8:29:07 AM6/18/25
to Dedalus Users
When discretizing one axis with Fourier base and another with Chebychev base, the differentiation matrix in the Fourier axis is diagonal but it is not in the Chebychev axis. Therefore, when inverting the differentiation matrix (+BCs), the data needs to be distributed in the Fourier axis and aligned in the Chebychev axis when parallelizing. 
This suggests to transform the Fourier axis first, redistribute, transform the Chebychev axis, and then immediately solve the system with no further redistribution. However, FFTW does not support c2c DCT, afaik, and the output of the FFT is generally complex.
This suggests to do the r2r DCT along the Chebychev axis first, redistribute, do the c2c FFT along the Fourier axis, redistribute, and then solve. But this requires one more redistribution. Alternatively, scipy has c2c DCTs, but scipy does not have an interface for reusing plans.

How is this handled in Dedalus? Do you do all transforms with FFTW at the cost of one more redistribution or do you use some other library for complex DCT and do only as many redistributions as strictly needed?

Thanks,
Thomas

Reply all
Reply to author
Forward
0 new messages