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

New boundary condition

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 14, 2009, 07:03
Default
  #21
tnk
New Member
 
L.E.Tonkov
Join Date: Apr 2009
Posts: 3
Rep Power: 17
tnk is on a distinguished road
Thank you, Alexander for fast reply. As far as I understand inletOutlet, b.c. depend on U vector direction but not magnitude.

I send forum private message to you.

Best regards
Leonid
tnk is offline   Reply With Quote

Old   June 8, 2009, 22:19
Default
  #22
Senior Member
 
ZHOU Bin
Join Date: Mar 2009
Location: Nanjing/Torino, Nanjing/Piemente, China/Italy
Posts: 164
Rep Power: 17
zhoubinwx is on a distinguished road
Send a message via ICQ to zhoubinwx Send a message via MSN to zhoubinwx Send a message via Skype™ to zhoubinwx
Hello,

Can I ask in " valueFraction*U + (1-valueFraction)*dU = 0 ", dU means the normal gradient of U, i.e. dU/dn, or just the difference between internalField velocity and boundary velocity?

Bin



Quote:
Originally Posted by niklas View Post
Hola,

Not 100 percent sure, but I'd say its like this:

valueFraction*U + (1-valueFraction)*dU = 0

N
zhoubinwx is offline   Reply With Quote

Old   June 9, 2009, 03:49
Default
  #23
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
According to User Guide page 128 it is normal gradient. Learn to use documentation for such questions, it will be more usefull:-)
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   June 24, 2010, 16:09
Default
  #24
Member
 
Join Date: Dec 2009
Location: Kanpur, India
Posts: 54
Rep Power: 16
Shoonya is on a distinguished road
Hello makaveli_lcf
You wrote that you had written your own code for dT/dn = h_ext / k_f * (T_ext - T) this kind of BC. I am trying to solve a problem which concerns the same BC you have talked in post #18. Could you please send me your code of that BC. I would be grateful to you.

thanks

Last edited by Shoonya; June 25, 2010 at 02:22.
Shoonya is offline   Reply With Quote

Old   October 6, 2010, 01:46
Default
  #25
Member
 
Join Date: Dec 2009
Posts: 46
Rep Power: 16
openfoam1 is on a distinguished road
Hi,


the equation

valueFraction * U + (1 - valueFraction) * dU/dy = 0

is not dimensionally consistent !!

i think it should be

valueFraction * U + (1 - valueFraction) *dU= 0

which dU is only the velocity difference

any comments ?

thanks

Last edited by openfoam1; October 6, 2010 at 17:44.
openfoam1 is offline   Reply With Quote

Old   October 6, 2010, 17:48
Default
  #26
Member
 
Join Date: Dec 2009
Posts: 46
Rep Power: 16
openfoam1 is on a distinguished road
Quote:
Originally Posted by zhoubinwx View Post
Hello,

Can I ask in " valueFraction*U + (1-valueFraction)*dU = 0 ", dU means the normal gradient of U, i.e. dU/dn, or just the difference between internalField velocity and boundary velocity?

Bin
That is a good post

dU is not dU/dn it is just the difference between internalField velocity and boundary velocity

because the equation must be dimensionally consistent

by the way , i verified it using simple mesh and icoFoam solver

thank you
openfoam1 is offline   Reply With Quote

Old   October 7, 2010, 03:31
Default
  #27
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
It is not necessary to guess what is what. Just have a look at the source code, otherwise why do we need it)))

So, from mixedFvPatchField.C:

Code:
00142 template<class Type>
00143 void mixedFvPatchField<Type>::evaluate(const Pstream::commsTypes)
00144 {
00145     if (!this->updated())
00146     {
00147         this->updateCoeffs();
00148     }
00149 
00150     Field<Type>::operator=
00151     (
00152         valueFraction_*refValue_
00153       +
00154         (1.0 - valueFraction_)*
00155         (
00156             this->patchInternalField()
00157           + refGrad_/this->patch().deltaCoeffs()
00158         )
00159     );
00160 
00161     fvPatchField<Type>::evaluate();
00162 }
00163 
00164 
00165 template<class Type>
00166 tmp<Field<Type> > mixedFvPatchField<Type>::snGrad() const
00167 {
00168     return
00169         valueFraction_
00170        *(refValue_ - this->patchInternalField())
00171        *this->patch().deltaCoeffs()
00172       + (1.0 - valueFraction_)*refGrad_;
00173 }
That mean,

U_wall = valueFraction*U0 + (1 - valueFraction)*(U_nearwall + Grad0 * dn)

where U0 and Grad0 are our given reference values for boundary field and gradient at the wall. dn is the distance between center of the cell and the boundary face. Now it is possible to transform this condition in whatever form is necessary))) All gradients and matrix coefficients are calculated using this relation.

Good luck!
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   February 17, 2011, 11:15
Default
  #28
New Member
 
Raimonds Vilums
Join Date: Oct 2010
Posts: 17
Rep Power: 17
argonaut is on a distinguished road
To implement something like this
Quote:
Originally Posted by makaveli_lcf View Post
T - T_ext - k_f /h_f * d(T)/dn = 0 (3)
you could use groovyBC from swak4foam in the similar manner like the following code:
Code:
rightWall
{
    type                   groovyBC;
    variables              "h_f=20.0;T_ext=20.0;k_f=0.2;";
    valueExpression     "T_ext";
    fractionExpression  "1.0/(1.0 + k_f/(mag(delta())*h_f))";
}
For explanation, see thread Mixed BC - heat transfer - laplacianFoam
argonaut is offline   Reply With Quote

Old   February 8, 2012, 14:31
Default Partial slip boundary
  #29
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
thank u in advance!

Last edited by Kanarya; February 17, 2012 at 12:29.
Kanarya is offline   Reply With Quote

Old   February 17, 2012, 12:26
Default ParticalSlip in OpenFOAM210
  #30
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
hi Foamers,

I am trying to compile particleSlip BC but it gives me error. can it be because of the version of OpenFoam because Alberto did code 2009 or 2010?can be the headers are different?
The error is:
Make/linux64GccDPOpt/particleSlipJohnsonJacksonFvPatchVectorField.o: In function `_GLOBAL__sub_I_particleSlipJohnsonJacksonFvPatchV ectorField.C':
particleSlipJohnsonJacksonFvPatchVectorField.C.t ext.startup+0xaf): undefined reference to `Foam::fvPatchField<Foam::Vector<double> >::constructpatchConstructorTables()'
particleSlipJohnsonJacksonFvPatchVectorField.C.t ext.startup+0xcc): undefined reference to `Foam::fvPatchField<Foam::Vector<double> >:atchConstructorTablePtr_'
particleSlipJohnsonJacksonFvPatchVectorField.C.t ext.startup+0xef): undefined reference to `Foam::fvPatchField<Foam::Vector<double> >::constructpatchMapperConstructorTables()'
particleSlipJohnsonJacksonFvPatchVectorField.C.t ext.startup+0x10f): undefined reference to `Foam::fvPatchField<Foam::Vector<double> >:atchMapperConstructorTablePtr_'
particleSlipJohnsonJacksonFvPatchVectorField.C.t ext.startup+0x132): undefined reference to `Foam::fvPatchField<Foam::Vector<double> >::constructdictionaryConstructorTables()'
particleSlipJohnsonJacksonFvPatchVectorField.C.t ext.startup+0x152): undefined reference to `Foam::fvPatchField<Foam::Vector<double> >::dictionaryConstructorTablePtr_'
collect2: ld returned 1 exit status

someone can help me?

Thanks in advance
Kanarya is offline   Reply With Quote

Old   February 27, 2012, 17:34
Unhappy particleSlipJohnsonJackson
  #31
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
Hi Foamers,

I would like to apply particleSlip BCs but I have following error and I could not find out the problem...please help me..
Create mesh for time = 0


Reading g
Reading transportProperties



--> FOAM FATAL ERROR:

request for dictionary kineticTheoryProperties from objectRegistry region0 failed
available objects of type dictionary are

4
(
fvSchemes
fvSolution
data
transportProperties
)


From function objectRegistry::lookupObject<Type>(const word&) const
in file /opt/openfoam201/src/OpenFOAM/lnInclude/objectRegistryTemplates.C at line 131.

FOAM aborting

#0 Foam::error:rintStack(Foam::Ostream&) in "/opt/openfoam201/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#1 Foam::error::abort() in "/opt/openfoam201/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#2 Foam::IOdictionary const& Foam:bjectRegistry::lookupObject<Foam::IOdiction ary>(Foam::word const&) const in "/opt/openfoam201/platforms/linuxGccDPOpt/lib/libfiniteVolume.so"
#3 Foam:articleSlipJohnsonJacksonFvPatchVectorField ::updateCoeffs() in "/home/recepkati/OpenFOAM/recepkati-2.0.1/platforms/linuxGccDPOpt/lib/libJohnsonJackson.so"
#4 Foam:artialSlipFvPatchField<Foam::Vector<double> >::evaluate(Foam::UPstream::commsTypes) in "/opt/openfoam201/platforms/linuxGccDPOpt/lib/libfiniteVolume.so"
#5 Foam:articleSlipJohnsonJacksonFvPatchVectorField:a rticleSlipJohnsonJacksonFvPatchVectorField(Foam::f vPatch const&, Foam:imensionedField<Foam::Vector<double>, Foam::volMesh> const&, Foam::dictionary const&) in "/home/recepkati/OpenFOAM/recepkati-2.0.1/platforms/linuxGccDPOpt/lib/libJohnsonJackson.so"
#6 Foam::fvPatchField<Foam::Vector<double> >::adddictionaryConstructorToTable<Foam:articleS lipJohnsonJacksonFvPatchVectorField>::New(Foam::fv Patch const&, Foam:imensionedField<Foam::Vector<double>, Foam::volMesh> const&, Foam::dictionary const&) in "/home/recepkati/OpenFOAM/recepkati-2.0.1/platforms/linuxGccDPOpt/lib/libJohnsonJackson.so"
#7 Foam::fvPatchField<Foam::Vector<double> >::New(Foam::fvPatch const&, Foam:imensionedField<Foam::Vector<double>, Foam::volMesh> const&, Foam::dictionary const&) in "/opt/openfoam201/platforms/linuxGccDPOpt/bin/twoPhaseEulerFoam"
#8 Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh>::GeometricBoundaryField::GeometricB oundaryField(Foam::fvBoundaryMesh const&, Foam:imensionedField<Foam::Vector<double>, Foam::volMesh> const&, Foam::dictionary const&) in "/opt/openfoam201/platforms/linuxGccDPOpt/bin/twoPhaseEulerFoam"
#9 Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh>::readField(Foam::dictionary const&) in "/opt/openfoam201/platforms/linuxGccDPOpt/bin/twoPhaseEulerFoam"
#10 Foam::GeometricField<Foam::Vector<double>, Foam::fvPatchField, Foam::volMesh>::readField(Foam::Istream&) in "/opt/openfoam201/platforms/linuxGccDPOpt/bin/twoPhaseEulerFoam"
#11 at phaseModel.C:0
#12 Foam:haseModel:haseModel(Foam::fvMesh const&, Foam::dictionary const&, Foam::word const&) in "/home/recepkati/OpenFOAM/recepkati-2.0.1/platforms/linuxGccDPOpt/lib/libphaseModel.so"
Aborted
thanks in advance..
Kanarya is offline   Reply With Quote

Old   February 28, 2012, 03:46
Default
  #32
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
Quote:
request for dictionary kineticTheoryProperties from objectRegistry region0 failed
available objects of type dictionary are
You need that dictionary for your solver.
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   February 28, 2012, 06:22
Unhappy particleSlipJohnsonJackson
  #33
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
Hi Alex,

thank you very much for your quick answer. I have already the directory there. I am using twoPhaseEulerFoam solver and I implement particleSlipJohnsonJackson BC in the model which is also from tutorials case "bed2".my file looks like:
dimensions [0 1 -1 0 0 0 0];

internalField uniform (0 0 0);

boundaryField
{
walls
{
type particleSlipJohnsonJackson;
specularityCoefficient 0.5;

}
outlet
{
type zeroGradient;
}
inlet
{
type fixedValue;
value uniform (0 0 0);
}
frontAndBackPlanes
{
type empty;
}
}

I changed BC of the walls.

and I have the directory kineticTheoryProperties in the model.

thanks a lot again
Kanarya is offline   Reply With Quote

Old   February 28, 2012, 06:25
Default
  #34
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
Quote:
and I have the directory kineticTheoryProperties in the model.
That should be a file in "constant/" folder, see
bed2/constant/kineticTheoryProperties

in tutorial
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   February 28, 2012, 06:33
Unhappy particleSlipJohnsonJackson
  #35
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
Hi Alex,
yes I had a look to this file but I could not find the problem what I should add there?

I attached the code as well.

thank you very much and I appreciate your time to send me this suggestions.

recep
Attached Files
File Type: c particleSlipJohnsonJacksonFvPatchVectorField.C (5.8 KB, 34 views)
Kanarya is offline   Reply With Quote

Old   February 28, 2012, 07:46
Default
  #36
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
Do you have this file in your case folder?
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   February 28, 2012, 07:48
Default
  #37
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
Ok, if you look in your BC file

Quote:
void particleSlipJohnsonJacksonFvPatchVectorField::upda teCoeffs()
{
if (updated())
{
return;
}

if ((specularityCoefficient_ < 0) || (specularityCoefficient_ > 1))
{
FatalErrorIn
(
"particleSlipJohnsonJacksonFvPatchScalarField: :"
"updateCoeffs()"
) << "The value of the specularity coefficient has to be between 0 and 1."
<< abort(FatalError);
}

const dictionary& transportProperties = db().lookupObject<IOdictionary>
(
"transportProperties"
);

const dictionary& kineticTheoryProperties = db().lookupObject<IOdictionary>
(
"kineticTheoryProperties"
);

...
so your BC looks for the dictionary kineticTheoryProperties in the memory,
but does not find.

Which solver do you use?
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   February 28, 2012, 07:49
Default particleSlipJohnsonJackson
  #38
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
hi Alex,

I think you forget to say the name of the file, which file?

best regards and thanks again

recep
Kanarya is offline   Reply With Quote

Old   February 28, 2012, 07:50
Default
  #39
Senior Member
 
Dr. Alexander Vakhrushev
Join Date: Mar 2009
Posts: 256
Blog Entries: 1
Rep Power: 19
makaveli_lcf is on a distinguished road
Send a message via ICQ to makaveli_lcf
no, that which you send me
__________________
Best regards,

Dr. Alexander VAKHRUSHEV

Christian Doppler Laboratory for "Metallurgical Applications of Magnetohydrodynamics"

Simulation and Modelling of Metallurgical Processes
Department of Metallurgy
University of Leoben

http://smmp.unileoben.ac.at
makaveli_lcf is offline   Reply With Quote

Old   February 28, 2012, 07:52
Default particleSlipJohnsonJackson
  #40
Senior Member
 
Join Date: May 2011
Posts: 231
Rep Power: 16
Kanarya is on a distinguished road
hi Alex

I am using twoPhaseEulerFoam.

yes, I understood the problem but I do not know how to modify it.

thanks

Recep
Kanarya is offline   Reply With Quote

Reply

Tags
heat transfer, new bc


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
Boundary condition for UDS Tomik FLUENT 0 December 5, 2006 18:37
Boundary condition of the third kind or Danckwertz boundary condition plage OpenFOAM Running, Solving & CFD 4 October 3, 2006 13:21
Slip Boundary Condition for Moving Boundary Shukla Main CFD Forum 3 November 11, 2005 16:02
UDF boundary condition Jeff FLUENT 2 November 20, 2003 18:15
Boundary Condition in LES Zhang Tsiang Main CFD Forum 3 February 5, 2002 21:15


All times are GMT -4. The time now is 16:19.