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
f703a9d6
Commit
f703a9d6
authored
2 years ago
by
Wuttke, Joachim
Browse files
Options
Downloads
Patches
Plain Diff
rm auxiliary class
parent
18fa2ede
No related branches found
No related tags found
1 merge request
!1021
work on readability of slicing machinery
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Resample/Processed/ParticleRegions.cpp
+0
-42
0 additions, 42 deletions
Resample/Processed/ParticleRegions.cpp
with
0 additions
and
42 deletions
Resample/Processed/ParticleRegions.cpp
+
0
−
42
View file @
f703a9d6
...
...
@@ -25,35 +25,6 @@
#include
<stdexcept>
#include
<utility>
// ************************************************************************************************
// define local class
// ************************************************************************************************
//! Helper class for the graded layer approximation. Generates limits for each layer, indicating
//! the region of the layer (along z) that contains particle(s)
//!
//! The constructor takes the bottom layer z-coordinates as parameter. This means that for N
//! layers, only N-1 coordinates need to be passed (the last layer is assumed to be semi-infinite).
//! @ingroup algorithms_internal
class
LayerFillLimits
{
public:
LayerFillLimits
(
std
::
vector
<
double
>
layers_bottomz
);
//! Particle limits are given in global coordinates
void
update
(
std
::
vector
<
ZLimits
>&
result
,
const
std
::
vector
<
double
>
ZBottoms
,
const
ZLimits
&
particle_limits
,
double
offset
);
private:
std
::
vector
<
double
>
m_ZBottoms
;
};
#ifndef INCLUDED_BY_TEST
// ************************************************************************************************
// implement local class
// ************************************************************************************************
namespace
{
std
::
vector
<
double
>
bottomLayerCoordinates
(
const
MultiLayer
&
sample
)
...
...
@@ -87,16 +58,6 @@ size_t iLayerBottom(double bottom, const std::vector<double> ZBottoms)
}
// namespace
LayerFillLimits
::
LayerFillLimits
(
std
::
vector
<
double
>
layers_bottomz
)
:
m_ZBottoms
(
std
::
move
(
layers_bottomz
))
{
}
void
LayerFillLimits
::
update
(
std
::
vector
<
ZLimits
>&
result
,
const
std
::
vector
<
double
>
ZBottoms
,
const
ZLimits
&
particle_span
,
double
offset
)
{
}
// ************************************************************************************************
// exported function
// ************************************************************************************************
...
...
@@ -112,7 +73,6 @@ std::vector<ZLimits> Compute::Slicing::particleRegions(const MultiLayer& sample,
return
result
;
const
std
::
vector
<
double
>
ZBottoms
=
bottomLayerCoordinates
(
sample
);
LayerFillLimits
layer_fill_limits
(
ZBottoms
);
for
(
size_t
i
=
0
;
i
<
N
;
++
i
)
{
const
Layer
*
layer
=
sample
.
layer
(
i
);
const
double
offset
=
(
i
==
0
)
?
0
:
ZBottoms
[
i
-
1
];
...
...
@@ -144,5 +104,3 @@ std::vector<ZLimits> Compute::Slicing::particleRegions(const MultiLayer& sample,
}
return
result
;
}
#endif // INCLUDED_BY_TEST
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