|
[Sponsors] |
read vector for a user defined application with controlDict files |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
December 3, 2015, 07:29 |
read vector for a user defined application with controlDict files
|
#1 |
New Member
LU
Join Date: Oct 2015
Posts: 11
Rep Power: 10 |
I'm trying to read in a vector, eg. the point of the rotating center, from a dictionary and to initialize it as constant of a application, eg. A.I have susscceful to define a scaler
scalar omega=0; omega=readScalar(myDict.lookup("omega"); And now i want to do the same thing for a vector, but when i use readVector instead of readScaler, the error is that: the readVector is not declared, so i do not know how to declare it ? And I know there is also a dimensionedVecotr , so I try const vector r (0,0,0) dimensionedVector(myDict.looup("r"); in the case ,i can compile it but in the result ,the real value of r in myDIct is not read, it just use the (0,0,0) .so could you tell me the reasons or give me some suggestion. Thank you so much Best regards Lu |
|
December 6, 2015, 11:08 |
|
#2 |
Senior Member
Joachim Herb
Join Date: Sep 2010
Posts: 650
Rep Power: 21 |
Did you try something like:
Code:
dimensionedVector r(myDict.looup("r")); Code:
const vector r(myDict.looup("r")); |
|
April 4, 2018, 06:18 |
|
#3 | |
New Member
sencer yucesan
Join Date: Mar 2018
Location: Vienna
Posts: 2
Rep Power: 0 |
Quote:
Did you managed to read the files from the controlDict ? I also created my own application, however, still struggling to read the vectors .. |
||
April 4, 2018, 08:42 |
|
#4 | |
Member
|
Quote:
Code:
vector r (dict.lookup("r")); |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Additional Variables Defined By User FORTRAN CEL | Wheeler | CFX | 2 | August 6, 2013 21:33 |
User Defined Scalars - Returning Values | Carlos V. | FLUENT | 0 | April 19, 2006 18:18 |
Usage of user defined functions | Gowrish | FLUENT | 1 | October 26, 2005 07:44 |
Results saving in CFD | hawk | Main CFD Forum | 16 | July 21, 2005 20:51 |
User defined memory | Hp | FLUENT | 0 | September 24, 2004 00:10 |