]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Rename variable.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Tue, 29 Mar 2005 16:44:29 +0000 (16:44 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Tue, 29 Mar 2005 16:44:29 +0000 (16:44 +0000)
git-svn-id: https://svn.dealii.org/trunk@10292 0785d39b-7218-0410-832d-ea1e28bc413d

tests/base/symmetric_tensor_01.cc
tests/base/symmetric_tensor_02.cc

index f318a121c7f42fcf6b9beaab3ab26f74d161d22d..af3b19754c202d6748456ad93332582f4ee996ab 100644 (file)
@@ -26,30 +26,30 @@ int main ()
   deallog.attach(logfile);
   deallog.depth_console(0);
   
-  SymmetricTensor<2,2> t2;
-  t2[0][0] = 1;
-  t2[1][1] = 2;
-  t2[0][1] = 3;
+  SymmetricTensor<2,2> t;
+  t[0][0] = 1;
+  t[1][1] = 2;
+  t[0][1] = 3;
 
-  Assert (t2[0][1] == t2[1][0], ExcInternalError());
+  Assert (t[0][1] == t[1][0], ExcInternalError());
 
                                    // check that if a single element is
                                    // accessed, its transpose element gets the
                                    // same value
-  t2[1][0] = 4;
-  Assert (t2[0][1] == 4, ExcInternalError());
+  t[1][0] = 4;
+  Assert (t[0][1] == 4, ExcInternalError());
 
                                    // make sure transposition doesn't change
                                    // anything
-  Assert (t2 == transpose(t2), ExcInternalError());
+  Assert (t == transpose(t), ExcInternalError());
 
                                    // check norm of tensor
-  Assert (std::fabs(t2.norm() - std::sqrt(1.*1+2*2+2*4*4)) < 1e-14,
+  Assert (std::fabs(t.norm() - std::sqrt(1.*1+2*2+2*4*4)) < 1e-14,
           ExcInternalError());
 
                                    // make sure norm is induced by scalar
                                    // product
-  Assert (std::fabs (t2.norm()*t2.norm() - t2*t2) < 1e-14,
+  Assert (std::fabs (t.norm()*t.norm() - t*t) < 1e-14,
           ExcInternalError());
 
   deallog << "OK" << std::endl;
index 72c71a232f2a56481b6962bd50a02b4651348f8a..1ba67ea8706e78079033dc8201b58727c593c166 100644 (file)
@@ -26,34 +26,34 @@ int main ()
   deallog.attach(logfile);
   deallog.depth_console(0);
   
-  SymmetricTensor<2,3> t3;
-  t3[0][0] = 1;
-  t3[1][1] = 2;
-  t3[2][2] = 3;
-  t3[0][1] = 4;
-  t3[0][2] = 5;
-  t3[1][2] = 6;
+  SymmetricTensor<2,3> t;
+  t[0][0] = 1;
+  t[1][1] = 2;
+  t[2][2] = 3;
+  t[0][1] = 4;
+  t[0][2] = 5;
+  t[1][2] = 6;
 
-  Assert (t3[0][1] == t3[1][0], ExcInternalError());
+  Assert (t[0][1] == t[1][0], ExcInternalError());
 
                                    // check that if a single element is
                                    // accessed, its transpose element gets the
                                    // same value
-  t3[1][0] = 14;
-  Assert (t3[0][1] == 14, ExcInternalError());
+  t[1][0] = 14;
+  Assert (t[0][1] == 14, ExcInternalError());
 
                                    // make sure transposition doesn't change
                                    // anything
-  Assert (t3 == transpose(t3), ExcInternalError());
+  Assert (t == transpose(t), ExcInternalError());
 
                                    // check norm of tensor
-  Assert (std::fabs(t3.norm() - std::sqrt(1.*1+2*2+3*3+2*14*14+2*5*5+2*6*6))
+  Assert (std::fabs(t.norm() - std::sqrt(1.*1+2*2+3*3+2*14*14+2*5*5+2*6*6))
           < 1e-14,
           ExcInternalError());
 
                                    // make sure norm is induced by scalar
                                    // product
-  Assert (std::fabs (t3.norm()*t3.norm() - t3*t3) < 1e-14,
+  Assert (std::fabs (t.norm()*t.norm() - t*t) < 1e-14,
           ExcInternalError());
 
   deallog << "OK" << std::endl;

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.