]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Qualify sind/cos/exp for std::
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Tue, 30 Apr 2002 10:53:12 +0000 (10:53 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Tue, 30 Apr 2002 10:53:12 +0000 (10:53 +0000)
git-svn-id: https://svn.dealii.org/trunk@5763 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/examples/step-13/step-13.cc

index 5065240e72a33c89e4429b4f0c90a97cc95aec5a..79439634460daa85561594152c16444c6a9ca1da 100644 (file)
@@ -1747,8 +1747,8 @@ Solution<dim>::value (const Point<dim>   &p,
 {
   double q = p(0);
   for (unsigned int i=1; i<dim; ++i)
-    q += sin(10*p(i)+5*p(0)*p(0));
-  const double exponential = exp(q);
+    q += std::sin(10*p(i)+5*p(0)*p(0));
+  const double exponential = std::exp(q);
   return exponential;
 };
 
@@ -1772,18 +1772,18 @@ RightHandSide<dim>::value (const Point<dim>   &p,
 {
   double q = p(0);
   for (unsigned int i=1; i<dim; ++i)
-    q += sin(10*p(i)+5*p(0)*p(0));
-  const double u = exp(q);
+    q += std::sin(10*p(i)+5*p(0)*p(0));
+  const double u = std::exp(q);
   double t1 = 1,
         t2 = 0,
         t3 = 0;
   for (unsigned int i=1; i<dim; ++i)
     {
-      t1 += cos(10*p(i)+5*p(0)*p(0)) * 10 * p(0);
-      t2 += 10*cos(10*p(i)+5*p(0)*p(0)) -
-           100*sin(10*p(i)+5*p(0)*p(0)) * p(0)*p(0);
-      t3 += 100*cos(10*p(i)+5*p(0)*p(0))*cos(10*p(i)+5*p(0)*p(0)) -
-           100*sin(10*p(i)+5*p(0)*p(0));
+      t1 += std::cos(10*p(i)+5*p(0)*p(0)) * 10 * p(0);
+      t2 += 10*std::cos(10*p(i)+5*p(0)*p(0)) -
+           100*std::sin(10*p(i)+5*p(0)*p(0)) * p(0)*p(0);
+      t3 += 100*std::cos(10*p(i)+5*p(0)*p(0))*std::cos(10*p(i)+5*p(0)*p(0)) -
+           100*std::sin(10*p(i)+5*p(0)*p(0));
     };
   t1 = t1*t1;
   

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.