-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Implement EDFM loading from VTK #3510
Open
paveltomin
wants to merge
57
commits into
develop
Choose a base branch
from
ouassim/edfm_loader
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
57 commits
Select commit
Hold shift + click to select a range
d77d082
initial embedded surface block abc
ouassimkh 35196c8
minor change
ouassimkh 2135a21
start concrete implementation
ouassimkh 7eb79a5
add the cpp
ouassimkh b20dd27
add embedded surfaces to CellBlockManager
ouassimkh 738c14a
this should not be commited
2fcdeed
upate cellBlock Manger and embedded Ruface block
ouassimkh 186a222
Correct edfm to cell type
ouassimkh 2401cc7
corrections
ouassimkh e2346e7
create edfm patches in bulk
ouassimkh c42b37f
small changes
ouassimkh 55239bd
add flag to enable experimentation
ouassimkh 4b2363e
missed files
ouassimkh 0fde8c6
add bulk edfm fracs
ouassimkh dd8d49e
All is running
ouassimkh 2e43180
uncrustify pass
ouassimkh cd555e0
start VTK edfm support
ouassimkh 041d290
Finish EDFM loading from VTK (no parallel)
ouassimkh 3bda862
builds after master rebase issues
ouassimkh 256efee
working serial run
ouassimkh 2d6583d
clearning
ouassimkh 8d52abc
cleraning
ouassimkh c718d96
bug
ouassimkh ba87177
uncrustify pass
ouassimkh 6d70f05
remove comments
ouassimkh c4a913b
use faceBlockName + some fixes for build (#3436)
paveltomin 584a601
add edfm vtk example
ouassimkh 29a20e8
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin 7b9014e
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
rrsettgast 31118bb
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin 5caf9aa
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin c84e27a
build fix
b4a5df4
remove
cec6ed2
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin b079426
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin 3e0357e
doxygen fix
1388970
fix one crash and introduce another
ef54e9c
just to see if test fail because of this
paveltomin 12e1747
fix old edfm cases
9716f90
Merge branch 'Feature/ouassim/edfm_loader_new' of https://github.com/…
a742215
chansing the paralllel issue
b3cee3b
fix global to local mapping
b7cd2b8
Update edfm_vtk_fractures.vtu
paveltomin 71ec173
code style
4fb1ac9
Merge branch 'Feature/ouassim/edfm_loader_new' of https://github.com/…
7784585
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin 4150280
doxygen fix
c3d501a
Update VTKUtilities.hpp
paveltomin 8fc88c1
Update EmbeddedSurfaceBlock.hpp
paveltomin 8384539
Merge branch 'develop' into Feature/ouassim/edfm_loader_new
paveltomin 1bf96de
Merge remote-tracking branch 'origin/develop' into ouassim/edfm_loader
CusiniM b1fa4c4
move creation of EmbeddedFractures upon input.
CusiniM 21f2e06
wip: move things around add useful comments.
CusiniM da7b7fa
moved all needed functions.
CusiniM f1555ab
Fixed CI computation.
CusiniM 1ecec46
fixed compilation issues.
CusiniM e49b685
Merge branch 'develop' into ouassim/edfm_loader
paveltomin File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
78 changes: 78 additions & 0 deletions
78
inputFiles/singlePhaseFlowFractures/edfm_vtk_fractures.vtu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
<?xml version="1.0"?> | ||
<VTKFile type="UnstructuredGrid" version="0.1" byte_order="LittleEndian" header_type="UInt32" compressor="vtkZLibDataCompressor"> | ||
<UnstructuredGrid> | ||
<Piece NumberOfPoints="6" NumberOfCells="2"> | ||
<PointData> | ||
<DataArray type="Int32" Name="fracture_ids_points" NumberOfComponents="1" format="ascii"> | ||
0 | ||
1 | ||
2 | ||
3 | ||
4 | ||
5 | ||
</DataArray> | ||
</PointData> | ||
<CellData GlobalIds="GLOBAL_IDS_CELLS"> | ||
<DataArray type="Int64" IdType="1" Name="GLOBAL_IDS_CELLS" format="ascii" RangeMin="18" RangeMax="19"> | ||
18 19 | ||
</DataArray> | ||
<DataArray type="Int32" Name="fracture_to_parent_matrix_cell_mapping" NumberOfComponents="2" format="ascii"> | ||
18 4 | ||
19 13 | ||
</DataArray> | ||
<DataArray type="Float32" Name="permeability" NumberOfComponents="1" format="ascii" RangeMin="0.1" RangeMax="0.1"> | ||
0.1 | ||
0.1 | ||
</DataArray> | ||
<DataArray type="Float32" Name="aperture" NumberOfComponents="1" format="ascii" RangeMin="0.0001" RangeMax="0.0001"> | ||
0.0001 | ||
0.0001 | ||
</DataArray> | ||
<DataArray type="Float32" Name="tangential_width_vectors" NumberOfComponents="3" format="ascii"> | ||
0 0 1 | ||
0 0 1 | ||
</DataArray> | ||
<DataArray type="Float32" Name="tangential_length_vectors" NumberOfComponents="3" format="ascii"> | ||
0 1 0 | ||
0 1 0 | ||
</DataArray> | ||
<DataArray type="Float32" Name="normal_vectors" NumberOfComponents="3" format="ascii"> | ||
1 0 0 | ||
1 0 0 | ||
</DataArray> | ||
</CellData> | ||
<Points> | ||
<DataArray type="Float32" Name="Points" NumberOfComponents="3" format="ascii" RangeMin="0" RangeMax="1"> | ||
0.5 0.3333 0 | ||
0.5 0.6666 0 | ||
0.5 0.3333 0.5 | ||
0.5 0.6666 0.5 | ||
0.5 0.3333 1 | ||
0.5 0.6666 1 | ||
<InformationKey name="L2_NORM_RANGE" location="vtkDataArray" length="2"> | ||
<Value index="0"> | ||
0 | ||
</Value> | ||
<Value index="1"> | ||
1 | ||
</Value> | ||
</InformationKey> | ||
</DataArray> | ||
</Points> | ||
<Cells> | ||
<DataArray type="Int64" Name="connectivity" format="ascii" RangeMin="0" RangeMax="5"> | ||
1 0 2 3 | ||
3 2 4 5 | ||
</DataArray> | ||
<DataArray type="Int64" Name="offsets" format="ascii" RangeMin="4" RangeMax="8"> | ||
4 | ||
8 | ||
</DataArray> | ||
<DataArray type="UInt8" Name="types" format="ascii" RangeMin="9" RangeMax="9"> | ||
9 | ||
9 | ||
</DataArray> | ||
</Cells> | ||
</Piece> | ||
</UnstructuredGrid> | ||
</VTKFile> |
122 changes: 122 additions & 0 deletions
122
inputFiles/singlePhaseFlowFractures/edfm_vtk_matrix.vtu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
<VTKFile type="UnstructuredGrid" version="1.0" byte_order="LittleEndian" header_type="UInt64"> | ||
<UnstructuredGrid> | ||
<Piece NumberOfPoints="48" NumberOfCells="18"> | ||
<PointData GlobalIds="GLOBAL_IDS_POINTS"> | ||
<DataArray type="Int64" IdType="1" Name="GLOBAL_IDS_POINTS" format="ascii" RangeMin="0" RangeMax="47"> | ||
0 1 2 3 4 5 | ||
6 7 8 9 10 11 | ||
12 13 14 15 16 17 | ||
18 19 20 21 22 23 | ||
24 25 26 27 28 29 | ||
30 31 32 33 34 35 | ||
36 37 38 39 40 41 | ||
42 43 44 45 46 47 | ||
</DataArray> | ||
</PointData> | ||
<CellData GlobalIds="GLOBAL_IDS_CELLS"> | ||
<DataArray type="Int64" Name="split" format="ascii" RangeMin="0" RangeMax="0"> | ||
0 0 0 0 0 0 | ||
0 0 0 0 0 0 | ||
0 0 0 0 0 0 | ||
</DataArray> | ||
<DataArray type="Int64" IdType="1" Name="GLOBAL_IDS_CELLS" format="ascii" RangeMin="0" RangeMax="17"> | ||
0 1 2 3 4 5 | ||
6 7 8 9 10 11 | ||
12 13 14 15 16 17 | ||
</DataArray> | ||
</CellData> | ||
<Points> | ||
<DataArray type="Float32" Name="Points" NumberOfComponents="3" format="ascii" RangeMin="0" RangeMax="1"> | ||
0 0 0 | ||
0.333 0 0 | ||
0.666 0 0 | ||
1 0 0 | ||
0 0.333 0 | ||
0.333 0.333 0 | ||
0.666 0.333 0 | ||
1 0.333 0 | ||
0 0.666 0 | ||
0.333 0.666 0 | ||
0.666 0.666 0 | ||
1 0.666 0 | ||
0 1 0 | ||
0.333 1 0 | ||
0.666 1 0 | ||
1 1 0 | ||
0 0 0.5 | ||
0.333 0 0.5 | ||
0.666 0 0.5 | ||
1 0 0.5 | ||
0 0.333 0.5 | ||
0.333 0.333 0.5 | ||
0.666 0.333 0.5 | ||
1 0.333 0.5 | ||
0 0.666 0.5 | ||
0.333 0.666 0.5 | ||
0.666 0.666 0.5 | ||
1 0.666 0.5 | ||
0 1 0.5 | ||
0.333 1 0.5 | ||
0.666 1 0.5 | ||
1 1 0.5 | ||
0 0 1 | ||
0.333 0 1 | ||
0.666 0 1 | ||
1 0 1 | ||
0 0.333 1 | ||
0.333 0.333 1 | ||
0.666 0.333 1 | ||
1 0.333 1 | ||
0 0.666 1 | ||
0.333 0.666 1 | ||
0.666 0.666 1 | ||
1 0.666 1 | ||
0 1 1 | ||
0.333 1 1 | ||
0.666 1 1 | ||
1 1 1 | ||
<InformationKey name="L2_NORM_RANGE" location="vtkDataArray" length="2"> | ||
<Value index="0"> | ||
0 | ||
</Value> | ||
<Value index="1"> | ||
1.7320508076 | ||
</Value> | ||
</InformationKey> | ||
</DataArray> | ||
</Points> | ||
<Cells> | ||
<DataArray type="Int64" Name="connectivity" format="ascii" RangeMin="0" RangeMax="47"> | ||
0 1 5 4 16 17 21 20 | ||
1 2 6 5 17 18 22 21 | ||
2 3 7 6 18 19 23 22 | ||
4 5 9 8 20 21 25 24 | ||
5 6 10 9 21 22 26 25 | ||
6 7 11 10 22 23 27 26 | ||
8 9 13 12 24 25 29 28 | ||
9 10 14 13 25 26 30 29 | ||
10 11 15 14 26 27 31 30 | ||
16 17 21 20 32 33 37 36 | ||
17 18 22 21 33 34 38 37 | ||
18 19 23 22 34 35 39 38 | ||
20 21 25 24 36 37 41 40 | ||
21 22 26 25 37 38 42 41 | ||
22 23 27 26 38 39 43 42 | ||
24 25 29 28 40 41 45 44 | ||
25 26 30 29 41 42 46 45 | ||
26 27 31 30 42 43 47 46 | ||
</DataArray> | ||
<DataArray type="Int64" Name="offsets" format="ascii" RangeMin="8" RangeMax="144"> | ||
8 16 24 32 40 48 | ||
56 64 72 80 88 96 | ||
104 112 120 128 136 144 | ||
</DataArray> | ||
<DataArray type="UInt8" Name="types" format="ascii" RangeMin="12" RangeMax="12"> | ||
12 12 12 12 12 12 | ||
12 12 12 12 12 12 | ||
12 12 12 12 12 12 | ||
</DataArray> | ||
</Cells> | ||
</Piece> | ||
</UnstructuredGrid> | ||
</VTKFile> |
137 changes: 137 additions & 0 deletions
137
inputFiles/singlePhaseFlowFractures/fractureMatrixFlow_edfm_vtk.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
<?xml version="1.0" ?> | ||
|
||
<Problem> | ||
<Solvers | ||
gravityVector="{ 0.0, 0.0, -9.81 }"> | ||
<SinglePhaseFVM | ||
name="SinglePhaseFlow" | ||
logLevel="1" | ||
discretization="singlePhaseTPFA" | ||
targetRegions="{ RockMatrix, Fracture }"> | ||
<NonlinearSolverParameters | ||
newtonTol="1.0e-6" | ||
newtonMaxIter="8"/> | ||
<LinearSolverParameters | ||
directParallel="0"/> | ||
</SinglePhaseFVM> | ||
|
||
<EmbeddedSurfaceGenerator | ||
name="SurfaceGenerator" | ||
logLevel="1" | ||
discretization="FE1" | ||
targetRegions="{ RockMatrix, Fracture }" | ||
fractureRegion="Fracture" | ||
mpiCommOrder="1"/> | ||
</Solvers> | ||
|
||
<NumericalMethods> | ||
<FiniteVolume> | ||
<TwoPointFluxApproximation | ||
name="singlePhaseTPFA"/> | ||
</FiniteVolume> | ||
<FiniteElements> | ||
<FiniteElementSpace | ||
name="FE1" | ||
order="1"/> | ||
</FiniteElements> | ||
</NumericalMethods> | ||
|
||
<ElementRegions> | ||
<CellElementRegion | ||
name="RockMatrix" | ||
cellBlocks="{ hexahedra }" | ||
materialList="{ water, rock }"/> | ||
|
||
<SurfaceElementRegion | ||
name="Fracture" | ||
faceBlock = "edfm_vtk_fractures" | ||
defaultAperture="1e-3" | ||
materialList="{ water, fractureFilling }" | ||
subRegionType="embeddedElement"/> | ||
</ElementRegions> | ||
|
||
<Constitutive> | ||
<CompressibleSinglePhaseFluid | ||
name="water" | ||
defaultDensity="1000" | ||
defaultViscosity="0.001" | ||
referencePressure="0.0" | ||
compressibility="0.0" | ||
viscosibility="0.0"/> | ||
|
||
<CompressibleSolidParallelPlatesPermeability | ||
name="fractureFilling" | ||
solidModelName="nullSolid" | ||
porosityModelName="fracturePorosity" | ||
permeabilityModelName="fracturePerm"/> | ||
|
||
<CompressibleSolidConstantPermeability | ||
name="rock" | ||
solidModelName="nullSolid" | ||
porosityModelName="rockPorosity" | ||
permeabilityModelName="rockPerm"/> | ||
|
||
<NullModel | ||
name="nullSolid"/> | ||
|
||
<PressurePorosity | ||
name="rockPorosity" | ||
defaultReferencePorosity="0.1" | ||
referencePressure="0.0" | ||
compressibility="0.0"/> | ||
|
||
<ConstantPermeability | ||
name="rockPerm" | ||
permeabilityComponents="{ 2.0e-15, 2.0e-15, 2.0e-15 }"/> | ||
|
||
<PressurePorosity | ||
name="fracturePorosity" | ||
defaultReferencePorosity="1.00" | ||
referencePressure="0.0" | ||
compressibility="0.0"/> | ||
|
||
<ParallelPlatesPermeability | ||
name="fracturePerm"/> | ||
</Constitutive> | ||
|
||
<FieldSpecifications> | ||
|
||
<FieldSpecification | ||
name="Porosity" | ||
initialCondition="1" | ||
setNames="{ all }" | ||
objectPath="ElementRegions/RockMatrix/hexahedra" | ||
fieldName="rockPorosity_referencePorosity" | ||
scale="0.1"/> | ||
|
||
<FieldSpecification | ||
name="fracPorosity" | ||
initialCondition="1" | ||
setNames="{ all }" | ||
objectPath="ElementRegions/Fracture" | ||
fieldName="fracturePorosity_porosity" | ||
scale="1.00"/> | ||
|
||
<FieldSpecification | ||
name="initialPressure" | ||
initialCondition="1" | ||
setNames="{ all }" | ||
objectPath="ElementRegions/RockMatrix/hexahedra" | ||
fieldName="pressure" | ||
scale="0.0"/> | ||
|
||
<FieldSpecification | ||
name="sourceTerm" | ||
objectPath="ElementRegions/RockMatrix/hexahedra" | ||
fieldName="pressure" | ||
scale="1e7" | ||
setNames="{ source }"/> | ||
|
||
<FieldSpecification | ||
name="sinkTerm" | ||
objectPath="ElementRegions/RockMatrix/hexahedra" | ||
fieldName="pressure" | ||
scale="0.0" | ||
setNames="{ sink }"/> | ||
</FieldSpecifications> | ||
</Problem> |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this ever used? I don't think we use this field. Or is it needed by vtk?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is used internally by VTK to map fracture patches to their nodes. I use it here VtkEmbeddedSurfaceBlockUtilities.cpp