# OpenFOAM の境界条件をまとめよう！

• View
1.423

• Category

## Technology

Embed Size (px)

DESCRIPTION

### Text of OpenFOAM の境界条件をまとめよう！

• 1. Fumiya Nozaki : 2014811 OpenFOAM Boundary Conditions
• 2. 2 cylindricalInletVelocity cylindricalInletVelocity myPatch { type cylindricalInletVelocity; axis (0 0 1); centre (0 0 0); axialVelocity constant 30; radialVelocity constant -10; rpm constant 100; } axis centre centre
• 3. 3 cylindricalInletVelocity (Z) axis centre axialVelocity axis axis radialVelocity rpm rpm = 2 60 rpm axis
• 4. 4 cylindricalInletVelocity void Foam::cylindricalInletVelocityFvPatchVectorField::updateCoeffs() { if (updated()) { return; } const scalar t = this->db().time().timeOutputValue(); const scalar axialVelocity = axialVelocity_->value(t); const scalar radialVelocity = radialVelocity_->value(t); const scalar rpm = rpm_->value(t); vector hatAxis = axis_/mag(axis_); const vectorField r(patch().Cf() - centre_); const vectorField d(r - (hatAxis & r)*hatAxis); tmp tangVel ( (rpm*constant::mathematical::pi/30.0)*(hatAxis) ^ d ); operator==(tangVel + hatAxis*axialVelocity + radialVelocity*d/mag(d)); fixedValueFvPatchField::updateCoeffs(); }
• 5. 5 fixedMean fixedMean outlet { type fixedMean; meanValue 10.0; value uniform 0.0; } outlet = 10.0 meanValue
• 6. 6 fixedMean 0100 template 0101 void fixedMeanFvPatchField::updateCoeffs() 0102 { 0103 if (this->updated()) 0104 { 0105 return; 0106 } 0107 0108 Field newValues(this->patchInternalField()); 0109 0110 Type meanValuePsi = 0111 gSum(this->patch().magSf()*newValues) 0112 /gSum(this->patch().magSf()); 0113 0114 if (mag(meanValue_) > SMALL && mag(meanValuePsi)/mag(meanValue_) > 0.5) 0115 { 0116 newValues *= mag(meanValue_)/mag(meanValuePsi); 0117 } 0118 else 0119 { 0120 newValues += (meanValue_ - meanValuePsi); 0121 } 0122 0123 this->operator==(newValues); 0124 0125 fixedValueFvPatchField::updateCoeffs(); 0126 }
• 7. 7 fixedMean 110-113meanValuePsi 114-121 meanValue_ meanValuePsi =
• 8. 8 SRFVelocity SRFVelocity SRFSimpleFoam SRFPimpleFoam Urel relative no inletValue relative yes inletValue inlet { type SRFVelocity; inletValue uniform ( 0 0 -10 ); relative no; value uniform ( 0 0 0 ); } = +
• 9. 9 SRFVelocity void Foam::SRFVelocityFvPatchVectorField::updateCoeffs() { if (updated()) { return; } // If not relative to the SRF include the effect of the SRF if (!relative_) { // Get reference to the SRF model const SRF::SRFModel& srf = db().lookupObject("SRFProperties"); // Determine patch velocity due to SRF const vectorField SRFVelocity(srf.velocity(patch().Cf())); operator==(-SRFVelocity + inletValue_); } // If already relative to the SRF simply supply the inlet value as a fixed // value else { operator==(inletValue_); } fixedValueFvPatchVectorField::updateCoeffs(); } relative no = + relative yes SRFModel.C 160
• 10. 10 turbulentIntensityKineticEnergyInlet turbulentIntensityKineticEnergyInlet = 3 2 2 : intensity Inlet { type turbulentIntensityKineticEnergyInlet; intensity 0.05; // 5% U U; // value uniform 1; // }
• 11. 11 turbulentMixingLengthFrequencyInlet turbulentMixingLengthFrequencyInlet = 0.25 Inlet { type turbulentMixingLengthFrequencyInlet; mixingLength 0.005; // [m] value uniform 1; } : mixingLength ( 0.09)

Recommended

Documents
Science
Documents
Documents
Documents
Documents
Documents
Documents
Technology
Engineering
Documents
Documents