Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
0c85f048
Commit
0c85f048
authored
2 years ago
by
Wuttke, Joachim
Browse files
Options
Downloads
Patches
Plain Diff
polyhedral ff tests moved to libff
parent
6d258eed
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!1193
polyhedral ff tests moved to libff
Pipeline
#83430
passed
2 years ago
Stage: build
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Tests/Unit/Numeric/FormFactorSpecializationTest.cpp
+0
-59
0 additions, 59 deletions
Tests/Unit/Numeric/FormFactorSpecializationTest.cpp
Tests/Unit/Numeric/FormFactorSymmetryTest.cpp
+0
-42
0 additions, 42 deletions
Tests/Unit/Numeric/FormFactorSymmetryTest.cpp
with
0 additions
and
101 deletions
Tests/Unit/Numeric/FormFactorSpecializationTest.cpp
+
0
−
59
View file @
0c85f048
...
...
@@ -18,65 +18,6 @@ protected:
}
};
const
double
eps_polyh
=
6e-12
;
// Linux 3e-12, relaxed for Win
TEST_F
(
FFSpecializationTest
,
TruncatedCubeAsBox
)
{
const
double
L
=
.5
;
TruncatedCube
p0
(
L
,
0
);
Box
p1
(
L
,
L
,
L
);
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
5e2
);
}
TEST_F
(
FFSpecializationTest
,
Pyramid2AsPyramid4
)
{
const
double
L
=
1.5
,
H
=
.24
,
alpha
=
.6
;
Pyramid2
p0
(
L
,
L
,
H
,
alpha
);
Pyramid4
p1
(
L
,
H
,
alpha
);
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
50
);
}
TEST_F
(
FFSpecializationTest
,
Pyramid3AsTetrahedron
)
{
static
const
double
alpha
=
atan
(
sqrt
(
8
));
const
double
L
=
1.8
;
Pyramid3
p0
(
L
,
sqrt
(
2.
/
3
)
*
L
,
alpha
);
PlatonicTetrahedron
p1
(
L
);
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
50
);
}
TEST_F
(
FFSpecializationTest
,
OctahedronAsTruncated
)
{
const
double
L
=
1.8
;
PlatonicOctahedron
p0
(
L
);
Bipyramid4
p1
(
L
,
L
/
sqrt
(
2
),
1.
,
atan
(
sqrt
(
2
)));
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
50
);
}
TEST_F
(
FFSpecializationTest
,
Pyramid3AsPrism
)
{
const
double
L
=
1.8
,
H
=
.3
;
Pyramid3
p0
(
L
,
H
,
M_PI
/
2
);
Prism3
p1
(
L
,
H
);
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
50
);
}
TEST_F
(
FFSpecializationTest
,
Pyramid4AsBox
)
{
const
double
L
=
1.8
,
H
=
.3
;
Pyramid4
p0
(
L
,
H
,
M_PI
/
2
);
Box
p1
(
L
,
L
,
H
);
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
100
);
}
TEST_F
(
FFSpecializationTest
,
Pyramid6AsPrism
)
{
const
double
L
=
.8
,
H
=
1.13
;
Pyramid6
p0
(
L
,
H
,
M_PI
/
2
);
Prism6
p1
(
L
,
H
);
run_test
(
&
p0
,
&
p1
,
eps_polyh
,
1e-99
,
100
);
}
//*********** cylinders ***************
TEST_F
(
FFSpecializationTest
,
HorizontalCylinderSlicedVsUnsliced
)
...
...
This diff is collapsed.
Click to expand it.
Tests/Unit/Numeric/FormFactorSymmetryTest.cpp
+
0
−
42
View file @
0c85f048
...
...
@@ -18,48 +18,6 @@ protected:
}
};
//*********** polyhedra ***************
TEST_F
(
FFSymmetryTest
,
Prism3
)
{
Prism3
ff
(
.83
,
.45
);
run_test
(
&
ff
,
[](
const
C3
&
q
)
->
C3
{
return
q
.
rotatedZ
(
M_TWOPI
/
3
);
},
1e-13
,
1e-99
,
2e2
);
}
TEST_F
(
FFSymmetryTest
,
Prism6
)
{
Prism6
ff
(
1.33
,
.42
);
run_test
(
&
ff
,
[](
const
C3
&
q
)
->
C3
{
return
q
.
rotatedZ
(
M_PI
/
3
);
},
1e-13
,
1e-99
,
50
);
run_test
(
&
ff
,
[](
const
C3
&
q
)
->
C3
{
return
q
.
rotatedZ
(
-
M_TWOPI
/
3
);
},
1e-13
,
1e-99
,
50
);
}
TEST_F
(
FFSymmetryTest
,
Pyramid3
)
{
Pyramid3
ff
(
8.43
,
.25
,
.53
);
run_test
(
&
ff
,
[](
const
C3
&
q
)
->
C3
{
return
q
.
rotatedZ
(
M_TWOPI
/
3
);
},
1e-11
,
1e-99
,
100
);
// Linux: 3e-12, relaxed for Mac
}
TEST_F
(
FFSymmetryTest
,
Pyramid6xFlat
)
{
// TODO for larger q, imag(ff) is nan
Pyramid6
ff
(
4.3
,
.09
,
.1
);
run_test
(
&
ff
,
[](
const
C3
&
q
)
->
C3
{
return
q
.
rotatedZ
(
-
M_PI
/
3
);
},
8e-10
,
1e-99
,
50
);
// Linux: 2e-12, relaxed for Mac
}
TEST_F
(
FFSymmetryTest
,
Pyramid6xSteep
)
{
Pyramid6
ff
(
.23
,
3.5
,
.999
*
M_PI
/
2
);
run_test
(
&
ff
,
[](
const
C3
&
q
)
->
C3
{
return
q
.
rotatedZ
(
-
M_PI
/
3
);
},
3e-10
,
1e-99
,
50
);
}
//*********** spheroids ***************
TEST_F
(
FFSymmetryTest
,
HemiEllipsoid
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment