<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>multiPhysicsFoam – Scalar-Transport</title><link>https://multiphysicsfoam.com/tags/scalar-transport/</link><description>Recent content in Scalar-Transport on multiPhysicsFoam</description><generator>Hugo -- gohugo.io</generator><language>en</language><atom:link href="https://multiphysicsfoam.com/tags/scalar-transport/index.xml" rel="self" type="application/rss+xml"/><item><title>Docs: regionCoupledScalarFlux</title><link>https://multiphysicsfoam.com/docs/user-guide/boundary-conditions/coupled-boundary-conditions/regioncoupledscalarflux/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://multiphysicsfoam.com/docs/user-guide/boundary-conditions/coupled-boundary-conditions/regioncoupledscalarflux/</guid><description>
&lt;h2 id="overview">Overview&lt;/h2>
&lt;p>&lt;code>regionCoupledScalarFlux&lt;/code> is the concrete scalar flux side (Neumann side) of
the partitioned DNA coupling. It derives from
&lt;code>genericRegionCoupledFlux&amp;lt;scalar&amp;gt;&lt;/code> (and so from &lt;code>fixedGradient&lt;/code>). It fixes the
patch-normal gradient so that the local diffusive flux is equal and opposite
to the flux of the value-side partner, i.e. flux continuity without a source
at the interface. It does not check the interface type and is normally used
with &lt;code>defaultInterface&lt;/code>. The partner on the neighbour patch must be a
&lt;code>genericRegionCoupledJump&amp;lt;scalar&amp;gt;&lt;/code>-derived BC, usually
&lt;code>regionCoupledScalarJump&lt;/code>.&lt;/p>
&lt;h2 id="mathematical-formulation">Mathematical Formulation&lt;/h2>
&lt;p>Let $F$ be this patch and $J$ the neighbour (jump-side) patch:&lt;/p>
$$
\Gamma_F \frac{\partial \phi_F}{\partial n_F} + \Gamma_J \frac{\partial \phi_J}{\partial n_J} = 0
\quad \text{on } \Gamma
$$
&lt;p>imposed as the gradient&lt;/p>
$$
\left.\frac{\partial \phi_F}{\partial n}\right|_b
= -\frac{\mathcal{I}_{J\to F}\!\left(\Gamma_J\, \partial_n \phi_J\right)}{\Gamma_F}
$$
&lt;p>followed by relaxation with the acceleration model. &lt;code>fluxJump()&lt;/code> returns zero.&lt;/p>
&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>$\phi$&lt;/td>
&lt;td>Coupled scalar field (same name in both regions)&lt;/td>
&lt;td>field-dependent&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$\Gamma_F$&lt;/td>
&lt;td>Diffusivity named by this BC&amp;rsquo;s &lt;code>diffusivity&lt;/code>&lt;/td>
&lt;td>field-dependent&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$\Gamma_J\,\partial_n\phi_J$&lt;/td>
&lt;td>&lt;code>flux()&lt;/code> of the jump-side partner, with the partner&amp;rsquo;s &lt;code>diffusivity&lt;/code>&lt;/td>
&lt;td>field-dependent&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$\mathcal{I}_{J\to F}$&lt;/td>
&lt;td>Interface-to-interface interpolation&lt;/td>
&lt;td>–&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="implementation">Implementation&lt;/h2>
&lt;p>Everything except &lt;code>fluxJump()&lt;/code> is inherited from
&lt;code>genericRegionCoupledFlux&amp;lt;scalar&amp;gt;&lt;/code>. In each DNA iteration &lt;code>updateCoeffs()&lt;/code>
updates the interface, &lt;code>refCast&lt;/code>s the neighbour patch field to
&lt;code>genericRegionCoupledJumpFvPatchField&amp;lt;scalar&amp;gt;&lt;/code>, takes its &lt;code>flux()&lt;/code>,
interpolates and negates it, adds &lt;code>fluxJump()&lt;/code> (= 0), divides by the local
&lt;code>diffCoeff()&lt;/code>, relaxes the gradient and fixes it. &lt;code>evaluate()&lt;/code> sets the
patch value from the gradient with optional non-orthogonal and second-order
corrections. The flux residual
$|\Gamma_F\,g_F + \mathcal{I}(q_J)|$ is checked against &lt;code>maxFluxRes&lt;/code>.&lt;/p>
&lt;h2 id="dictionary-entries">Dictionary Entries&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Keyword&lt;/th>
&lt;th>Description&lt;/th>
&lt;th>Required&lt;/th>
&lt;th>Default&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>type&lt;/code>&lt;/td>
&lt;td>&lt;code>regionCoupledScalarFlux&lt;/code>&lt;/td>
&lt;td>yes&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>interfaceType&lt;/code>&lt;/td>
&lt;td>Interface type list, e.g. &lt;code>(defaultInterface)&lt;/code>. Only the first entry is used; any type is accepted.&lt;/td>
&lt;td>yes&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>diffusivity&lt;/code>&lt;/td>
&lt;td>Diffusivity name (&lt;code>volScalarField&lt;/code> or &lt;code>transportProperties&lt;/code> entry)&lt;/td>
&lt;td>effectively yes&lt;/td>
&lt;td>&lt;code>word::null&lt;/code> (lookup fails)&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>neighbourFieldName&lt;/code>&lt;/td>
&lt;td>Read and written, not used&lt;/td>
&lt;td>no&lt;/td>
&lt;td>local field name&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>accType&lt;/code>&lt;/td>
&lt;td>&lt;code>fixed&lt;/code>, &lt;code>aitken&lt;/code> or &lt;code>IQNILS&lt;/code>&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>fixed&lt;/code> (with warning)&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>relax&lt;/code>&lt;/td>
&lt;td>Initial / fixed relaxation factor&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>1.0&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>couplingReuse&lt;/code>&lt;/td>
&lt;td>&lt;code>IQNILS&lt;/code> only: reused time steps&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>0&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>nonOrthCorr&lt;/code>&lt;/td>
&lt;td>Non-orthogonal correction in &lt;code>evaluate()&lt;/code>&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>false&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>secondOrder&lt;/code>&lt;/td>
&lt;td>Second-order value evaluation&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>false&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>gradient&lt;/code>&lt;/td>
&lt;td>Initial gradient; if given, the initial patch value is evaluated from it&lt;/td>
&lt;td>no&lt;/td>
&lt;td>zero&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>value&lt;/code>&lt;/td>
&lt;td>Not read (only written)&lt;/td>
&lt;td>no&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="usage">Usage&lt;/h2>
&lt;p>From &lt;code>tutorials/electrochemistry/NTGKBatteryWithTabs/0/negTabRegion/orig/partitioned/T&lt;/code>
(flux side on the tab):&lt;/p>
&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">toCellFromNeg
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> type regionCoupledScalarFlux;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> interfaceType (defaultInterface);
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> diffusivity &amp;#34;k&amp;#34;;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> secondOrder false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> nonOrthCorr false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> value $internalField;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">}
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Partner in &lt;code>0/batteryRegion/orig/partitioned/T&lt;/code>:&lt;/p>
&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">toNegTab
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> type regionCoupledScalarJump;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> interfaceType (defaultInterface);
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> diffusivity &amp;#34;k&amp;#34;;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> accType aitken;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> relax 0.75;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> secondOrder false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> nonOrthCorr false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> value $internalField;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">}
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>The &lt;code>regionInterfaceProperties&lt;/code> (&lt;code>cellToNegTab&lt;/code>, &lt;code>defaultInterface&lt;/code>,
&lt;code>coupledFields (phiPos phiNeg T)&lt;/code>) and the &lt;code>DNA&lt;/code> entries are shown in
&lt;code>regionCoupledScalarJump&lt;/code>. In this tutorial &lt;code>k&lt;/code> is a uniform entry in the
&lt;code>transportProperties&lt;/code> of the &lt;code>NTGK&lt;/code> and &lt;code>conductPotentialTemperature&lt;/code>
regions.&lt;/p>
&lt;h2 id="known-limitations">Known Limitations&lt;/h2>
&lt;ul>
&lt;li>&lt;strong>Partner must be a jump BC&lt;/strong> of the same field (bad-cast error
otherwise).&lt;/li>
&lt;li>&lt;strong>&lt;code>diffusivity&lt;/code> must be set&lt;/strong>; the default &lt;code>word::null&lt;/code> lookup fails.&lt;/li>
&lt;li>&lt;strong>No interfacial source.&lt;/strong> &lt;code>fluxJump()&lt;/code> is always zero. Use a derived BC
with its own &lt;code>fluxJump()&lt;/code> (e.g. &lt;code>regionCoupledPhaseChangeHeatFlux&lt;/code>) for a
flux jump.&lt;/li>
&lt;li>&lt;strong>No consistency check&lt;/strong> between the diffusivities named on the two
sides.&lt;/li>
&lt;li>&lt;strong>&lt;code>value&lt;/code> is ignored on input&lt;/strong> and &lt;strong>&lt;code>gradient&lt;/code> is not written&lt;/strong>. On
restart the coupled gradient starts from zero unless &lt;code>gradient&lt;/code> is given.&lt;/li>
&lt;li>&lt;strong>First relaxation uses the patch values as reference&lt;/strong> (inherited; only
matters with &lt;code>relax&lt;/code> ≠ 1 or &lt;code>aitken&lt;/code>/&lt;code>IQNILS&lt;/code> on this side).&lt;/li>
&lt;li>Inherited from &lt;code>genericRegionCoupledFlux&lt;/code>: &lt;code>neighbourFieldName&lt;/code> unused,
&lt;code>nonOrthCorr&lt;/code>/&lt;code>secondOrder&lt;/code> only in the evaluated value, &lt;code>IQNILS&lt;/code> not
parallel-consistent, partitioned only.&lt;/li>
&lt;/ul>
&lt;h2 id="tutorials">Tutorials&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Tutorial&lt;/th>
&lt;th>Description&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>tutorials/electrochemistry/NTGKBatteryWithTabs&lt;/code>&lt;/td>
&lt;td>&lt;code>phiPos&lt;/code>: flux side on the battery (&lt;code>diffusivity sigmaPos&lt;/code>, initial &lt;code>gradient uniform 0.1266&lt;/code>). &lt;code>phiNeg&lt;/code>: flux side on the negative tab (&lt;code>diffusivity sigma&lt;/code>). &lt;code>T&lt;/code>: flux side on both tabs (&lt;code>diffusivity k&lt;/code>). All with &lt;code>defaultInterface&lt;/code> and &lt;code>directMap&lt;/code>.&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><item><title>Docs: regionCoupledScalarJump</title><link>https://multiphysicsfoam.com/docs/user-guide/boundary-conditions/coupled-boundary-conditions/regioncoupledscalarjump/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://multiphysicsfoam.com/docs/user-guide/boundary-conditions/coupled-boundary-conditions/regioncoupledscalarjump/</guid><description>
&lt;h2 id="overview">Overview&lt;/h2>
&lt;p>&lt;code>regionCoupledScalarJump&lt;/code> is the concrete scalar value side (Dirichlet side)
of the partitioned DNA coupling. It derives from
&lt;code>genericRegionCoupledJump&amp;lt;scalar&amp;gt;&lt;/code> (and so from &lt;code>fixedValue&lt;/code>). It fixes the
patch value to the neighbour value interpolated onto this patch, scaled by a
jump (partition) coefficient $c$, which defaults to 1, i.e. continuity. It does
not check the interface type, so it works with any interface, in practice
&lt;code>defaultInterface&lt;/code>. It is the generic choice for potentials, temperatures
and concentrations that need no interface physics. The partner on the
neighbour patch is &lt;code>regionCoupledScalarFlux&lt;/code> (or any other
&lt;code>genericRegionCoupledFlux&amp;lt;scalar&amp;gt;&lt;/code>-derived BC, e.g.
&lt;code>regionCoupledPhaseChangeHeatFlux&lt;/code>).&lt;/p>
&lt;h2 id="mathematical-formulation">Mathematical Formulation&lt;/h2>
&lt;p>Let $J$ be this patch and $F$ the neighbour (flux-side) patch:&lt;/p>
$$
\phi_J = c\;\mathcal{I}_{F\to J}(\phi_F) \quad \text{on } \Gamma
$$
&lt;p>implemented as $\phi_J = \mathcal{I}_{F\to J}(\phi_F) + j$ with the value jump&lt;/p>
$$
j = \mathcal{I}_{F\to J}(\phi_F)\,(c - 1).
$$
&lt;p>The value is then relaxed by the acceleration model. The flux handed to the
partner is&lt;/p>
$$
q_J = \Gamma_J \left.\frac{\partial \phi_J}{\partial n}\right|_b
$$
&lt;p>with the coupled &lt;code>snGrad&lt;/code> of &lt;code>genericRegionCoupledJump&lt;/code> (optional
non-orthogonal and second-order corrections).&lt;/p>
&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>$\phi$&lt;/td>
&lt;td>Coupled scalar field (same name in both regions)&lt;/td>
&lt;td>field-dependent&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$c$&lt;/td>
&lt;td>Jump (partition) coefficient, keyword &lt;code>jumpCoefficient&lt;/code>&lt;/td>
&lt;td>–&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$\mathcal{I}_{F\to J}$&lt;/td>
&lt;td>Interface-to-interface interpolation&lt;/td>
&lt;td>–&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>$\Gamma_J$&lt;/td>
&lt;td>Diffusivity named by &lt;code>diffusivity&lt;/code>&lt;/td>
&lt;td>field-dependent&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="implementation">Implementation&lt;/h2>
&lt;p>All run-time work (interface lookup, &lt;code>updateCoeffs()&lt;/code>, relaxation, &lt;code>snGrad&lt;/code>,
&lt;code>flux()&lt;/code>, &lt;code>diffCoeff()&lt;/code>, residuals) is inherited from
&lt;code>genericRegionCoupledJump&amp;lt;scalar&amp;gt;&lt;/code>. The class only implements
&lt;code>valueJump()&lt;/code>:&lt;/p>
&lt;ol>
&lt;li>Looks up the neighbour field under the local field name and interpolates
its neighbour patch values onto this patch.&lt;/li>
&lt;li>Determines $c$ per face:
&lt;ul>
&lt;li>if a &lt;code>volScalarField&lt;/code> named &lt;code>jumpCoefficient&lt;/code> is registered on the
&lt;strong>local&lt;/strong> region, its local patch values are used;&lt;/li>
&lt;li>else, if &lt;code>jumpCoefficient&lt;/code> is set, a uniform &lt;code>dimensionedScalar&lt;/code> of that
name is read from the local region&amp;rsquo;s &lt;code>transportProperties&lt;/code>;&lt;/li>
&lt;li>else $c = 1$.&lt;/li>
&lt;/ul>
&lt;/li>
&lt;li>Returns $\mathcal{I}_{F\to J}(\phi_F)\,(c - 1)$.&lt;/li>
&lt;/ol>
&lt;p>&lt;code>valueJump()&lt;/code> is evaluated in &lt;code>updateCoeffs()&lt;/code> and again in each residual
evaluation (jump residual $|\phi_J - \mathcal{I}(\phi_F) - j|$, checked
against &lt;code>maxJumpRes&lt;/code>).&lt;/p>
&lt;h2 id="dictionary-entries">Dictionary Entries&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Keyword&lt;/th>
&lt;th>Description&lt;/th>
&lt;th>Required&lt;/th>
&lt;th>Default&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>type&lt;/code>&lt;/td>
&lt;td>&lt;code>regionCoupledScalarJump&lt;/code>&lt;/td>
&lt;td>yes&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>interfaceType&lt;/code>&lt;/td>
&lt;td>Interface type list, e.g. &lt;code>(defaultInterface)&lt;/code>. Only the first entry is used to find the interface; any type is accepted.&lt;/td>
&lt;td>yes&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>diffusivity&lt;/code>&lt;/td>
&lt;td>Diffusivity name (&lt;code>volScalarField&lt;/code> or &lt;code>transportProperties&lt;/code> entry) used by &lt;code>flux()&lt;/code> for the partner&lt;/td>
&lt;td>effectively yes&lt;/td>
&lt;td>&lt;code>word::null&lt;/code> (lookup fails)&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>jumpCoefficient&lt;/code>&lt;/td>
&lt;td>Name of the partition-coefficient field / &lt;code>transportProperties&lt;/code> entry&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>word::null&lt;/code> → $c = 1$&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>neighbourFieldName&lt;/code>&lt;/td>
&lt;td>Read and written, not used&lt;/td>
&lt;td>no&lt;/td>
&lt;td>local field name&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>accType&lt;/code>&lt;/td>
&lt;td>&lt;code>fixed&lt;/code>, &lt;code>aitken&lt;/code> or &lt;code>IQNILS&lt;/code>&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>fixed&lt;/code> (with warning)&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>relax&lt;/code>&lt;/td>
&lt;td>Initial / fixed relaxation factor&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>1.0&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>couplingReuse&lt;/code>&lt;/td>
&lt;td>&lt;code>IQNILS&lt;/code> only: reused time steps&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>0&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>nonOrthCorr&lt;/code>&lt;/td>
&lt;td>Non-orthogonal correction of &lt;code>snGrad&lt;/code>&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>false&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>secondOrder&lt;/code>&lt;/td>
&lt;td>Second-order &lt;code>snGrad&lt;/code>&lt;/td>
&lt;td>no&lt;/td>
&lt;td>&lt;code>false&lt;/code>&lt;/td>
&lt;/tr>
&lt;tr>
&lt;td>&lt;code>value&lt;/code>&lt;/td>
&lt;td>Initial patch value (read if present, otherwise uninitialised)&lt;/td>
&lt;td>effectively yes&lt;/td>
&lt;td>—&lt;/td>
&lt;/tr>
&lt;/tbody>
&lt;/table>
&lt;h2 id="usage">Usage&lt;/h2>
&lt;p>From &lt;code>tutorials/electrochemistry/NTGKBatteryWithTabs/0/posTabRegion/orig/partitioned/phiPos&lt;/code>
(jump side on the tab):&lt;/p>
&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">toCellFromPos
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> type regionCoupledScalarJump;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> interfaceType (defaultInterface);
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> diffusivity &amp;#34;sigma&amp;#34;;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> accType aitken;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> relax 0.1;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> secondOrder false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> nonOrthCorr false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> value $internalField;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">}
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Partner in &lt;code>0/batteryRegion/orig/partitioned/phiPos&lt;/code>:&lt;/p>
&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">toPosTab
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> type regionCoupledScalarFlux;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> interfaceType (defaultInterface);
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> diffusivity &amp;#34;sigmaPos&amp;#34;;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> secondOrder false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> nonOrthCorr false;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> value $internalField;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> gradient uniform 0.1266;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">}
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Interface entry in &lt;code>constant/regionInterfaceProperties&lt;/code>:&lt;/p>
&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">cellToPosTab
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> interfaceType (defaultInterface);
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> coupledPatchPair
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> (
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> (batteryRegion toPosTab)
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> (posTabRegion toCellFromPos)
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> );
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> coupledFields
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> (
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> phiPos
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> phiNeg
&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"> defaultInterfaceCoeffs
&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;/code>&lt;/pre>&lt;/div>&lt;p>and a DNA entry per coupled field in &lt;code>constant/multiRegionProperties&lt;/code>:&lt;/p>
&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">DNA
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl">{
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> phiPos
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> {
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> maxCoupleIter 50;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> residualControl
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> {
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> maxJumpRes 1e-05;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> outputJumpResField no;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> maxFluxRes 1e-05;
&lt;/span>&lt;/span>&lt;span class="line">&lt;span class="cl"> outputFluxResField no;
&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;/code>&lt;/pre>&lt;/div>&lt;p>For a partition coefficient (e.g. Henry&amp;rsquo;s law $C_A = H\,C_B$), add
&lt;code>jumpCoefficient H;&lt;/code> and provide &lt;code>H&lt;/code> either as a &lt;code>volScalarField&lt;/code> on the
jump-side region or as &lt;code>H H [0 0 0 0 0 0 0] 0.5;&lt;/code> in its
&lt;code>transportProperties&lt;/code>.&lt;/p>
&lt;h2 id="known-limitations">Known Limitations&lt;/h2>
&lt;ul>
&lt;li>&lt;strong>No interface-type check.&lt;/strong> Any interface type listed first in
&lt;code>interfaceType&lt;/code> is accepted. The interface&amp;rsquo;s own physics, if any, is not
used, except that its &lt;code>correct()&lt;/code> is called through &lt;code>update()&lt;/code>.&lt;/li>
&lt;li>&lt;strong>&lt;code>diffusivity&lt;/code> must be set.&lt;/strong> The default &lt;code>word::null&lt;/code> makes the
&lt;code>diffCoeff()&lt;/code> lookup in &lt;code>transportProperties&lt;/code> fail as soon as the partner
asks for &lt;code>flux()&lt;/code>.&lt;/li>
&lt;li>&lt;strong>Diffusivities are not checked for consistency.&lt;/strong> Each side uses whatever
its &lt;code>diffusivity&lt;/code> names (in NTGK, &lt;code>sigmaPos&lt;/code> on the battery and &lt;code>sigma&lt;/code> on
the tab). Flux conservation requires the same units on both sides.&lt;/li>
&lt;li>&lt;strong>Jump coefficient is taken from the jump side only&lt;/strong> (local field or local
&lt;code>transportProperties&lt;/code>). With a &lt;code>volScalarField&lt;/code>, the local patch values
are used and not interpolated.&lt;/li>
&lt;li>&lt;strong>&lt;code>jumpCoefficient&lt;/code> is not written&lt;/strong> by &lt;code>write()&lt;/code>, so it disappears from
written time directories and after &lt;code>decomposePar&lt;/code>.&lt;/li>
&lt;li>Inherited limitations of &lt;code>genericRegionCoupledJump&lt;/code>: &lt;code>neighbourFieldName&lt;/code>
unused, side detection by patch name only, &lt;code>IQNILS&lt;/code> not parallel-consistent,
partitioned only.&lt;/li>
&lt;/ul>
&lt;h2 id="tutorials">Tutorials&lt;/h2>
&lt;table>
&lt;thead>
&lt;tr>
&lt;th>Tutorial&lt;/th>
&lt;th>Description&lt;/th>
&lt;/tr>
&lt;/thead>
&lt;tbody>
&lt;tr>
&lt;td>&lt;code>tutorials/electrochemistry/NTGKBatteryWithTabs&lt;/code>&lt;/td>
&lt;td>&lt;code>batteryRegion (NTGK)&lt;/code> coupled to two &lt;code>conductPotentialTemperature&lt;/code> tabs through &lt;code>defaultInterface&lt;/code>. &lt;code>phiPos&lt;/code>: jump side on the positive tab (&lt;code>diffusivity sigma&lt;/code>, Aitken 0.1). &lt;code>phiNeg&lt;/code>: jump side on the battery (&lt;code>diffusivity sigmaNeg&lt;/code>, Aitken 0.75). &lt;code>T&lt;/code>: jump side on the battery at both tabs (&lt;code>diffusivity k&lt;/code>, Aitken 0.75). &lt;code>directMap&lt;/code> transfer.&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>