Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Simon Perkins
ducc
Commits
45edfc90
Commit
45edfc90
authored
Jan 19, 2020
by
Martin Reinecke
Browse files
various
parent
8705186d
Changes
7
Hide whitespace changes
Inline
Side-by-side
Makefile.am
View file @
45edfc90
...
...
@@ -20,8 +20,8 @@ libmrutil_la_SOURCES = \
mr_util/constants.h
\
mr_util/error_handling.cc
\
mr_util/error_handling.h
\
mr_util/
morton_utils
.cc
\
mr_util/
morton_utils
.h
\
mr_util/
space_filling
.cc
\
mr_util/
space_filling
.h
\
mr_util/fft.h
\
mr_util/gl_integrator.h
\
mr_util/mav.h
\
...
...
@@ -72,13 +72,13 @@ nobase_include_HEADERS = \
EXTRA_DIST
=
runtest.sh
check_PROGRAMS
=
sharp2_testsuite
morton
_test
check_PROGRAMS
=
sharp2_testsuite
space_filling
_test
sharp2_testsuite_SOURCES
=
test
/sharp2_testsuite.cc
sharp2_testsuite_LDADD
=
libmrutil.la
morton
_test_SOURCES
=
test
/
morton
_test.cc
morton
_test_LDADD
=
libmrutil.la
space_filling
_test_SOURCES
=
test
/
space_filling
_test.cc
space_filling
_test_LDADD
=
libmrutil.la
TESTS
=
run
test.sh
TESTS
=
test
/test_libsharp.sh
test
/test_space_filling
.sh
pkgconfigdir
=
$(libdir)
/pkgconfig
nodist_pkgconfig_DATA
=
@PACKAGE_NAME@.pc
...
...
libsharp2/sharp_geomhelpers.cc
View file @
45edfc90
...
...
@@ -243,7 +243,8 @@ unique_ptr<sharp_geom_info> sharp_make_fejer1_geom_info (size_t nrings, size_t p
weight
[
2
*
k
]
=
2.
/
(
1.
-
4.
*
k
*
k
)
*
sin
((
k
*
pi
)
/
nrings
);
}
if
((
nrings
&
1
)
==
0
)
weight
[
nrings
-
1
]
=
0.
;
mr
::
r2r_fftpack
({
size_t
(
nrings
)},
{
1
},
{
1
},
{
0
},
false
,
false
,
weight
.
data
(),
weight
.
data
(),
1.
);
auto
tmp
=
fmav
(
weight
.
data
(),{
nrings
});
mr
::
r2r_fftpack
(
tmp
,
tmp
,
{
0
},
false
,
false
,
1.
);
for
(
size_t
m
=
0
;
m
<
(
nrings
+
1
)
/
2
;
++
m
)
{
...
...
@@ -275,7 +276,8 @@ unique_ptr<sharp_geom_info> sharp_make_cc_geom_info (size_t nrings, size_t pprin
for
(
size_t
k
=
1
;
k
<=
(
n
/
2
-
1
);
++
k
)
weight
[
2
*
k
-
1
]
=
2.
/
(
1.
-
4.
*
k
*
k
)
+
dw
;
weight
[
2
*
(
n
/
2
)
-
1
]
=
(
n
-
3.
)
/
(
2
*
(
n
/
2
)
-
1
)
-
1.
-
dw
*
((
2
-
(
n
&
1
))
*
n
-
1
);
mr
::
r2r_fftpack
({
size_t
(
n
)},
{
1
},
{
1
},
{
0
},
false
,
false
,
weight
.
data
(),
weight
.
data
(),
1.
);
auto
tmp
=
fmav
(
weight
.
data
(),{
n
});
mr
::
r2r_fftpack
(
tmp
,
tmp
,
{
0
},
false
,
false
,
1.
);
weight
[
n
]
=
weight
[
0
];
for
(
size_t
m
=
0
;
m
<
(
nrings
+
1
)
/
2
;
++
m
)
...
...
@@ -308,7 +310,8 @@ unique_ptr<sharp_geom_info> sharp_make_fejer2_geom_info (size_t nrings, size_t p
for
(
size_t
k
=
1
;
k
<=
(
n
/
2
-
1
);
++
k
)
weight
[
2
*
k
-
1
]
=
2.
/
(
1.
-
4.
*
k
*
k
);
weight
[
2
*
(
n
/
2
)
-
1
]
=
(
n
-
3.
)
/
(
2
*
(
n
/
2
)
-
1
)
-
1.
;
mr
::
r2r_fftpack
({
size_t
(
n
)},
{
1
},
{
1
},
{
0
},
false
,
false
,
weight
.
data
(),
weight
.
data
(),
1.
);
auto
tmp
=
fmav
(
weight
.
data
(),{
n
});
mr
::
r2r_fftpack
(
tmp
,
tmp
,
{
0
},
false
,
false
,
1.
);
for
(
size_t
m
=
0
;
m
<
nrings
;
++
m
)
weight
[
m
]
=
weight
[
m
+
1
];
...
...
mr_util/
morton_utils
.cc
→
mr_util/
space_filling
.cc
View file @
45edfc90
...
...
@@ -29,7 +29,7 @@
* Author: Martin Reinecke
*/
#include
"mr_util/
morton_utils
.h"
#include
"mr_util/
space_filling
.h"
namespace
mr
{
...
...
mr_util/
morton_utils
.h
→
mr_util/
space_filling
.h
View file @
45edfc90
...
...
@@ -30,8 +30,8 @@
* Author: Martin Reinecke
*/
#ifndef MRUTIL_
MORTON_UTILS
_H
#define MRUTIL_
MORTON_UTILS
_H
#ifndef MRUTIL_
SPACE_FILLING
_H
#define MRUTIL_
SPACE_FILLING
_H
#include
<cstdint>
#include
<array>
...
...
test/
morton
_test.cc
→
test/
space_filling
_test.cc
View file @
45edfc90
#include
<functional>
#include
"mr_util/
morton_utils
.h"
#include
"mr_util/
space_filling
.h"
#include
"mr_util/error_handling.h"
using
namespace
std
;
...
...
run
test.sh
→
test
/test_libsharp
.sh
View file @
45edfc90
File moved
test/test_space_filling.sh
0 → 100755
View file @
45edfc90
#!/bin/sh
./space_filling_test
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment