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

Add FFTW-based synthesis and analysis #13

Closed
ahbarnett opened this issue Jul 25, 2018 · 3 comments
Closed

Add FFTW-based synthesis and analysis #13

ahbarnett opened this issue Jul 25, 2018 · 3 comments

Comments

@ahbarnett
Copy link

Hi Michael,

It took a little while to get build on linux going. Here's suggestions for tweaks to library (not worth a pull request). I only tested on ubuntu 16.04.

Append to Make.inc:

ifeq ($(UNAME), Linux)
LDLIBS += -lm
CFLAGS += -I/usr/lib/openblas-base
LDFLAGS += -L/usr/lib/openblas-base
endif

You'll also need to add in the ifeq windows block:
UNAME := Windows

Also, you'll want to add instructions to type in the shell:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:.

Otherwise the executable can't find the .so

My tests now all run, although I don't understand the output.

PS It's not apparent from your docs how to do a simple spherical harmonic eval or projection onto a tensor product grid. Am I supposed to do sph to Fourier then do FFT2 on grid? I would have to guess the normalization, etc. An example of that would be very helpful.

PPS Good to see you at ICOSAHOM!

@MikaelSlevinsky
Copy link
Owner

This is really helpful, thanks!

The plan is to port over the synthesis and analysis from FFTW as in the Julia package https://github.com/MikaelSlevinsky/FastTransforms.jl/blob/master/src/SphericalHarmonics/synthesisanalysis.jl

@MikaelSlevinsky
Copy link
Owner

The repository now builds and runs the tests on Travis' linux infrastructure. FFTW-based synthesis and analysis are forthcoming and will be available as part of a first release.

@MikaelSlevinsky MikaelSlevinsky changed the title build on linux / docs for how to do sph harm projection to/from grid Add FFTW-based synthesis and analysis Jul 25, 2018
@MikaelSlevinsky
Copy link
Owner

P.S. I started adding FFTW overrides for synthesis and analysis on the sphere. I'm not closing the issue because I still have to do the triangle and disk cases, but I also added an example that works through a simple case numerically illustrating the spherical harmonic addition theorem.

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