|
[Sponsors] |
April 2, 2013, 05:41 |
Add time-dependent force
|
#1 |
New Member
Pavel
Join Date: Apr 2013
Location: Russia
Posts: 2
Rep Power: 0 |
Hello everyone,
I'm a new OpenFoam user. I need to add into the Navier-Stokes equations the time-dependent force: f(t) = F*cos(w*t)^2, where t - time. Here is the UEqn.H: Code:
fvVectorMatrix UEqn ( fvm::ddt(rho, U) + fvm::div(rhoPhi, U) + turbulence->divDevRhoReff(rho, U) ); UEqn.relax(); if (pimple.momentumPredictor()) { solve ( UEqn == (rho*F) - fvc::reconstruct ( ( - ghf*fvc::snGrad(rho) - fvc::snGrad(p_rgh) ) * mesh.magSf() ) ); } Code:
... Info<< "Reading field F\n" << endl; volVectorField F ( IOobject ( "F", runTime.timeName(), mesh, IOobject::MUST_READ, IOobject::AUTO_WRITE ), mesh ); ... Could you tell me how to do it. |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Sudden jump in Courant number | NJG | OpenFOAM Running, Solving & CFD | 7 | May 15, 2014 14:52 |
pimpleFoam: turbulence->correct(); is not executed when using residualControl | hfs | OpenFOAM Running, Solving & CFD | 3 | October 29, 2013 09:35 |
Orifice Plate with a fully developed flow - Problems with convergence | jonmec | OpenFOAM Running, Solving & CFD | 3 | July 28, 2011 06:24 |
How to add time varying body force | hsieh | OpenFOAM Running, Solving & CFD | 2 | July 26, 2010 12:43 |
IcoFoam parallel woes | msrinath80 | OpenFOAM Running, Solving & CFD | 9 | July 22, 2007 03:58 |