Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • N NIFTy
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 19
    • Issues 19
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ift
  • NIFTy
  • Issues
  • #71
Closed
Open
Issue created Apr 10, 2017 by Pumpe, Daniel (dpumpe)@dpumpe

FFT transformations, RGSpace(zerocenter)

Hi, during a few small tests Martin and me came across a serious problem concerning harmonic transformations. If one uses a RGSpace with npix%2 !=0 and zerocenter=True the FFT gives wrong results (see example res4.val). As the handling of the zerocenter-keyword seems to give rise to various problems and in particular complexity in the code, we have to ask the question "what is it necessary for". If we come to the conclusion that we can drop it in fewer of simplicity, which necessary functionality would we loose?

`x1 = RGSpace(200, zerocenter=False, distances=0.1) k1 = RGRGTransformation.get_codomain(x1, zerocenter=False)

FFT1 = FFTOperator(domain=x1, target=k1, domain_dtype=np.float64, target_dtype=np.complex64)

test_field_1 = Field(x1, val=1.)

res1 = FFT1.inverse_times(FFT1.times(test_field_1))

x2 = RGSpace(200, zerocenter=True, distances=0.1) k2 = RGRGTransformation.get_codomain(x2, zerocenter=True)

FFT2 = FFTOperator(domain=x2, target=k2, domain_dtype=np.float64, target_dtype=np.complex64)

test_field_2 = Field(x2, val=1.)

res2 = FFT2.inverse_times(FFT2.times(test_field_2))

x3 = RGSpace(199, zerocenter=False, distances=0.1) k3 = RGRGTransformation.get_codomain(x3, zerocenter=False)

FFT3 = FFTOperator(domain=x3, target=k3, domain_dtype=np.float64, target_dtype=np.complex64)

test_field_3 = Field(x3, val=1.)

res3 = FFT3.inverse_times(FFT3.times(test_field_3))

x4 = RGSpace(199, zerocenter=True, distances=0.1) k4 = RGRGTransformation.get_codomain(x4, zerocenter=True)

FFT4 = FFTOperator(domain=x4, target=k4, domain_dtype=np.float64, target_dtype=np.complex64)

test_field_4 = Field(x4, val=1.)

res4 = FFT4.inverse_times(FFT4.times(test_field_4))```

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking