CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

access boundary field from inside BC

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 2, 2010, 16:43
Default access boundary field from inside BC
  #1
Senior Member
 
Aram Amouzandeh
Join Date: Mar 2009
Location: Vienna, Vienna, Austria
Posts: 190
Rep Power: 17
mabinty is on a distinguished road
Hi all!

I implemented a radiation model in the chtMultiRegionFoam solver. Now I have to modify the solidWallMixedTemperature BC (solvers/heatTransfer/chtMultiRegionFoam/derivedFvPatchFields/solidWallMixedTemperatureCoupled) to account for radiation at the fluid_solid interface. There I need the total radiative heat flux Qr at the wall, calculated by the radiation model (here fvDOM). I tried:

Code:
scalarField Qrad;

if (findIndex(props.fluidRegionNames(), myRegion.name()) != -1)
    {
        Qrad = this->patch().lookupPatchField<volScalarField, scalar>(Qr);
    }
The code compiles, and when I run the solver I get the following error:

Code:
--> FOAM FATAL ERROR: 

    request for volScalarField  from objectRegistry air failed
    available objects of type volScalarField are

27
(
aLambda_0
a
ILambda_0_0
psi
DpDt
K
Qr0
h
I1
E
rho
Qr1
Cp
psi_0
G
ILambda_1_0
alpha
rho_0
p
T
Qr
I0
pow3(T)
p_0
e
bLambda_0
mu
)


    From function objectRegistry::lookupObject<Type>(const word&) const
    in file /home/aa/OpenFOAM/OpenFOAM-1.6.x/src/OpenFOAM/lnInclude/objectRegistryTemplates.C at line 140.

FOAM aborting

#0  Foam::error::printStack(Foam::Ostream&) in "/home/aa/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#1  Foam::error::abort() in "/home/aa/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libOpenFOAM.so"
#2  Foam::Ostream& Foam::operator<< <Foam::error>(Foam::Ostream&, Foam::errorManip<Foam::error>) in "/home/aa/OpenFOAM/aa-1.6.x/applications/bin/linux64GccDPOpt/chtMultiRegionRadFoam"
#3  Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> const& Foam::objectRegistry::lookupObject<Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh> >(Foam::word const&) const in "/home/aa/OpenFOAM/aa-1.6.x/applications/bin/linux64GccDPOpt/chtMultiRegionRadFoam"
#4  Foam::solidWallMixedTemperatureCoupledFvPatchScalarField::updateCoeffs() in "/home/aa/OpenFOAM/aa-1.6.x/applications/bin/linux64GccDPOpt/chtMultiRegionRadFoam"
#5  Foam::mixedFvPatchField<double>::evaluate(Foam::Pstream::commsTypes) in "/home/aa/OpenFOAM/aa-1.6.x/applications/bin/linux64GccDPOpt/chtMultiRegionRadFoam"
#6  Foam::mixedEnthalpyFvPatchScalarField::updateCoeffs() in "/home/aa/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libbasicThermophysicalModels.so"
#7  Foam::fvMatrix<double>::fvMatrix(Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>&, Foam::dimensionSet const&) in "/home/aa/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libradiation.so"
#8  Foam::tmp<Foam::fvMatrix<double> > Foam::fvm::Sp<double>(Foam::DimensionedField<double, Foam::volMesh> const&, Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>&) in "/home/aa/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libradiation.so"
#9  Foam::radiation::radiationModel::Sh(Foam::basicThermo&) const in "/home/aa/OpenFOAM/OpenFOAM-1.6.x/lib/linux64GccDPOpt/libradiation.so"
#10  main in "/home/aa/OpenFOAM/aa-1.6.x/applications/bin/linux64GccDPOpt/chtMultiRegionRadFoam"
#11  __libc_start_main in "/lib/libc.so.6"
#12  _start at /build/buildd/glibc-2.9/csu/../sysdeps/x86_64/elf/start.S:116
I don t know why the request failed as the field I d like to access is mentioned in the list of the available objects.

Can somebody give me a hint on how to get Qr at the considered boundary??

Thx in advance,
Aram
mabinty is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Implementation of boundary conditions for FVM Tom Main CFD Forum 7 August 26, 2014 06:58
Boundary condition vector field gradient from two sides of patch face quba OpenFOAM 0 December 12, 2007 06:26
Slip boundary condition what is inside normunds OpenFOAM Running, Solving & CFD 2 June 4, 2007 07:45
Boundary conditions? Tom Main CFD Forum 0 November 5, 2002 02:54
Far Field Boundary Conditions Xavi Main CFD Forum 8 December 17, 1998 09:11


All times are GMT -4. The time now is 05:38.