Skip to content

Commit 2e4c714

Browse files
Revert sincos change in GaussianRoughnessSampler
1 parent 0531ca4 commit 2e4c714

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/celeritas/optical/surface/GaussianRoughnessSampler.hh

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,9 +103,7 @@ CELER_FUNCTION Real3 GaussianRoughnessSampler::operator()(Engine& rng)
103103
// nonpositive slope are generally vanishingly small)
104104
alpha = std::fabs(sample_alpha_(rng));
105105
} while (alpha >= alpha_max_);
106-
sin_alpha = std::sin(alpha);
107-
cos_alpha = std::cos(alpha);
108-
// sincos(alpha, &sin_alpha, &cos_alpha);
106+
sincos(alpha, &sin_alpha, &cos_alpha);
109107

110108
// Transform to polar angle using rejection
111109
} while (RejectionSampler{sin_alpha, f_max_}(rng));

0 commit comments

Comments
 (0)