00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033 {
00034 labelList cellBoundaryFaceCount(omega_.size(), 0);
00035
00036 scalar Cmu25 = pow(Cmu.value(), 0.25);
00037
00038 const fvPatchList& patches = mesh_.boundary();
00039
00040
00041 forAll(patches, patchi)
00042 {
00043 const fvPatch& curPatch = patches[patchi];
00044
00045 if (isType<wallFvPatch>(curPatch))
00046 {
00047 forAll(curPatch, facei)
00048 {
00049 label faceCelli = curPatch.faceCells()[facei];
00050
00051 omega_[faceCelli] = 0.0;
00052 G[faceCelli] = 0.0;
00053 }
00054 }
00055 }
00056
00057
00058
00059 forAll(patches, patchi)
00060 {
00061 const fvPatch& curPatch = patches[patchi];
00062
00063 if (isType<wallFvPatch>(curPatch))
00064 {
00065 # include "checkkOmegaPatchFieldTypes.H"
00066
00067 const scalarField& rhow = rho_.boundaryField()[patchi];
00068
00069 const scalarField& muw = mu().boundaryField()[patchi];
00070 const scalarField& mutw = mut_.boundaryField()[patchi];
00071
00072 scalarField magFaceGradU =
00073 mag(U_.boundaryField()[patchi].snGrad());
00074
00075 forAll(curPatch, facei)
00076 {
00077 label faceCelli = curPatch.faceCells()[facei];
00078
00079 scalar yPlus =
00080 Cmu25*y_[faceCelli]
00081 *sqrt(k_[faceCelli])
00082 /(muw[facei]/rhow[facei]);
00083
00084
00085
00086
00087
00088 cellBoundaryFaceCount[faceCelli]++;
00089
00090 omega_[faceCelli] +=
00091 sqrt(k_[faceCelli])
00092 /(Cmu25*kappa_*y_[faceCelli]);
00093
00094 if (yPlus > yPlusLam_)
00095 {
00096 G[faceCelli] +=
00097 (mutw[facei] + muw[facei])
00098 *magFaceGradU[facei]
00099 *Cmu25*sqrt(k_[faceCelli])
00100 /(kappa_*y_[faceCelli]);
00101 }
00102 }
00103 }
00104 }
00105
00106
00107
00108
00109 forAll(patches, patchi)
00110 {
00111 const fvPatch& curPatch = patches[patchi];
00112
00113 if (isType<wallFvPatch>(curPatch))
00114 {
00115 forAll(curPatch, facei)
00116 {
00117 label faceCelli = curPatch.faceCells()[facei];
00118
00119 omega_[faceCelli] /= cellBoundaryFaceCount[faceCelli];
00120 G[faceCelli] /= cellBoundaryFaceCount[faceCelli];
00121 }
00122 }
00123 }
00124 }
00125
00126
00127
Copyright © 2000-2007 OpenCFD Ltd