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
b79afd57
Commit
b79afd57
authored
2 years ago
by
Wuttke, Joachim
Browse files
Options
Downloads
Patches
Plain Diff
clang-format
parent
3f0880b4
No related branches found
No related tags found
1 merge request
!913
cleanup and simplification in specular scan context
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
Resample/Element/SpecularElement.cpp
+7
-8
7 additions, 8 deletions
Resample/Element/SpecularElement.cpp
Sim/Scan/AlphaScan.cpp
+2
-3
2 additions, 3 deletions
Sim/Scan/AlphaScan.cpp
Sim/Scan/QzScan.cpp
+2
-2
2 additions, 2 deletions
Sim/Scan/QzScan.cpp
with
11 additions
and
13 deletions
Resample/Element/SpecularElement.cpp
+
7
−
8
View file @
b79afd57
...
@@ -16,17 +16,16 @@
...
@@ -16,17 +16,16 @@
#include
"Base/Vector/Direction.h"
#include
"Base/Vector/Direction.h"
#include
"Resample/Slice/KzComputation.h"
#include
"Resample/Slice/KzComputation.h"
SpecularElement
SpecularElement
::
FromQzScan
(
SpecularElement
SpecularElement
::
FromQzScan
(
double
kz
,
const
PolMatrices
&
polMatrices
,
double
kz
,
const
PolMatrices
&
polMatrices
,
bool
computable
)
bool
computable
)
{
{
return
SpecularElement
(
computable
,
polMatrices
,
return
SpecularElement
(
computable
,
polMatrices
,
[
kz
](
const
SliceStack
&
slices
)
{
[
kz
](
const
SliceStack
&
slices
)
{
return
Compute
::
Kz
::
computeKzFromSLDs
(
slices
,
kz
);
return
Compute
::
Kz
::
computeKzFromSLDs
(
slices
,
kz
);
});
});
}
}
SpecularElement
SpecularElement
::
FromAlphaScan
(
SpecularElement
SpecularElement
::
FromAlphaScan
(
double
wavelength
,
double
alpha
,
double
wavelength
,
double
alpha
,
const
PolMatrices
&
polMatrices
,
bool
computable
)
const
PolMatrices
&
polMatrices
,
bool
computable
)
{
{
return
SpecularElement
(
return
SpecularElement
(
computable
,
polMatrices
,
computable
,
polMatrices
,
...
...
This diff is collapsed.
Click to expand it.
Sim/Scan/AlphaScan.cpp
+
2
−
3
View file @
b79afd57
...
@@ -101,9 +101,8 @@ std::vector<SpecularElement> AlphaScan::generateElements() const
...
@@ -101,9 +101,8 @@ std::vector<SpecularElement> AlphaScan::generateElements() const
const
double
inc
=
incs
[
i
][
k
];
const
double
inc
=
incs
[
i
][
k
];
for
(
size_t
j
=
0
,
size_wls
=
wls
[
i
].
size
();
j
<
size_wls
;
++
j
)
{
for
(
size_t
j
=
0
,
size_wls
=
wls
[
i
].
size
();
j
<
size_wls
;
++
j
)
{
const
double
wl
=
wls
[
i
][
j
];
const
double
wl
=
wls
[
i
][
j
];
result
.
emplace_back
(
result
.
emplace_back
(
SpecularElement
::
FromAlphaScan
(
SpecularElement
::
FromAlphaScan
(
wl
,
-
inc
,
polMatrices
(),
wl
>=
0
&&
inc
>=
0
&&
inc
<=
M_PI_2
));
wl
,
-
inc
,
polMatrices
(),
wl
>=
0
&&
inc
>=
0
&&
inc
<=
M_PI_2
));
}
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Sim/Scan/QzScan.cpp
+
2
−
2
View file @
b79afd57
...
@@ -66,8 +66,8 @@ std::vector<SpecularElement> QzScan::generateElements() const
...
@@ -66,8 +66,8 @@ std::vector<SpecularElement> QzScan::generateElements() const
std
::
vector
<
SpecularElement
>
result
;
std
::
vector
<
SpecularElement
>
result
;
result
.
reserve
(
qz
.
size
());
result
.
reserve
(
qz
.
size
());
for
(
size_t
i
=
0
,
size
=
qz
.
size
();
i
<
size
;
++
i
)
for
(
size_t
i
=
0
,
size
=
qz
.
size
();
i
<
size
;
++
i
)
result
.
emplace_back
(
SpecularElement
::
FromQzScan
(
result
.
emplace_back
(
-
(
qz
[
i
]
+
m_offset
)
/
2.0
,
polMatrices
(),
qz
[
i
]
>=
0
));
SpecularElement
::
FromQzScan
(
-
(
qz
[
i
]
+
m_offset
)
/
2.0
,
polMatrices
(),
qz
[
i
]
>=
0
));
return
result
;
return
result
;
}
}
...
...
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