|
[Sponsors] | |||||
|
|
|
#1 |
|
Senior Member
Illya Shevchuk
Join Date: Aug 2009
Location: Darmstadt, Germany
Posts: 147
Rep Power: 5 ![]() |
Hi Foamers,
is there an elegant way to declare multimedensional fields? Something similar to a multidimensional array e.g. scalar[n4][n3][n2][n1] my4DArray; This implementation seems to works, but is really inelegant (please don't laugh to loud at this stupid solution): Code:
Field <scalar> dummy1D(n1,scalar(0.0)); Field <Field <scalar> > dummy2D(n2,dummy1D); Field <Field <Field <scalar> > > dummy3D(n3,dummy2D); Field <Field <Field <Field <scalar> > > > my4DField(n4,dummy3D); Best regards, illya |
|
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| multidimensional integration in openfoam | Farshad_Noravesh | OpenFOAM | 2 | April 15, 2011 14:15 |
| multidimensional hashtable? | Farshad_Noravesh | OpenFOAM | 0 | January 24, 2011 09:05 |
| How to represent the pressure evaluated by multidimensional averaging? | renyun0511 | OpenFOAM Running, Solving & CFD | 0 | November 4, 2010 03:44 |
| Dynamic multidimensional array in C++? | Chen Zhi | Main CFD Forum | 13 | May 22, 2008 21:18 |
| Genuinely Multidimensional Upwind Scheme | Praveen Chandrashekar | Main CFD Forum | 9 | October 25, 2001 06:47 |