Skip to content
Snippets Groups Projects
Commit 6d6509c3 authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

Merge branch 'ff01' into 'develop'

compute sinc(x) diretly w/o calling gsl

See merge request !485
parents f95ba512 3b95e297
No related branches found
No related tags found
1 merge request!485compute sinc(x) diretly w/o calling gsl
Pipeline #50481 passed
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
#include <fftw3.h> #include <fftw3.h>
#include <gsl/gsl_sf_erf.h> #include <gsl/gsl_sf_erf.h>
#include <gsl/gsl_sf_expint.h> #include <gsl/gsl_sf_expint.h>
#include <gsl/gsl_sf_trig.h>
#include <limits> #include <limits>
#include <random> #include <random>
#include <stdexcept> // need overlooked by g++ 5.4 #include <stdexcept> // need overlooked by g++ 5.4
...@@ -52,7 +51,9 @@ double Math::cot(double x) ...@@ -52,7 +51,9 @@ double Math::cot(double x)
double Math::sinc(double x) // Sin(x)/x double Math::sinc(double x) // Sin(x)/x
{ {
return gsl_sf_sinc(x / M_PI); if (x==0)
return 1;
return std::sin(x) / x;
} }
complex_t Math::sinc(const complex_t z) // Sin(x)/x complex_t Math::sinc(const complex_t z) // Sin(x)/x
......
...@@ -5622,10 +5622,10 @@ C++ includes: ZLimits.h ...@@ -5622,10 +5622,10 @@ C++ includes: ZLimits.h
"; ";
// File: namespace_0d105.xml // File: namespace_0d120.xml
// File: namespace_0d108.xml // File: namespace_0d123.xml
// File: namespace_0d129.xml // File: namespace_0d129.xml
...@@ -6361,21 +6361,6 @@ Used by the hard sphere and by several soft sphere classes. ...@@ -6361,21 +6361,6 @@ Used by the hard sphere and by several soft sphere classes.
// File: IProfileRipple_8h.xml // File: IProfileRipple_8h.xml
// File: PolyhedralComponents_8cpp.xml
// File: PolyhedralComponents_8h.xml
// File: PolyhedralTopology_8h.xml
// File: Polyhedron_8cpp.xml
// File: Polyhedron_8h.xml
// File: Prism_8cpp.xml // File: Prism_8cpp.xml
...@@ -6421,6 +6406,21 @@ Used by the hard sphere and by several soft sphere classes. ...@@ -6421,6 +6406,21 @@ Used by the hard sphere and by several soft sphere classes.
// File: Lattice3D_8h.xml // File: Lattice3D_8h.xml
// File: PolyhedralComponents_8cpp.xml
// File: PolyhedralComponents_8h.xml
// File: PolyhedralTopology_8h.xml
// File: Polyhedron_8cpp.xml
// File: Polyhedron_8h.xml
// File: SomeFormFactors_8cpp.xml // File: SomeFormFactors_8cpp.xml
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment