point.C
Go to the documentation of this file.
1 // The libMesh Finite Element Library.
2 // Copyright (C) 2002-2018 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner
3 
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License, or (at your option) any later version.
8 
9 // This library is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
13 
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 
18 
19 
20 
21 // C++ includes
22 
23 // Local includes
24 // #include "libmesh/point.h"
25 
26 
27 
28 
29 // ------------------------------------------------------------
30 // Point class member functions
31 // unsigned int Point::key() const
32 // {
33 // unsigned int tempx,tempy,tempz;
34 
35 // int i,j=2,cnt=0;
36 // unsigned int index[3];
37 // const Real deg = 1.e12;
38 
39 // tempx = static_cast<unsigned int>(((*this)(0)*deg));
40 // tempy = static_cast<unsigned int>(((*this)(1)*deg));
41 // tempz = static_cast<unsigned int>(((*t!his)(2)*deg));
42 
43 // index[0]=0;
44 // index[1]=0;
45 // index[2]=0;
46 
47 // for (i=sizeof(unsigned int)*8-1;i>=0;i--)
48 // {
49 // index[j] += (tempx >> i) & 01;
50 // index[j] = index[j] << 01;
51 
52 // if (( cnt % (sizeof(unsigned int)*8) == 0) && (cnt !=0 ) )
53 // {
54 // cnt = 0;
55 // j--;
56 // }
57 // else
58 // cnt++;
59 
60 // index[j] += (tempy >> i) & 01;
61 // index[j] = index[j] << 01;
62 
63 // if (( cnt % (sizeof(unsigned int)*8) == 0) && (cnt !=0 ) )
64 // {
65 // cnt = 0;
66 // j--;
67 // }
68 // else
69 // cnt++;
70 
71 // index[j] += (tempz >> i) & 01;
72 // index[j] = index[j] << 01;
73 
74 // if (( cnt % (sizeof(unsigned int)*8) == 0) && (cnt !=0 ) )
75 // {
76 // cnt = 0;
77 // j--;
78 // }
79 // else
80 // cnt++;
81 // }
82 
83 // return index[2];
84 // }