MATLAB: How to solve a PDE with Fast Fourier Transform in matlab (the problem has three dimensions X, Y, Z)

fftpde

This PDE is Allen-Cahn Equation with three dimensions. I think that I should use fftn() but I need to see an example script to see the effects of fftn() in whole script.
Thanks,

Best Answer

The documentation for fftn contains examples of its use:
https://www.mathworks.com/help/matlab/ref/fftn.html?s_tid=srchtitle#examples
MathWorks also offers a toolbox specifically for solving PDEs:
https://www.mathworks.com/products/pde.html
https://www.mathworks.com/help/pde/
This may also be of use to you:
https://www.mathworks.com/matlabcentral/fileexchange/23972-chebfun-v4-old-version--please-download-current-version-instead?focused=5593102&tab=example