Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
athena
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Peter Sherwood
athena
Commits
c5266f50
Commit
c5266f50
authored
4 years ago
by
Christos Anastopoulos
Browse files
Options
Downloads
Patches
Plain Diff
remove seemingly unused code
parent
0491459e
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Tracking/TrkDetDescr/TrkDetDescrUtils/TrkDetDescrUtils/OrderPositionsToStepVector.h
+0
-65
0 additions, 65 deletions
...tDescrUtils/TrkDetDescrUtils/OrderPositionsToStepVector.h
with
0 additions
and
65 deletions
Tracking/TrkDetDescr/TrkDetDescrUtils/TrkDetDescrUtils/OrderPositionsToStepVector.h
deleted
100644 → 0
+
0
−
65
View file @
0491459e
/*
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
*/
///////////////////////////////////////////////////////////////////
// BinUtility.h, (c) ATLAS Detector software
///////////////////////////////////////////////////////////////////
#ifndef TRKDETDESCRUTILS_ORDERPOSITIONSTOSTEPVECTOR_H
#define TRKDETDESCRUTILS_ORDERPOSITIONSTOSTEPVECTOR_H
#include
<algorithm>
#include
<vector>
namespace
Trk
{
/** @class OrderPositionsToStepVector
Class inheriting from std::vector<double> to transform 1-dim
un-aequidistant positions (x,y,z,r-values) into stepvectors
for BinUtility1D usage.
The constructor takes r/z values as a std::vector<double>,
a mimimum and a maximum boundary.
@author Andreas.Salzburger@cern.ch
*/
class
OrderPositionsToStepVector
:
public
std
::
vector
<
double
>
{
public:
/**Constructor with arguments*/
OrderPositionsToStepVector
(
std
::
vector
<
double
>&
rzvalues
,
double
rzmin
,
double
rzmax
);
/**Destructor*/
~
OrderPositionsToStepVector
()
{}
private
:
/** Forbidden constructor */
OrderPositionsToStepVector
()
{}
};
inline
OrderPositionsToStepVector
::
OrderPositionsToStepVector
(
std
::
vector
<
double
>&
values
,
double
min
,
double
max
)
:
std
::
vector
<
double
>
(
values
.
size
())
{
unsigned
int
vectorSize
=
values
.
size
();
// sort the vector
sort
(
values
.
begin
(),
values
.
end
());
// first step - necessary because of correction of parsecLayerRmin
double
firstStep
=
fabs
(
0.5
*
(
values
[
1
]
+
values
[
0
])
-
min
);
double
lastValue
=
min
+
firstStep
;
push_back
(
firstStep
);
// all steps between second and one before last
for
(
unsigned
int
istep
=
2
;
istep
<
vectorSize
;
++
istep
)
{
double
currentStep
=
fabs
(
0.5
*
(
values
[
istep
]
+
values
[
istep
-
1
])
-
lastValue
);
push_back
(
currentStep
);
lastValue
+=
currentStep
;
}
// last step
push_back
(
fabs
(
max
-
0.5
*
(
values
[
vectorSize
-
2
]
+
values
[
vectorSize
-
1
])));
}
}
#endif
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