<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>multiPhysicsFoam – Diffusion</title><link>https://multiphysicsfoam.com/tags/diffusion/</link><description>Recent content in Diffusion on multiPhysicsFoam</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://multiphysicsfoam.com/tags/diffusion/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: laplacianFluid</title><link>https://multiphysicsfoam.com/docs/user-guide/region-physics/heat-transfer-models/laplacianfluid/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://multiphysicsfoam.com/docs/user-guide/region-physics/heat-transfer-models/laplacianfluid/</guid><description>
&lt;h2 id="overview">Overview&lt;/h2>
&lt;p>&lt;code>laplacianFluid&lt;/code> solves the transient diffusion equation for a scalar field
&lt;code>T&lt;/code> on a &lt;strong>static&lt;/strong> mesh. It is a direct port of the stock OpenFOAM
&lt;code>laplacianFoam&lt;/code> solver into the &lt;code>regionType&lt;/code> framework: no velocity field, no
pressure-velocity coupling, and no mesh motion are involved — only a single
diffusion equation with a constant or field diffusivity &lt;code>DT&lt;/code>. Despite the
name &lt;code>T&lt;/code>, the field is a generic passive scalar and can represent temperature
or any other diffusing quantity. It is suitable as a lightweight standalone
conduction region, or as one side of a multi-region coupling where only
diffusive transport of a scalar is required.&lt;/p>
&lt;h2 id="governing-equations">Governing Equations&lt;/h2>
&lt;h3 id="diffusion">Diffusion&lt;/h3>
$$
\frac{\partial T}{\partial t} - \nabla \cdot \left( D_T \, \nabla T \right) = S_T
$$
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Symbol&lt;/th>
&lt;th>Description&lt;/th>
&lt;th>Unit&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>$T$&lt;/td>
&lt;td>Transported scalar (e.g. temperature)&lt;/td>
&lt;td>K (or scalar-dependent)&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$D_T$&lt;/td>
&lt;td>Diffusivity&lt;/td>
&lt;td>m²/s&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$S_T$&lt;/td>
&lt;td>Source term (from &lt;code>fvOptions&lt;/code>)&lt;/td>
&lt;td>[T]/s&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;p>There is no continuity or momentum equation — &lt;code>laplacianFluid&lt;/code> has no velocity
field and does not support advection.&lt;/p>
&lt;h2 id="numerical-algorithm">Numerical Algorithm&lt;/h2>
&lt;p>&lt;code>laplacianFluid&lt;/code> does not run its own outer solve loop. &lt;code>usesPIMPLE()&lt;/code> returns
&lt;code>false&lt;/code>, and &lt;code>solveRegion()&lt;/code>, &lt;code>prePredictor()&lt;/code>, &lt;code>momentumPredictor()&lt;/code>,
&lt;code>pressureCorrector()&lt;/code>, and &lt;code>meshMotionCorrector()&lt;/code> are all no-ops. Instead:&lt;/p>
&lt;ol>
&lt;li>&lt;code>setCoupledEqns(&amp;quot;T&amp;quot;)&lt;/code> assembles the diffusion equation as an
&lt;code>fvScalarMatrix&lt;/code> and registers it with &lt;code>multiRegionSystem&lt;/code>.&lt;/li>
&lt;li>The equation is solved through the standard coupled-matrix path
(&lt;code>multiRegionSystem::assembleAndSolveEqns&amp;lt;scalar&amp;gt;(&amp;quot;T&amp;quot;)&lt;/code>), the same
mechanism used for DNA-coupled partitioned fields.&lt;/li>
&lt;li>&lt;code>getMinDeltaT()&lt;/code> returns &lt;code>GREAT&lt;/code>, i.e. this region never constrains the
global time step — &lt;code>deltaT&lt;/code> must be set explicitly (no diffusion-number
based adjustable time-stepping is implemented).&lt;/li>
&lt;li>On write steps only, &lt;code>postSolve()&lt;/code> recomputes the derived output fields
&lt;code>gradTx&lt;/code>, &lt;code>gradTy&lt;/code>, &lt;code>gradTz&lt;/code>, and &lt;code>DTgradT = DT * grad(T)&lt;/code> if
&lt;code>writeGradT&lt;/code> is enabled (mirrors &lt;code>laplacianFoam&lt;/code>&amp;rsquo;s &lt;code>write.H&lt;/code>).&lt;/li>
&lt;/ol>
&lt;p>&lt;strong>Non-orthogonal correction caveat:&lt;/strong> stock &lt;code>laplacianFoam&lt;/code> wraps its solve in
a &lt;code>while (simple.correctNonOrthogonal())&lt;/code> loop. The coupled-matrix solve path
used here has no equivalent non-orthogonal corrector loop, so results will
differ from &lt;code>laplacianFoam&lt;/code> on non-orthogonal meshes. The closest substitute
is the region&amp;rsquo;s Picard corrector (&lt;code>maxCorr&lt;/code> / &lt;code>convergenceTolerance&lt;/code> in
&lt;code>fvSolution&lt;/code>), which re-invokes &lt;code>setCoupledEqns()&lt;/code> per iteration.&lt;/p>
&lt;h2 id="sub-models">Sub-Models&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Sub-model&lt;/th>
&lt;th>Selection mechanism&lt;/th>
&lt;th>Notes&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>fvOptions&lt;/code>&lt;/td>
&lt;td>&lt;code>system/fvOptions&lt;/code>&lt;/td>
&lt;td>Explicit/implicit source terms for &lt;code>T&lt;/code>&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;p>No turbulence, transport-model, or MRF sub-models are used.&lt;/p>
&lt;h2 id="required-fields">Required Fields&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Field&lt;/th>
&lt;th>Type&lt;/th>
&lt;th>Description&lt;/th>
&lt;th>Unit&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>T&lt;/code>&lt;/td>
&lt;td>&lt;code>volScalarField&lt;/code>&lt;/td>
&lt;td>Transported scalar&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>DT&lt;/code>&lt;/td>
&lt;td>&lt;code>volScalarField&lt;/code>&lt;/td>
&lt;td>Diffusivity — read if present, otherwise created uniform from &lt;code>transportProperties&lt;/code>&lt;/td>
&lt;td>m²/s&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;p>Additionally created at runtime if &lt;code>writeGradT&lt;/code> is enabled (default &lt;code>true&lt;/code>):&lt;/p>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Field&lt;/th>
&lt;th>Type&lt;/th>
&lt;th>Description&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>gradTx&lt;/code>, &lt;code>gradTy&lt;/code>, &lt;code>gradTz&lt;/code>&lt;/td>
&lt;td>&lt;code>volScalarField&lt;/code>&lt;/td>
&lt;td>Components of $\nabla T$&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>DTgradT&lt;/code>&lt;/td>
&lt;td>&lt;code>volVectorField&lt;/code>&lt;/td>
&lt;td>Diffusive flux $D_T \nabla T$&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="case-setup">Case Setup&lt;/h2>
&lt;h3 id="required-dictionaries">Required dictionaries&lt;/h3>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-gdscript3" data-lang="gdscript3">&lt;span class="line">&lt;span class="cl">&lt;span class="n">constant&lt;/span>&lt;span class="o">/&lt;/span>&lt;span class="n">transportProperties&lt;/span> &lt;span class="err">–&lt;/span> &lt;span class="n">diffusivity&lt;/span> &lt;span class="p">(&lt;/span>&lt;span class="n">DT&lt;/span>&lt;span class="p">),&lt;/span> &lt;span class="k">if&lt;/span> &lt;span class="n">no&lt;/span> &lt;span class="n">DT&lt;/span> &lt;span class="n">field&lt;/span> &lt;span class="n">is&lt;/span> &lt;span class="n">supplied&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="n">system&lt;/span>&lt;span class="o">/&lt;/span>&lt;span class="n">fvSolution&lt;/span> &lt;span class="err">–&lt;/span> &lt;span class="n">T&lt;/span> &lt;span class="n">solver&lt;/span> &lt;span class="n">settings&lt;/span>&lt;span class="p">,&lt;/span> &lt;span class="n">SIMPLE&lt;/span>&lt;span class="o">.&lt;/span>&lt;span class="n">writeGradT&lt;/span> &lt;span class="n">flag&lt;/span>
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">&lt;span class="n">system&lt;/span>&lt;span class="o">/&lt;/span>&lt;span class="n">fvSchemes&lt;/span> &lt;span class="err">–&lt;/span> &lt;span class="n">discretisation&lt;/span> &lt;span class="n">schemes&lt;/span>
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h3 id="multiregionproperties-entry">&lt;code>multiRegionProperties&lt;/code> entry&lt;/h3>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-fallback" data-lang="fallback">&lt;span class="line">&lt;span class="cl">regions
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">(
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> ( scalarRegion (laplacianFluid) )
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">);
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h3 id="controldict-singleregionmode">&lt;code>controlDict&lt;/code> (singleRegionMode)&lt;/h3>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-fallback" data-lang="fallback">&lt;span class="line">&lt;span class="cl">singleRegionMode yes;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">regionType laplacianFluid;
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h3 id="key-fvsolution-settings">Key &lt;code>fvSolution&lt;/code> settings&lt;/h3>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-fallback" data-lang="fallback">&lt;span class="line">&lt;span class="cl">solvers
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> T
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> {
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> solver PCG;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> preconditioner DIC;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> tolerance 1e-06;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> relTol 0;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> }
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">}
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">SIMPLE
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> writeGradT true; // write grad(T) components and DT*grad(T) at write time
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">}
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h3 id="transportproperties">&lt;code>transportProperties&lt;/code>&lt;/h3>
&lt;div class="highlight">&lt;pre tabindex="0" class="chroma">&lt;code class="language-fallback" data-lang="fallback">&lt;span class="line">&lt;span class="cl">DT 4e-05; // uniform diffusivity, used if no DT field is present
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;h2 id="coupling">Coupling&lt;/h2>
&lt;p>&lt;code>laplacianFluid&lt;/code> exposes &lt;code>T&lt;/code> via &lt;code>selfCoupledFieldNames()&lt;/code>, so it is solved
standalone and can also participate as a pure-diffusion side in multi-region
interfaces (unlike &lt;code>conductTemperature&lt;/code>, whose &lt;code>T&lt;/code> is only solved through
partitioned coupling):&lt;/p>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Interface type&lt;/th>
&lt;th>Exchanged fields&lt;/th>
&lt;th>Coupling modes&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>heatTransferInterface&lt;/code>&lt;/td>
&lt;td>&lt;code>T&lt;/code>, heat flux &lt;code>q&lt;/code>&lt;/td>
&lt;td>partitioned (DNA)&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>defaultInterface&lt;/code>&lt;/td>
&lt;td>&lt;code>T&lt;/code>&lt;/td>
&lt;td>partitioned (DNA)&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="known-limitations">Known Limitations&lt;/h2>
&lt;ul>
&lt;li>&lt;strong>Static mesh only&lt;/strong> — &lt;code>meshMotionCorrector()&lt;/code> is a no-op; moving/deforming
meshes are not supported.&lt;/li>
&lt;li>&lt;strong>No non-orthogonal corrector loop&lt;/strong> — unlike &lt;code>laplacianFoam&lt;/code>, the coupled
solve path used here does not iterate over non-orthogonal correctors within
a single time step; see the numerical algorithm note above for the
workaround.&lt;/li>
&lt;/ul>
&lt;h2 id="tutorials">Tutorials&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Tutorial path&lt;/th>
&lt;th>Description&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>tutorials/singleRegion/laplacianFluid/flange&lt;/code>&lt;/td>
&lt;td>Classic OpenFOAM &amp;ldquo;flange&amp;rdquo; thermal conduction case (single-region, fixed time step)&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="references">References&lt;/h2>
&lt;ul>
&lt;li>Alkfri, A., Habes, C., Marschall, H., &lt;em>multiRegionFoam: A Unified Multiphysics Framework for Multi-Region Coupled Continuum-Physical Problems&lt;/em>, Engineering with Computers, 2023.
DOI: &lt;a href="https://doi.org/10.1007/s00366-024-01974-4">10.1007/s00366-024-01974-4&lt;/a>&lt;/li>
&lt;/ul></description></item></channel></rss>