-
Notifications
You must be signed in to change notification settings - Fork 100
feat: electrostatics #3698
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
Open
lihanyu97
wants to merge
25
commits into
develop
Choose a base branch
from
li/electrostatics
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
feat: electrostatics #3698
Changes from all commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
479229a
prototype from laplace
lihanyu97 e303da3
add electrochemistry material model
lihanyu97 b14c914
implement BV term
lihanyu97 ef93c26
Add interface material model
lihanyu97 9540694
2D defect case included
lihanyu97 4a8d605
schema file
lihanyu97 194c869
Merge branch 'develop' into li/electrostatics
lihanyu97 c05b148
Add physics to BV term
lihanyu97 bb6b208
Elastic finite strain material model
lihanyu97 cbd5419
rename
lihanyu97 9c0852e
Merge branch 'develop' into li/electrostatics
lihanyu97 b08bbb5
Compiled successfully
lihanyu97 2d33b3d
delete duplicate files during merge
lihanyu97 8de8e75
correct kirchhoff stress
lihanyu97 91638f2
finite strain kernel compiled
lihanyu97 c1854de
solution converged
lihanyu97 b0b7070
add finite strain cases
lihanyu97 56ab0cb
Merge branch 'develop' into li/electrostatics
lihanyu97 39d7074
fix gcc compiler
lihanyu97 e6cabf0
clean up unused variables
lihanyu97 3e0a7b3
Merge branch 'develop' into li/electrostatics
lihanyu97 263126f
fix styles
lihanyu97 76d75d9
Merge remote-tracking branch 'origin/develop' into li/electrostatics
frankfeifan 37e7f8f
resolve merge conflicts for feOps and bcs
frankfeifan 8ec357c
style and schema
frankfeifan 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
This file contains hidden or 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
This file contains hidden or 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,156 @@ | ||
| <?xml version="1.0" ?> | ||
|
|
||
| <Problem> | ||
|
|
||
| <Solvers> | ||
| <Electrostatics | ||
| name="halfcell" | ||
| discretization="FE1" | ||
| fieldName="potential" | ||
| targetRegions="{Region1, Region2, SEIRegion}"> | ||
| <LinearSolverParameters | ||
| directParallel="0"/> | ||
| </Electrostatics> | ||
|
|
||
| <SurfaceGenerator | ||
| name="SurfaceGen" | ||
| fractureRegion="SEIRegion" | ||
| targetRegions="{ Region1, Region2 }" | ||
| initialRockToughness="1.0e10" | ||
| mpiCommOrder="1"/> | ||
| </Solvers> | ||
|
|
||
| <Mesh> | ||
| <InternalMesh | ||
| name="mesh1" | ||
| elementTypes="{C3D8}" | ||
| xCoords="{0, 5, 10}" | ||
| yCoords="{0, 1}" | ||
| zCoords="{0, 1}" | ||
| nx="{5, 5}" | ||
| ny="{1}" | ||
| nz="{1}" | ||
| cellBlockNames="{electrode, electrolyte}"/> | ||
| </Mesh> | ||
|
|
||
| <Geometry> | ||
| <Box | ||
| name="currentCollector" | ||
| xMin="{ -0.01, -0.01, -0.01 }" | ||
| xMax="{ 0.01, 1.01, 1.01 }"/> | ||
|
|
||
| <Box | ||
| name="ground" | ||
| xMin="{ 9.99, -0.01, -0.01 }" | ||
| xMax="{ 10.01, 1.01, 1.01 }"/> | ||
|
|
||
| <Box | ||
| name="SEI" | ||
| xMin="{ 4.99, -0.01, -0.01 }" | ||
| xMax="{ 5.01, 1.01, 1.01 }"/> | ||
| </Geometry> | ||
|
|
||
| <ElementRegions> | ||
| <CellElementRegion | ||
| name="Region1" | ||
| cellBlocks="{electrode}" | ||
| materialList="{electrodeMaterial}"/> | ||
|
|
||
| <CellElementRegion | ||
| name="Region2" | ||
| cellBlocks="{electrolyte}" | ||
| materialList="{electrolyteMaterial}"/> | ||
|
|
||
| <SurfaceElementRegion | ||
| name="SEIRegion" | ||
| defaultAperture="1.0e-6" | ||
| materialList="{lithium}"/> | ||
| </ElementRegions> | ||
|
|
||
| <Constitutive> | ||
| <ElectroChemistryBase | ||
| name="electrodeMaterial" | ||
| defaultConductivity="100.0"/> | ||
|
|
||
| <ElectroChemistryBase | ||
| name="electrolyteMaterial" | ||
| defaultConductivity="10.0"/> | ||
|
|
||
| <ButlerVolmerInterface | ||
| name="lithium" | ||
| defaultReactivityCoefficient="1.0"/> | ||
| </Constitutive> | ||
|
|
||
| <NumericalMethods> | ||
| <FiniteElements> | ||
| <FiniteElementSpace | ||
| name="FE1" | ||
| order="1"/> | ||
| </FiniteElements> | ||
| </NumericalMethods> | ||
|
|
||
| <Outputs> | ||
| <VTK | ||
| name="vtkOutput"/> | ||
| </Outputs> | ||
|
|
||
| <Events | ||
| maxTime="1.0"> | ||
|
|
||
| <SoloEvent | ||
| name="preInterface" | ||
| target="/Solvers/SurfaceGen"/> | ||
|
|
||
| <PeriodicEvent | ||
| name="solverApplication" | ||
| forceDt="1.0" | ||
| target="/Solvers/halfcell"/> | ||
|
|
||
| <PeriodicEvent | ||
| name="outputs" | ||
| timeFrequency="1.0" | ||
| target="/Outputs/vtkOutput"/> | ||
| </Events> | ||
|
|
||
| <FieldSpecifications> | ||
| <FieldSpecification | ||
| name="groundPotential" | ||
| fieldName="potential" | ||
| objectPath="nodeManager" | ||
| scale="0.0" | ||
| setNames="{ground}"/> | ||
|
|
||
| <Traction | ||
| name="inputCurrent" | ||
| objectPath="faceManager" | ||
| tractionType="normal" | ||
| scale="-1.0" | ||
| functionName="NeumannTimeFunction" | ||
| setNames="{currentCollector}"/> | ||
|
|
||
| <FieldSpecification | ||
| name="sei" | ||
| initialCondition="1" | ||
| setNames="{ SEI }" | ||
| objectPath="faceManager" | ||
| fieldName="ruptureState" | ||
| scale="1"/> | ||
|
|
||
| <FieldSpecification | ||
| name="separableFace" | ||
| initialCondition="1" | ||
| setNames="{ SEI }" | ||
| objectPath="faceManager" | ||
| fieldName="isFaceSeparable" | ||
| scale="1"/> | ||
| </FieldSpecifications> | ||
|
|
||
| <Functions> | ||
| <TableFunction | ||
| name="NeumannTimeFunction" | ||
| inputVarNames="{time}" | ||
| coordinates="{ 0.0, 1.0}" | ||
| values="{ 0.0, -1.0}"/> | ||
| </Functions> | ||
|
|
||
| </Problem> |
173 changes: 173 additions & 0 deletions
173
inputFiles/Electrostatics/Electrostatics_variable_reactivity.xml
This file contains hidden or 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,173 @@ | ||
| <?xml version="1.0" ?> | ||
|
|
||
| <Problem> | ||
|
|
||
| <Solvers> | ||
| <Electrostatics | ||
| name="halfcell" | ||
| discretization="FE1" | ||
| fieldName="potential" | ||
| targetRegions="{Region1, Region2, SEIRegion}"> | ||
| <LinearSolverParameters | ||
| directParallel="0"/> | ||
| </Electrostatics> | ||
|
|
||
| <SurfaceGenerator | ||
| name="SurfaceGen" | ||
| fractureRegion="SEIRegion" | ||
| targetRegions="{ Region1, Region2 }" | ||
| initialRockToughness="1.0e10" | ||
| mpiCommOrder="1"/> | ||
|
|
||
| </Solvers> | ||
|
|
||
| <Mesh> | ||
| <InternalMesh | ||
| name="mesh1" | ||
| elementTypes="{C3D8}" | ||
| xCoords="{0, 5, 10}" | ||
| yCoords="{0, 10}" | ||
| zCoords="{0, 1}" | ||
| nx="{5, 5}" | ||
| ny="{10}" | ||
| nz="{1}" | ||
| cellBlockNames="{electrode, electrolyte}"/> | ||
| </Mesh> | ||
|
|
||
| <Geometry> | ||
| <Box | ||
| name="currentCollector" | ||
| xMin="{ -0.01, -0.01, -0.01 }" | ||
| xMax="{ 0.01, 10.01, 1.01 }"/> | ||
|
|
||
| <Box | ||
| name="ground" | ||
| xMin="{ 9.99, -0.01, -0.01 }" | ||
| xMax="{ 10.01, 10.01, 1.01 }"/> | ||
|
|
||
| <Box | ||
| name="SEITop" | ||
| xMin="{ 4.99, 4.99, -0.01 }" | ||
| xMax="{ 5.01, 10.01, 1.01 }"/> | ||
|
|
||
| <Box | ||
| name="SEIBottom" | ||
| xMin="{ 4.99, -0.01, -0.01 }" | ||
| xMax="{ 5.01, 5.01, 1.01 }"/> | ||
|
|
||
| </Geometry> | ||
|
|
||
| <ElementRegions> | ||
| <CellElementRegion | ||
| name="Region1" | ||
| cellBlocks="{electrode}" | ||
| materialList="{electrodeMaterial}"/> | ||
|
|
||
| <CellElementRegion | ||
| name="Region2" | ||
| cellBlocks="{electrolyte}" | ||
| materialList="{electrolyteMaterial}"/> | ||
|
|
||
| <SurfaceElementRegion | ||
| name="SEIRegion" | ||
| defaultAperture="1.0e-6" | ||
| materialList="{metalSE}"/> | ||
| </ElementRegions> | ||
|
|
||
| <Constitutive> | ||
| <ElectroChemistryBase | ||
| name="electrodeMaterial" | ||
| defaultConductivity="100.0"/> | ||
|
|
||
| <ElectroChemistryBase | ||
| name="electrolyteMaterial" | ||
| defaultConductivity="1.0"/> | ||
|
|
||
| <ButlerVolmerInterface | ||
| name="metalSE" | ||
| defaultReactivityCoefficient="5.0"/> | ||
| </Constitutive> | ||
|
|
||
| <NumericalMethods> | ||
| <FiniteElements> | ||
| <FiniteElementSpace | ||
| name="FE1" | ||
| order="1"/> | ||
| </FiniteElements> | ||
| </NumericalMethods> | ||
|
|
||
| <Outputs> | ||
| <VTK | ||
| name="vtkOutput"/> | ||
| </Outputs> | ||
|
|
||
| <Events | ||
| maxTime="1.0"> | ||
|
|
||
| <SoloEvent | ||
| name="preInterface" | ||
| target="/Solvers/SurfaceGen"/> | ||
|
|
||
| <PeriodicEvent | ||
| name="solverApplication" | ||
| forceDt="1.0" | ||
| target="/Solvers/halfcell"/> | ||
|
|
||
| <PeriodicEvent | ||
| name="outputs" | ||
| timeFrequency="1.0" | ||
| target="/Outputs/vtkOutput"/> | ||
| </Events> | ||
|
|
||
| <FieldSpecifications> | ||
| <FieldSpecification | ||
| name="groundPotential" | ||
| fieldName="potential" | ||
| objectPath="nodeManager" | ||
| scale="0.0" | ||
| setNames="{ground}"/> | ||
|
|
||
| <Traction | ||
| name="inputCurrent" | ||
| objectPath="faceManager" | ||
| tractionType="normal" | ||
| scale="-1.0" | ||
| functionName="NeumannTimeFunction" | ||
| setNames="{currentCollector}"/> | ||
|
|
||
| <FieldSpecification | ||
| name="sei" | ||
| initialCondition="1" | ||
| setNames="{ SEITop, SEIBottom }" | ||
| objectPath="faceManager" | ||
| fieldName="ruptureState" | ||
| scale="1"/> | ||
|
|
||
| <FieldSpecification | ||
| name="separableFace" | ||
| initialCondition="1" | ||
| setNames="{ SEITop, SEIBottom }" | ||
| objectPath="faceManager" | ||
| fieldName="isFaceSeparable" | ||
| scale="1"/> | ||
|
|
||
| <FieldSpecification | ||
| name="SEITopReactivityCoef" | ||
| initialCondition="1" | ||
| setNames="{ SEITop }" | ||
| objectPath="ElementRegions/SEIRegion" | ||
| fieldName="metalSE_reactivityCoefficient" | ||
| scale="0.0"/> | ||
|
|
||
| <!-- This is how you comment in xml --> | ||
| </FieldSpecifications> | ||
|
|
||
| <Functions> | ||
| <TableFunction | ||
| name="NeumannTimeFunction" | ||
| inputVarNames="{time}" | ||
| coordinates="{ 0.0, 1.0}" | ||
| values="{ 0.0, -1.0}"/> | ||
| </Functions> | ||
|
|
||
| </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.
Uh oh!
There was an error while loading. Please reload this page.