|
[Sponsors] |
Getting nu at a particular location, please help! |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
May 31, 2013, 08:44 |
Getting nu at a particular location, please help!
|
#1 |
Member
Jack
Join Date: Aug 2012
Posts: 47
Rep Power: 13 |
Hi there!
I have the task of compiling some models into later versions of openFoam (from 1.7.1), I believe I am almost there however I have come a bit unstuck on: nu()[CellI] in the below code. Is there still a way to use index notation with nu in OF-2.1.0? Thanks for any help you can give me! Jack Code:
labelHashSet fixCells; scalarField yPlus = 0.547723*y_*sqrt(k_)/nu(); forAll(omega_, i) { if(yPlus[i] < 2.0) { fixCells.insert(i); setO[i]=1; } } labelList fixCellsLabel = fixCells.toc(); scalarField fixO(fixCells.size()); forAll(fixO, i) { label cellI = fixCellsLabel[i]; fixO[i]=6.0/beta1_.value()*nu()[cellI]/(sqr(y_[cellI])); } omegaEqn().setValues(fixCellsLabel, fixO ); |
|
May 31, 2013, 09:44 |
|
#2 |
Senior Member
Bernhard
Join Date: Sep 2009
Location: Delft
Posts: 790
Rep Power: 21 |
I don't think these kind of addressing really changed from 1.7 to 2.1. I assume you got problems with compiling, can you shows some error messages?
|
|
May 31, 2013, 09:56 |
|
#3 |
Member
Jack
Join Date: Aug 2012
Posts: 47
Rep Power: 13 |
Hi, thank you very much for a quick reply.
The error is as follows: Code:
Making dependency list for source file v2fEASMkOmegaV2/v2fEASMkOmegaV2.C In file included from v2fEASMkOmegaV2/v2fEASMkOmegaV2.C:670:0: v2fEASMkOmegaV2/omegaBSLWall.H: In member function 'virtual void Foam::incompressible::RASModels::v2fEASMkOmegaV2::correct()': v2fEASMkOmegaV2/omegaBSLWall.H:75:38: error: no match for 'operator[]' in 'Foam::incompressible::turbulenceModel::nu() const()[faceCelli]' In file included from v2fEASMkOmegaV2/v2fEASMkOmegaV2.C:672:0: v2fEASMkOmegaV2/setOmega.H:30:39: error: no match for 'operator[]' in 'Foam::incompressible::turbulenceModel::nu() const()[cellI]' make: *** [Make/darwinIntel64Gcc46DPOpt/v2fEASMkOmegaV2.o] Error 1 Thanks Jack |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Radiation interface | hinca | CFX | 15 | January 26, 2014 17:11 |
An error has occurred in cfx5solve: | volo87 | CFX | 5 | June 14, 2013 17:44 |
Error finding variable "THERMX" | sunilpatil | CFX | 8 | April 26, 2013 07:00 |
Errors running allwmake in OpenFOAM141dev with WM_COMPILE_OPTION%3ddebug | unoder | OpenFOAM Installation | 11 | January 30, 2008 20:30 |