From b4dee312a4667d5f33071629aec16f22eae04e68 Mon Sep 17 00:00:00 2001 From: Christopher Lackner Date: Tue, 5 Sep 2023 13:23:20 +0200 Subject: [PATCH] autodiff sqr in ngcore namespace --- libsrc/general/autodiff.hpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/libsrc/general/autodiff.hpp b/libsrc/general/autodiff.hpp index 10cf7a4f..c7f0e269 100644 --- a/libsrc/general/autodiff.hpp +++ b/libsrc/general/autodiff.hpp @@ -319,9 +319,9 @@ inline AutoDiff operator/ (double x, const AutoDiff & y) return x * Inv(y); } -} //namespace netgen +} // namespace netgen -namespace std +namespace ngcore { /// AutoDiff times AutoDiff template @@ -335,7 +335,10 @@ inline netgen::AutoDiff sqr (const netgen::AutoDiff & x) throw() res.DValue(i) = hx*x.DValue(i); return res; } +} // namespace ngcore +namespace std +{ template inline netgen::AutoDiff fabs (const netgen::AutoDiff & x) { @@ -349,8 +352,5 @@ inline netgen::AutoDiff fabs (const netgen::AutoDiff & x) res.DValue(i) = 0.0; return res; } - -} //namespace std -//@} - +} // namespace std #endif