Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ jobs:
fail-fast : false
matrix:
include:
# Validates the code-style using uncrustify
# Validates C++ style (uncrustify) and XML formatting (format_xml)
- name: Check code style
BUILD_AND_TEST_ARGS: --test-code-style
# Validates that the documentation generated using doxygen has no hole.
Expand Down
26 changes: 6 additions & 20 deletions examples/GPU/beamBending.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@
discretization="FE1"
targetRegions="{ Region2 }">
<!-- SPHINX_SolidMechanicsSolverEnd -->
<NonlinearSolverParameters
newtonTol="1.0e-6"
newtonMaxIter="8"/>
<NonlinearSolverParameters newtonTol="1.0e-6" newtonMaxIter="8"/>
<LinearSolverParameters
logLevel="1"
solverType="gmres"
Expand Down Expand Up @@ -43,10 +41,7 @@
<!-- This event is applied every cycle, and overrides the
solver time-step request -->
<!-- SPHINX_Execution -->
<PeriodicEvent
name="solverApplications"
forceDt="1.0"
target="/Solvers/lagsolve"/>
<PeriodicEvent name="solverApplications" forceDt="1.0" target="/Solvers/lagsolve"/>

<!-- SPHINX_ExecutionEnd -->
<!-- This event is applied every 5.0e-5s. The targetExactTimestep
Expand All @@ -67,18 +62,13 @@
<!-- SPHINX_FEDiscretization -->
<NumericalMethods>
<FiniteElements>
<FiniteElementSpace
name="FE1"
order="1"/>
<FiniteElementSpace name="FE1" order="1"/>
</FiniteElements>
</NumericalMethods>

<!-- SPHINX_FEDiscretizationEnd -->
<ElementRegions>
<CellElementRegion
name="Region2"
cellBlocks="{ * }"
materialList="{ shale }"/>
<CellElementRegion name="Region2" cellBlocks="{ * }" materialList="{ shale }"/>
</ElementRegions>

<Constitutive>
Expand Down Expand Up @@ -145,12 +135,8 @@

<!-- SPHINX_TableFunctionEnd -->
<Outputs>
<Silo
name="siloOutput"
parallelThreads="32"
childDirectory="sub"/>
<Silo name="siloOutput" parallelThreads="32" childDirectory="sub"/>

<Restart
name="restartOutput"/>
<Restart name="restartOutput"/>
</Outputs>
</Problem>
14 changes: 3 additions & 11 deletions examples/advanced_xml_features/included/included_a.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@
name="SinglePhaseFlow"
discretization="singlePhaseTPFA"
targetRegions="{ Region1 }">
<LinearSolverParameters
solverType="gmres"
krylovTol="1.0e-12"/>
<LinearSolverParameters solverType="gmres" krylovTol="1.0e-12"/>
</SinglePhaseFVM>
</Solvers>

Expand All @@ -27,14 +25,8 @@
</Mesh>

<Geometry>
<Box
name="source"
xMin="{ -0.01, -0.01, -0.01 }"
xMax="{ 1.01, 1.01, 1.01 }"/>
<Box name="source" xMin="{ -0.01, -0.01, -0.01 }" xMax="{ 1.01, 1.01, 1.01 }"/>

<Box
name="sink"
xMin="{ 8.99, -0.01, -0.01 }"
xMax="{ 10.01, 1.01, 1.01 }"/>
<Box name="sink" xMin="{ 8.99, -0.01, -0.01 }" xMax="{ 10.01, 1.01, 1.01 }"/>
</Geometry>
</Problem>
31 changes: 8 additions & 23 deletions examples/advanced_xml_features/included/included_b.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,9 @@
<Problem>
<Events
maxTime="2e4">
<PeriodicEvent
name="outputs"
timeFrequency="1000.0"
target="/Outputs/siloOutput"/>
<PeriodicEvent name="outputs" timeFrequency="1000.0" target="/Outputs/siloOutput"/>

<PeriodicEvent
name="solverApplications"
forceDt="1e3"
target="/Solvers/SinglePhaseFlow"/>
<PeriodicEvent name="solverApplications" forceDt="1e3" target="/Solvers/SinglePhaseFlow"/>

<PeriodicEvent
name="restarts"
Expand All @@ -22,16 +16,12 @@

<NumericalMethods>
<FiniteVolume>
<TwoPointFluxApproximation
name="singlePhaseTPFA"/>
<TwoPointFluxApproximation name="singlePhaseTPFA"/>
</FiniteVolume>
</NumericalMethods>

<ElementRegions>
<CellElementRegion
name="Region1"
cellBlocks="{ * }"
materialList="{ water, rock }"/>
<CellElementRegion name="Region1" cellBlocks="{ * }" materialList="{ water, rock }"/>
</ElementRegions>

<Constitutive>
Expand All @@ -49,25 +39,20 @@
porosityModelName="rockPorosity"
permeabilityModelName="rockPerm"/>

<NullModel
name="nullSolid"/>
<NullModel name="nullSolid"/>

<PressurePorosity
name="rockPorosity"
defaultReferencePorosity="0.05"
referencePressure="0.0"
compressibility="1.0e-9"/>

<ConstantPermeability
name="rockPerm"
permeabilityComponents="{ 2.0e-16, 2.0e-16, 2.0e-16 }"/>
<ConstantPermeability name="rockPerm" permeabilityComponents="{ 2.0e-16, 2.0e-16, 2.0e-16 }"/>
</Constitutive>

<Outputs>
<Silo
name="siloOutput"/>
<Silo name="siloOutput"/>

<Restart
name="restartOutput"/>
<Restart name="restartOutput"/>
</Outputs>
</Problem>
9 changes: 3 additions & 6 deletions examples/advanced_xml_features/included_files_example.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,10 @@ using the following rules:
Otherwise insert the target into the xml structure as-is
-->
<Included>
<File
name="./included/included_a.xml"/>
<File name="./included/included_a.xml"/>

<File
name="./included/included_b.xml"/>
<File name="./included/included_b.xml"/>

<File
name="./included/included_c.xml"/>
<File name="./included/included_c.xml"/>
</Included>
</Problem>
55 changes: 14 additions & 41 deletions examples/advanced_xml_features/parameters_example.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,11 @@ XML Units:
- These use a python-style format e.g. (0.1 [m/s**2])
-->
<Parameters>
<Parameter
name="permeability"
value="2.0e-16"/>
<Parameter name="permeability" value="2.0e-16"/>

<Parameter
name="porosity"
value="0.05"/>
<Parameter name="porosity" value="0.05"/>

<Parameter
name="pressure"
value="5 [MPa]"/>
<Parameter name="pressure" value="5 [MPa]"/>
</Parameters>

<Solvers
Expand All @@ -36,9 +30,7 @@ XML Units:
name="SinglePhaseFlow"
discretization="singlePhaseTPFA"
targetRegions="{ Region1 }">
<LinearSolverParameters
solverType="gmres"
krylovTol="1.0e-12"/>
<LinearSolverParameters solverType="gmres" krylovTol="1.0e-12"/>
</SinglePhaseFVM>
</Solvers>

Expand All @@ -56,28 +48,16 @@ XML Units:
</Mesh>

<Geometry>
<Box
name="source"
xMin="{ -0.01, -0.01, -0.01 }"
xMax="{ 1.01, 1.01, 1.01 }"/>

<Box
name="sink"
xMin="{ 8.99, -0.01, -0.01 }"
xMax="{ 10.01, 1.01, 1.01 }"/>
<Box name="source" xMin="{ -0.01, -0.01, -0.01 }" xMax="{ 1.01, 1.01, 1.01 }"/>

<Box name="sink" xMin="{ 8.99, -0.01, -0.01 }" xMax="{ 10.01, 1.01, 1.01 }"/>
</Geometry>

<Events
maxTime="2e4">
<PeriodicEvent
name="outputs"
timeFrequency="1000.0"
target="/Outputs/siloOutput"/>
<PeriodicEvent name="outputs" timeFrequency="1000.0" target="/Outputs/siloOutput"/>

<PeriodicEvent
name="solverApplications"
forceDt="1e3"
target="/Solvers/SinglePhaseFlow"/>
<PeriodicEvent name="solverApplications" forceDt="1e3" target="/Solvers/SinglePhaseFlow"/>

<PeriodicEvent
name="restarts"
Expand All @@ -88,16 +68,12 @@ XML Units:

<NumericalMethods>
<FiniteVolume>
<TwoPointFluxApproximation
name="singlePhaseTPFA"/>
<TwoPointFluxApproximation name="singlePhaseTPFA"/>
</FiniteVolume>
</NumericalMethods>

<ElementRegions>
<CellElementRegion
name="Region1"
cellBlocks="{ * }"
materialList="{ water, rock }"/>
<CellElementRegion name="Region1" cellBlocks="{ * }" materialList="{ water, rock }"/>
</ElementRegions>

<Constitutive>
Expand All @@ -115,8 +91,7 @@ XML Units:
porosityModelName="rockPorosity"
permeabilityModelName="rockPerm"/>

<NullModel
name="nullSolid"/>
<NullModel name="nullSolid"/>

<PressurePorosity
name="rockPorosity"
Expand All @@ -130,11 +105,9 @@ XML Units:
</Constitutive>

<Outputs>
<Silo
name="siloOutput"/>
<Silo name="siloOutput"/>

<Restart
name="restartOutput"/>
<Restart name="restartOutput"/>
</Outputs>

<FieldSpecifications>
Expand Down
55 changes: 14 additions & 41 deletions examples/advanced_xml_features/symbolic_math_example.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,11 @@ XML Symbolic Math:
- This constraint can be relaxed to allow more complicated functions (sin, cos, etc.)
-->
<Parameters>
<Parameter
name="permeability"
value="2.0e-16"/>
<Parameter name="permeability" value="2.0e-16"/>

<Parameter
name="porosity"
value="0.05"/>
<Parameter name="porosity" value="0.05"/>

<Parameter
name="pressure"
value="5 [MPa]"/>
<Parameter name="pressure" value="5 [MPa]"/>
</Parameters>

<Solvers
Expand All @@ -46,9 +40,7 @@ XML Symbolic Math:
name="SinglePhaseFlow"
discretization="singlePhaseTPFA"
targetRegions="{ Region1 }">
<LinearSolverParameters
solverType="gmres"
krylovTol="1.0e-12"/>
<LinearSolverParameters solverType="gmres" krylovTol="1.0e-12"/>
</SinglePhaseFVM>
</Solvers>

Expand All @@ -66,28 +58,16 @@ XML Symbolic Math:
</Mesh>

<Geometry>
<Box
name="source"
xMin="{ -0.01, -0.01, -0.01 }"
xMax="{ 1.01, 1.01, 1.01 }"/>

<Box
name="sink"
xMin="{ 8.99, -0.01, -0.01 }"
xMax="{ 10.01, 1.01, 1.01 }"/>
<Box name="source" xMin="{ -0.01, -0.01, -0.01 }" xMax="{ 1.01, 1.01, 1.01 }"/>

<Box name="sink" xMin="{ 8.99, -0.01, -0.01 }" xMax="{ 10.01, 1.01, 1.01 }"/>
</Geometry>

<Events
maxTime="2e4">
<PeriodicEvent
name="outputs"
timeFrequency="1000.0"
target="/Outputs/siloOutput"/>
<PeriodicEvent name="outputs" timeFrequency="1000.0" target="/Outputs/siloOutput"/>

<PeriodicEvent
name="solverApplications"
forceDt="1e3"
target="/Solvers/SinglePhaseFlow"/>
<PeriodicEvent name="solverApplications" forceDt="1e3" target="/Solvers/SinglePhaseFlow"/>

<PeriodicEvent
name="restarts"
Expand All @@ -98,16 +78,12 @@ XML Symbolic Math:

<NumericalMethods>
<FiniteVolume>
<TwoPointFluxApproximation
name="singlePhaseTPFA"/>
<TwoPointFluxApproximation name="singlePhaseTPFA"/>
</FiniteVolume>
</NumericalMethods>

<ElementRegions>
<CellElementRegion
name="Region1"
cellBlocks="{ * }"
materialList="{ water, rock }"/>
<CellElementRegion name="Region1" cellBlocks="{ * }" materialList="{ water, rock }"/>
</ElementRegions>

<Constitutive>
Expand All @@ -125,8 +101,7 @@ XML Symbolic Math:
porosityModelName="rockPorosity"
permeabilityModelName="rockPerm"/>

<NullModel
name="nullSolid"/>
<NullModel name="nullSolid"/>

<PressurePorosity
name="rockPorosity"
Expand All @@ -140,11 +115,9 @@ XML Symbolic Math:
</Constitutive>

<Outputs>
<Silo
name="siloOutput"/>
<Silo name="siloOutput"/>

<Restart
name="restartOutput"/>
<Restart name="restartOutput"/>
</Outputs>

<FieldSpecifications>
Expand Down
Loading
Loading