Nektar++
MappingXYofXY.cpp
Go to the documentation of this file.
1///////////////////////////////////////////////////////////////////////////////
2//
3// File: MappingXYofXY.cpp
4//
5// For more information, please see: http://www.nektar.info
6//
7// The MIT License
8//
9// Copyright (c) 2006 Division of Applied Mathematics, Brown University (USA),
10// Department of Aeronautics, Imperial College London (UK), and Scientific
11// Computing and Imaging Institute, University of Utah (USA).
12//
13// Permission is hereby granted, free of charge, to any person obtaining a
14// copy of this software and associated documentation files (the "Software"),
15// to deal in the Software without restriction, including without limitation
16// the rights to use, copy, modify, merge, publish, distribute, sublicense,
17// and/or sell copies of the Software, and to permit persons to whom the
18// Software is furnished to do so, subject to the following conditions:
19//
20// The above copyright notice and this permission notice shall be included
21// in all copies or substantial portions of the Software.
22//
23// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
24// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
26// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
28// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
29// DEALINGS IN THE SOFTWARE.
30//
31// Description: Mapping of the type X = X(x,y), Y = Y(x,y)
32//
33///////////////////////////////////////////////////////////////////////////////
34
37
38namespace Nektar
39{
40namespace GlobalMapping
41{
42
43std::string MappingXYofXY::className =
45 "X = X(x,y), Y = Y(x,y)");
46
47/**
48 * @class MappingXYofXY
49 * This class implements a mapping defined by the transformation
50 * \f[ \bar{x} = \bar{x}(x,y) \f]
51 * \f[ \bar{y} = \bar{y}(x,y) \f]
52 * \f[ \bar{z} = z \f]
53 * where \f$(\bar{x},\bar{y},\bar{z})\f$ are the Cartesian (physical)
54 * coordinates and \f$(x,y,z)\f$ are the transformed (computational)
55 * coordinates.
56 */
60 : Mapping(pSession, pFields)
61{
62}
63
64/**
65 *
66 */
69 const TiXmlElement *pMapping)
70{
71 Mapping::v_InitObject(pFields, pMapping);
72
73 m_constantJacobian = false;
74
76 "Mapping X = X(x,y), Y = Y(x,y) needs 2 velocity components.");
77}
78
80 const Array<OneD, Array<OneD, NekDouble>> &inarray,
82{
83 int physTot = m_fields[0]->GetTotPoints();
84
85 // U1 = fx*u1 + fy*u2
86 Vmath::Vmul(physTot, m_GeometricInfo[0], 1, inarray[0], 1, outarray[0], 1);
87 Vmath::Vvtvp(physTot, m_GeometricInfo[1], 1, inarray[1], 1, outarray[0], 1,
88 outarray[0], 1);
89
90 // U2 = gx*u1+gy*u2
91 Vmath::Vmul(physTot, m_GeometricInfo[2], 1, inarray[0], 1, outarray[1], 1);
92 Vmath::Vvtvp(physTot, m_GeometricInfo[3], 1, inarray[1], 1, outarray[1], 1,
93 outarray[1], 1);
94
95 // U3 = u3
96 if (m_nConvectiveFields == 3)
97 {
98 Vmath::Vcopy(physTot, inarray[2], 1, outarray[2], 1);
99 }
100}
101
103 const Array<OneD, Array<OneD, NekDouble>> &inarray,
105{
106 int physTot = m_fields[0]->GetTotPoints();
107 Array<OneD, NekDouble> wk(physTot, 0.0);
108
109 // U1 = [gy*u1-gx*u2]/(fx*gy-gx*fy)
110 Vmath::Vmul(physTot, inarray[1], 1, m_GeometricInfo[2], 1, outarray[0], 1);
111 Vmath::Vvtvm(physTot, inarray[0], 1, m_GeometricInfo[3], 1, outarray[0], 1,
112 outarray[0], 1);
113 Vmath::Vdiv(physTot, outarray[0], 1, m_GeometricInfo[4], 1, outarray[0], 1);
114
115 // U2 = [fx*u2 - fy*u1]/(fx*gy-gx*fy)
116 Vmath::Vmul(physTot, inarray[0], 1, m_GeometricInfo[1], 1, outarray[1], 1);
117 Vmath::Vvtvm(physTot, inarray[1], 1, m_GeometricInfo[0], 1, outarray[1], 1,
118 outarray[1], 1);
119 Vmath::Vdiv(physTot, outarray[1], 1, m_GeometricInfo[4], 1, outarray[1], 1);
120
121 // U3 = u3
122 if (m_nConvectiveFields == 3)
123 {
124 Vmath::Vcopy(physTot, inarray[2], 1, outarray[2], 1);
125 }
126}
127
129 const Array<OneD, Array<OneD, NekDouble>> &inarray,
131{
132 int physTot = m_fields[0]->GetTotPoints();
133 Array<OneD, NekDouble> wk(physTot, 0.0);
134
135 // U1 = [gy*u1-fy*u2]/(fx*gy-gx*fy)
136 Vmath::Vmul(physTot, inarray[1], 1, m_GeometricInfo[1], 1, outarray[0], 1);
137 Vmath::Vvtvm(physTot, inarray[0], 1, m_GeometricInfo[3], 1, outarray[0], 1,
138 outarray[0], 1);
139 Vmath::Vdiv(physTot, outarray[0], 1, m_GeometricInfo[4], 1, outarray[0], 1);
140
141 // U2 = [fx*u2-gx*u1]/(fx*gy-gx*fy)
142 Vmath::Vmul(physTot, inarray[0], 1, m_GeometricInfo[2], 1, outarray[1], 1);
143 Vmath::Vvtvm(physTot, inarray[1], 1, m_GeometricInfo[0], 1, outarray[1], 1,
144 outarray[1], 1);
145 Vmath::Vdiv(physTot, outarray[1], 1, m_GeometricInfo[4], 1, outarray[1], 1);
146
147 // U3 = u3
148 if (m_nConvectiveFields == 3)
149 {
150 Vmath::Vcopy(physTot, inarray[2], 1, outarray[2], 1);
151 }
152}
153
155 const Array<OneD, Array<OneD, NekDouble>> &inarray,
157{
158 int physTot = m_fields[0]->GetTotPoints();
159
160 // U1 = u1*fx +gx*u2
161 Vmath::Vmul(physTot, m_GeometricInfo[0], 1, inarray[0], 1, outarray[0], 1);
162 Vmath::Vvtvp(physTot, m_GeometricInfo[2], 1, inarray[1], 1, outarray[0], 1,
163 outarray[0], 1);
164
165 // U2 = fy*u1 + gy*u2
166 Vmath::Vmul(physTot, m_GeometricInfo[1], 1, inarray[0], 1, outarray[1], 1);
167 Vmath::Vvtvp(physTot, m_GeometricInfo[3], 1, inarray[1], 1, outarray[1], 1,
168 outarray[1], 1);
169
170 // U3 = u3
171 if (m_nConvectiveFields == 3)
172 {
173 Vmath::Vcopy(physTot, inarray[2], 1, outarray[2], 1);
174 }
175}
176
178{
179 int physTot = m_fields[0]->GetTotPoints();
180 Vmath::Vabs(physTot, m_GeometricInfo[4], 1, outarray, 1);
181}
182
185{
186 int physTot = m_fields[0]->GetTotPoints();
187 int nvel = m_nConvectiveFields;
188
189 for (int i = 0; i < nvel * nvel; i++)
190 {
191 outarray[i] = Array<OneD, NekDouble>(physTot, 0.0);
192 }
193
194 // g_{1,1} = m_metricTensor[0]
195 Vmath::Vcopy(physTot, m_metricTensor[0], 1, outarray[0 * nvel + 0], 1);
196
197 // g_{2,2} = m_metricTensor[1]
198 Vmath::Vcopy(physTot, m_metricTensor[1], 1, outarray[1 * nvel + 1], 1);
199
200 // g_{1,2}=g{2,1} = m_metricTensor[2]
201 Vmath::Vcopy(physTot, m_metricTensor[2], 1, outarray[0 * nvel + 1], 1);
202 Vmath::Vcopy(physTot, m_metricTensor[2], 1, outarray[1 * nvel + 0], 1);
203
204 // g_{3,3} = 1
205 if (m_nConvectiveFields == 3)
206 {
207 Vmath::Sadd(physTot, 1.0, outarray[2 * nvel + 2], 1,
208 outarray[2 * nvel + 2], 1);
209 }
210}
211
214{
215 int physTot = m_fields[0]->GetTotPoints();
216 int nvel = m_nConvectiveFields;
217
218 for (int i = 0; i < nvel * nvel; i++)
219 {
220 outarray[i] = Array<OneD, NekDouble>(physTot, 0.0);
221 }
222
223 // Get Jacobian
224 Array<OneD, NekDouble> Jac(physTot, 0.0);
225 GetJacobian(Jac);
226
227 // Get Jacobian squared
228 Array<OneD, NekDouble> wk(physTot, 0.0);
229 Vmath::Vmul(physTot, Jac, 1, Jac, 1, wk, 1);
230 // G^{1,1} = m_metricTensor[1]/Jac^2
231 Vmath::Vcopy(physTot, m_metricTensor[1], 1, outarray[0 * nvel + 0], 1);
232 Vmath::Vdiv(physTot, outarray[0 * nvel + 0], 1, wk, 1,
233 outarray[0 * nvel + 0], 1);
234
235 // G^{2,2} = m_metricTensor[0]/Jac^2
236 Vmath::Vcopy(physTot, m_metricTensor[0], 1, outarray[1 * nvel + 1], 1);
237 Vmath::Vdiv(physTot, outarray[1 * nvel + 1], 1, wk, 1,
238 outarray[1 * nvel + 1], 1);
239
240 // G^{1,2} = G^{2,1} = -m_metricTensor[2]/Jac^2
241 Vmath::Vcopy(physTot, m_metricTensor[2], 1, outarray[0 * nvel + 1], 1);
242 Vmath::Neg(physTot, outarray[0 * nvel + 1], 1);
243 Vmath::Vdiv(physTot, outarray[0 * nvel + 1], 1, wk, 1,
244 outarray[0 * nvel + 1], 1);
245 Vmath::Vcopy(physTot, outarray[0 * nvel + 1], 1, outarray[1 * nvel + 0], 1);
246
247 // G^{3,3} = 1
248 if (m_nConvectiveFields == 3)
249 {
250 Vmath::Sadd(physTot, 1.0, outarray[2 * nvel + 2], 1,
251 outarray[2 * nvel + 2], 1);
252 }
253}
254
256 const Array<OneD, Array<OneD, NekDouble>> &inarray,
258{
259 int physTot = m_fields[0]->GetTotPoints();
260 int nvel = m_nConvectiveFields;
261
262 for (int i = 0; i < nvel; i++)
263 {
264 for (int j = 0; j < nvel; j++)
265 {
266 outarray[i * nvel + j] = Array<OneD, NekDouble>(physTot, 0.0);
267 }
268 }
269
270 // Calculate non-zero terms
271
272 // outarray(0,0) = U1 * m_Christoffel[0] + U2 * m_Christoffel[1]
273 Vmath::Vmul(physTot, m_Christoffel[0], 1, inarray[0], 1,
274 outarray[0 * nvel + 0], 1);
275 Vmath::Vvtvp(physTot, m_Christoffel[1], 1, inarray[1], 1,
276 outarray[0 * nvel + 0], 1, outarray[0 * nvel + 0], 1);
277
278 // outarray(0,1) = U1 * m_Christoffel[1] + U2 * m_Christoffel[2]
279 Vmath::Vmul(physTot, m_Christoffel[1], 1, inarray[0], 1,
280 outarray[0 * nvel + 1], 1);
281 Vmath::Vvtvp(physTot, m_Christoffel[2], 1, inarray[1], 1,
282 outarray[0 * nvel + 1], 1, outarray[0 * nvel + 1], 1);
283
284 // outarray(1,0) = U1 * m_Christoffel[3] + U2 * m_Christoffel[4]
285 Vmath::Vmul(physTot, m_Christoffel[3], 1, inarray[0], 1,
286 outarray[1 * nvel + 0], 1);
287 Vmath::Vvtvp(physTot, m_Christoffel[4], 1, inarray[1], 1,
288 outarray[1 * nvel + 0], 1, outarray[1 * nvel + 0], 1);
289
290 // outarray(1,1) = U1 * m_Christoffel[4] + U2 * m_Christoffel[5]
291 Vmath::Vmul(physTot, m_Christoffel[4], 1, inarray[0], 1,
292 outarray[1 * nvel + 1], 1);
293 Vmath::Vvtvp(physTot, m_Christoffel[5], 1, inarray[1], 1,
294 outarray[1 * nvel + 1], 1, outarray[1 * nvel + 1], 1);
295}
296
298 const Array<OneD, Array<OneD, NekDouble>> &inarray,
300{
301 int physTot = m_fields[0]->GetTotPoints();
302 int nvel = m_nConvectiveFields;
303
304 for (int i = 0; i < nvel; i++)
305 {
306 for (int j = 0; j < nvel; j++)
307 {
308 outarray[i * nvel + j] = Array<OneD, NekDouble>(physTot, 0.0);
309 }
310 }
311
312 // Calculate non-zero terms
313
314 // outarray(0,0) = U1 * m_Christoffel[0] + U2 * m_Christoffel[3]
315 Vmath::Vmul(physTot, m_Christoffel[0], 1, inarray[0], 1,
316 outarray[0 * nvel + 0], 1);
317 Vmath::Vvtvp(physTot, m_Christoffel[3], 1, inarray[1], 1,
318 outarray[0 * nvel + 0], 1, outarray[0 * nvel + 0], 1);
319
320 // outarray(0,1) = U1 * m_Christoffel[1] + U2 * m_Christoffel[4]
321 Vmath::Vmul(physTot, m_Christoffel[1], 1, inarray[0], 1,
322 outarray[0 * nvel + 1], 1);
323 Vmath::Vvtvp(physTot, m_Christoffel[4], 1, inarray[1], 1,
324 outarray[0 * nvel + 1], 1, outarray[0 * nvel + 1], 1);
325
326 // outarray(1,0) = U1 * m_Christoffel[1] + U2 * m_Christoffel[4]
327 Vmath::Vmul(physTot, m_Christoffel[1], 1, inarray[0], 1,
328 outarray[1 * nvel + 0], 1);
329 Vmath::Vvtvp(physTot, m_Christoffel[4], 1, inarray[1], 1,
330 outarray[1 * nvel + 0], 1, outarray[1 * nvel + 0], 1);
331
332 // outarray(1,1) = U1 * m_Christoffel[2] + U2 * m_Christoffel[5]
333 Vmath::Vmul(physTot, m_Christoffel[2], 1, inarray[0], 1,
334 outarray[1 * nvel + 1], 1);
335 Vmath::Vvtvp(physTot, m_Christoffel[5], 1, inarray[1], 1,
336 outarray[1 * nvel + 1], 1, outarray[1 * nvel + 1], 1);
337}
338
340{
341 int phystot = m_fields[0]->GetTotPoints();
342 // Allocation of geometry memory
344 for (int i = 0; i < m_GeometricInfo.size(); i++)
345 {
346 m_GeometricInfo[i] = Array<OneD, NekDouble>(phystot, 0.0);
347 }
348
349 bool waveSpace = m_fields[0]->GetWaveSpace();
350 m_fields[0]->SetWaveSpace(false);
351
352 // Calculate derivatives of x transformation --> m_GeometricInfo 0-1
354 m_GeometricInfo[0]);
356 m_GeometricInfo[1]);
357
358 // Calculate derivatives of y transformation m_GeometricInfo 2-3
360 m_GeometricInfo[2]);
362 m_GeometricInfo[3]);
363
364 // Calculate fx*gy-gx*fy --> m_GeometricInfo4
365 Vmath::Vmul(phystot, m_GeometricInfo[1], 1, m_GeometricInfo[2], 1,
366 m_GeometricInfo[4], 1);
367 Vmath::Vvtvm(phystot, m_GeometricInfo[0], 1, m_GeometricInfo[3], 1,
368 m_GeometricInfo[4], 1, m_GeometricInfo[4], 1);
369 //
372
373 m_fields[0]->SetWaveSpace(waveSpace);
374}
375
377{
378 int physTot = m_fields[0]->GetTotPoints();
379 // Allocate memory
381 for (int i = 0; i < m_metricTensor.size(); i++)
382 {
383 m_metricTensor[i] = Array<OneD, NekDouble>(physTot, 0.0);
384 }
385 // g_{1,1} = fx^2+gx^2
386 Vmath::Vmul(physTot, m_GeometricInfo[0], 1, m_GeometricInfo[0], 1,
387 m_metricTensor[0], 1);
388 Vmath::Vvtvp(physTot, m_GeometricInfo[2], 1, m_GeometricInfo[2], 1,
389 m_metricTensor[0], 1, m_metricTensor[0], 1);
390 // g_{2,2} = fy^2+gy^2
391 Vmath::Vmul(physTot, m_GeometricInfo[1], 1, m_GeometricInfo[1], 1,
392 m_metricTensor[1], 1);
393 Vmath::Vvtvp(physTot, m_GeometricInfo[3], 1, m_GeometricInfo[3], 1,
394 m_metricTensor[1], 1, m_metricTensor[1], 1);
395 // g_{1,2} = g_{2,1} = fy*fx+gx*gy
396 Vmath::Vmul(physTot, m_GeometricInfo[0], 1, m_GeometricInfo[1], 1,
397 m_metricTensor[2], 1);
398 Vmath::Vvtvp(physTot, m_GeometricInfo[2], 1, m_GeometricInfo[3], 1,
399 m_metricTensor[2], 1, m_metricTensor[2], 1);
400}
401
403{
404 int physTot = m_fields[0]->GetTotPoints();
405 int nvel = m_nConvectiveFields;
406
408 Array<OneD, Array<OneD, NekDouble>> G_inv(nvel * nvel);
409 Array<OneD, Array<OneD, NekDouble>> gradG(2 * 2 * 2);
412 // Allocate memory
413 for (int i = 0; i < gradG.size(); i++)
414 {
415 gradG[i] = Array<OneD, NekDouble>(physTot, 0.0);
416 tmp[i] = Array<OneD, NekDouble>(physTot, 0.0);
417 }
418 for (int i = 0; i < G.size(); i++)
419 {
420 G[i] = Array<OneD, NekDouble>(physTot, 0.0);
421 G_inv[i] = Array<OneD, NekDouble>(physTot, 0.0);
422 }
423
424 // Get the metric tensor and its inverse
426 GetInvMetricTensor(G_inv);
427
428 bool waveSpace = m_fields[0]->GetWaveSpace();
429 m_fields[0]->SetWaveSpace(false);
430 // Calculate gradients of g
431 // consider only 2 dimensions, since the 3rd is trivial
432 for (int i = 0; i < 2; i++)
433 {
434 for (int j = 0; j < 2; j++)
435 {
436 for (int k = 0; k < 2; k++)
437 {
439 G[i * nvel + j],
440 gradG[i * 2 * 2 + j * 2 + k]);
441 }
442 }
443 }
444
445 // Calculate tmp[p,j,k] = 1/2( gradG[pj,k]+ gradG[pk,j]-gradG[jk,p])
446 for (int p = 0; p < 2; p++)
447 {
448 for (int j = 0; j < 2; j++)
449 {
450 for (int k = 0; k < 2; k++)
451 {
452 Vmath::Vadd(physTot, gradG[p * 2 * 2 + j * 2 + k], 1,
453 gradG[p * 2 * 2 + k * 2 + j], 1,
454 tmp[p * 2 * 2 + j * 2 + k], 1);
455 Vmath::Vsub(physTot, tmp[p * 2 * 2 + j * 2 + k], 1,
456 gradG[j * 2 * 2 + k * 2 + p], 1,
457 tmp[p * 2 * 2 + j * 2 + k], 1);
458 Vmath::Smul(physTot, 0.5, tmp[p * 2 * 2 + j * 2 + k], 1,
459 tmp[p * 2 * 2 + j * 2 + k], 1);
460 }
461 }
462 }
463
464 // Calculate Christoffel symbols = g^ip tmp[p,j,k]
465 int n = 0;
466 for (int i = 0; i < 2; i++)
467 {
468 for (int j = 0; j < 2; j++)
469 {
470 for (int k = 0; k <= j; k++)
471 {
472 m_Christoffel[n] = Array<OneD, NekDouble>(physTot, 0.0);
473 for (int p = 0; p < 2; p++)
474 {
475 Vmath::Vvtvp(physTot, G_inv[i * nvel + p], 1,
476 tmp[p * 2 * 2 + j * 2 + k], 1,
477 m_Christoffel[n], 1, m_Christoffel[n], 1);
478 }
479 n = n + 1;
480 }
481 }
482 }
483
484 m_fields[0]->SetWaveSpace(waveSpace);
485}
486
487} // namespace GlobalMapping
488} // namespace Nektar
#define ASSERTL0(condition, msg)
Definition: ErrorUtil.hpp:215
Base class for mapping to be applied to the coordinate system.
Definition: Mapping.h:69
int m_nConvectiveFields
Number of velocity components.
Definition: Mapping.h:414
GLOBAL_MAPPING_EXPORT void GetInvMetricTensor(Array< OneD, Array< OneD, NekDouble > > &outarray)
Get the inverse of metric tensor .
Definition: Mapping.h:184
Array< OneD, Array< OneD, NekDouble > > m_GeometricInfo
Array with metric terms of the mapping.
Definition: Mapping.h:412
Array< OneD, Array< OneD, NekDouble > > m_coords
Array with the Cartesian coordinates.
Definition: Mapping.h:408
Array< OneD, MultiRegions::ExpListSharedPtr > m_fields
Definition: Mapping.h:406
GLOBAL_MAPPING_EXPORT void GetMetricTensor(Array< OneD, Array< OneD, NekDouble > > &outarray)
Get the metric tensor .
Definition: Mapping.h:177
GLOBAL_MAPPING_EXPORT void GetJacobian(Array< OneD, NekDouble > &outarray)
Get the Jacobian of the transformation.
Definition: Mapping.h:155
virtual GLOBAL_MAPPING_EXPORT void v_InitObject(const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const TiXmlElement *pMapping)
Definition: Mapping.cpp:101
bool m_constantJacobian
Flag defining if the Jacobian is constant.
Definition: Mapping.h:423
static std::string className
Name of the class.
Definition: MappingXYofXY.h:70
virtual GLOBAL_MAPPING_EXPORT void v_CovarToCartesian(const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray) override
static GLOBAL_MAPPING_EXPORT MappingSharedPtr create(const LibUtilities::SessionReaderSharedPtr &pSession, const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const TiXmlElement *pMapping)
Creates an instance of this class.
Definition: MappingXYofXY.h:58
virtual GLOBAL_MAPPING_EXPORT void v_ApplyChristoffelCovar(const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray) override
MappingXYofXY(const LibUtilities::SessionReaderSharedPtr &pSession, const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields)
Array< OneD, Array< OneD, NekDouble > > m_metricTensor
Definition: MappingXYofXY.h:79
Array< OneD, Array< OneD, NekDouble > > m_Christoffel
Definition: MappingXYofXY.h:80
virtual GLOBAL_MAPPING_EXPORT void v_GetMetricTensor(Array< OneD, Array< OneD, NekDouble > > &outarray) override
virtual GLOBAL_MAPPING_EXPORT void v_ApplyChristoffelContravar(const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray) override
virtual GLOBAL_MAPPING_EXPORT void v_UpdateGeomInfo() override
virtual GLOBAL_MAPPING_EXPORT void v_CovarFromCartesian(const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray) override
virtual GLOBAL_MAPPING_EXPORT void v_GetJacobian(Array< OneD, NekDouble > &outarray) override
virtual GLOBAL_MAPPING_EXPORT void v_InitObject(const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const TiXmlElement *pMapping) override
virtual GLOBAL_MAPPING_EXPORT void v_GetInvMetricTensor(Array< OneD, Array< OneD, NekDouble > > &outarray) override
virtual GLOBAL_MAPPING_EXPORT void v_ContravarToCartesian(const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray) override
virtual GLOBAL_MAPPING_EXPORT void v_ContravarFromCartesian(const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray) override
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, std::string pDesc="")
Register a class with the factory.
Definition: NekFactory.hpp:198
MappingFactory & GetMappingFactory()
Declaration of the mapping factory singleton.
Definition: Mapping.cpp:53
std::shared_ptr< SessionReader > SessionReaderSharedPtr
MultiRegions::Direction const DirCartesianMap[]
Definition: ExpList.h:90
The above copyright notice and this permission notice shall be included.
Definition: CoupledSolver.h:2
void Vmul(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Multiply vector z = x*y.
Definition: Vmath.cpp:207
void Vabs(int n, const T *x, const int incx, T *y, const int incy)
vabs: y = |x|
Definition: Vmath.cpp:548
void Neg(int n, T *x, const int incx)
Negate x = -x.
Definition: Vmath.cpp:513
void Vvtvp(int n, const T *w, const int incw, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
vvtvp (vector times vector plus vector): z = w*x + y
Definition: Vmath.cpp:569
void Vadd(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Add vector z = x+y.
Definition: Vmath.cpp:354
void Vvtvm(int n, const T *w, const int incw, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
vvtvm (vector times vector minus vector): z = w*x - y
Definition: Vmath.cpp:593
void Smul(int n, const T alpha, const T *x, const int incx, T *y, const int incy)
Scalar multiply y = alpha*x.
Definition: Vmath.cpp:245
void Vdiv(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Multiply vector z = x/y.
Definition: Vmath.cpp:280
void Sadd(int n, const T alpha, const T *x, const int incx, T *y, const int incy)
Add scalar y = alpha + x.
Definition: Vmath.cpp:379
void Vcopy(int n, const T *x, const int incx, T *y, const int incy)
Definition: Vmath.cpp:1191
void Vsub(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Subtract vector z = x-y.
Definition: Vmath.cpp:414