34 return (X0 + L/
double(globals.max_length) *
double(X));
39 return (Y0 + L/
double(globals.max_length) *
double(Y));
44 return (Z0 + L/
double(globals.max_length) *
double(Z));
49 return (uint32_t)(double(globals.max_length)/L * (X - X0));
54 return (uint32_t)(double(globals.max_length)/L * (Y - Y0));
59 return (uint32_t)(double(globals.max_length)/L * (Z - Z0));
64 return ((L/
double(globals.max_length))*
double(size));
69 return ((pow(L,2.0)/pow(
double(globals.max_length),2.0))*
double(Area));
74 return ((pow(L,3.0)/pow(
double(globals.max_length),3.0))*
double(Volume));
79 vector<double> & mapcenter){
84 #if defined(__INTEL_COMPILER) || defined(__ICC)
90 for (
int i=0; i<dim; i++){
91 mapcenter[i] = mapcenter[i] + L/double(globals.max_length) * center[i];
93 #if defined(__INTEL_COMPILER) || defined(__ICC)
95 mapcenter.shrink_to_fit();
101 vector<double> & mapcenter){
106 #if defined(__INTEL_COMPILER) || defined(__ICC)
108 orig.shrink_to_fit();
112 for (
int i=0; i<dim; i++){
113 mapcenter[i] = mapcenter[i] + L/double(globals.max_length) * center[i];
115 #if defined(__INTEL_COMPILER) || defined(__ICC)
117 mapcenter.shrink_to_fit();
123 vector<vector<double> > & mapnodes){
128 #if defined(__INTEL_COMPILER) || defined(__ICC)
130 orig.shrink_to_fit();
132 mapnodes.resize(globals.nnodes);
133 for (
int i=0; i<globals.nnodes; i++){
134 mapnodes[i].resize(3);
135 for (
int j=0; j<3; j++){
136 mapnodes[i][j] = orig[j] + L/double(globals.max_length) * double(nodes[i][j]);
138 #if defined(__INTEL_COMPILER) || defined(__ICC)
140 mapnodes[i].shrink_to_fit();
143 #if defined(__INTEL_COMPILER) || defined(__ICC)
145 mapnodes.shrink_to_fit();
152 vector<vector<double> > & mapnodes){
157 #if defined(__INTEL_COMPILER) || defined(__ICC)
159 orig.shrink_to_fit();
161 mapnodes.resize(globals.nnodes);
162 for (
int i=0; i<globals.nnodes; i++){
163 mapnodes[i].resize(3);
164 for (
int j=0; j<3; j++){
165 mapnodes[i][j] = orig[j] + L/double(globals.max_length) * double(nodes[i][j]);
167 #if defined(__INTEL_COMPILER) || defined(__ICC)
169 mapnodes[i].shrink_to_fit();
172 #if defined(__INTEL_COMPILER) || defined(__ICC)
174 mapnodes.shrink_to_fit();
180 vector<double> & mapnode){
185 #if defined(__INTEL_COMPILER) || defined(__ICC)
187 orig.shrink_to_fit();
190 for (
int j=0; j<3; j++){
191 mapnode[j] = orig[j] + L/double(globals.max_length) * double(node[j]);
198 vector<vector<double> > & mapnodes){
203 #if defined(__INTEL_COMPILER) || defined(__ICC)
205 orig.shrink_to_fit();
207 mapnodes.resize(globals.nnodesperface);
208 for (
int i=0; i<globals.nnodesperface; i++){
209 mapnodes[i].resize(3);
210 for (
int j=0; j<3; j++){
211 mapnodes[i][j] = orig[j] + L/double(globals.max_length) * double(nodes[i][j]);
213 #if defined(__INTEL_COMPILER) || defined(__ICC)
215 mapnodes[i].shrink_to_fit();
218 #if defined(__INTEL_COMPILER) || defined(__ICC)
220 mapnodes.shrink_to_fit();
226 vector<vector<double> > & mapnodes){
231 #if defined(__INTEL_COMPILER) || defined(__ICC)
233 orig.shrink_to_fit();
235 mapnodes.resize(globals.nnodesperface);
236 for (
int i=0; i<globals.nnodesperface; i++){
237 mapnodes[i].resize(3);
238 for (
int j=0; j<3; j++){
239 mapnodes[i][j] = orig[j] + L/double(globals.max_length) * double(nodes[i][j]);
241 #if defined(__INTEL_COMPILER) || defined(__ICC)
243 mapnodes[i].shrink_to_fit();
246 #if defined(__INTEL_COMPILER) || defined(__ICC)
248 mapnodes.shrink_to_fit();
254 vector<double> & mapnormal){
255 mapnormal = vector<double>(normal.begin(), normal.end());
256 #if defined(__INTEL_COMPILER) || defined(__ICC)
258 mapnormal.shrink_to_fit();
double mapSize(uint32_t const &size)
double mapArea(uint64_t const &area)
void mapNodesIntersection(uint32_t(*nodes)[3], vector< vector< double > > &mapnodes)
void mapCenter(double *¢er, vector< double > &mapcenter)
void mapNodes(uint32_t(*nodes)[3], vector< vector< double > > &mapnodes)
void mapNode(vector< uint32_t > &node, vector< double > &mapnode)
void mapNormals(vector< int8_t > normal, vector< double > &mapnormal)
double mapX(uint32_t const &X)
double mapZ(uint32_t const &Z)
double mapVolume(uint64_t const &volume)
double mapY(uint32_t const &Y)