Skip to content
Merged
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
16 changes: 16 additions & 0 deletions modules/elasticity/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,19 @@ if(FEMUTILS_HAS_SOLVER_BACKEND_PETSC)
-A,//fem/solution-comparison-file=check/elasticity_traction_bodyforce_bar.quad.txt
inputs/bar.2D.traction.bodyforce.quad.arc)

add_test(NAME [elasticity]2D_Dirichlet_cartesian COMMAND Elasticity
-A,//fem/solution-comparison-file=check/bar.2D.cartesian.Dirichlet.bodyForce.txt
inputs/bar.2D.cartesian.Dirichlet.bodyForce.arc)

add_test(NAME [elasticity]bar_parse_and_exit COMMAND Elasticity
-A,//fem/assemble-linear-system=false
-A,//fem/solve-linear-system=false
inputs/bar.2D.arc)

add_test(NAME [elasticity]3D_Dirichlet_cartesian COMMAND Elasticity
-A,//fem/solution-comparison-file=check/bar.3D.cartesian.Dirichlet.bodyForce.txt
inputs/bar.3D.cartesian.Dirichlet.bodyForce.arc)

add_test(NAME [elasticity]3D_Dirichlet_bodyforce_hexa COMMAND Elasticity
-A,//fem/solution-comparison-file=check/3D_dirichlet_bodyforce.hexa.txt
inputs/3D.dirichlet.bodyforce.hexa.arc)
Expand Down Expand Up @@ -175,6 +183,14 @@ if(FEMUTILS_HAS_SOLVER_BACKEND_PETSC)
-A,//fem/solution-comparison-file=check/test_elasticity_results.txt
-A,//fem/boundary-conditions/dirichlet/enforce-Dirichlet-method=RowColumnElimination
inputs/bar.2D.arc)

add_test(NAME [elasticity]Dirichlet_cartesian_2p COMMAND ${MPIEXEC_EXECUTABLE} -n 2 ./Elasticity
-A,//fem/solution-comparison-file=check/bar.2D.cartesian.Dirichlet.bodyForce.txt
inputs/bar.2D.cartesian.Dirichlet.bodyForce.arc)

add_test(NAME [elasticity]3D_Dirichlet_cartesian_2p COMMAND ${MPIEXEC_EXECUTABLE} -n 2 ./Elasticity
-A,//fem/solution-comparison-file=check/bar.3D.cartesian.Dirichlet.bodyForce.txt
inputs/bar.3D.cartesian.Dirichlet.bodyForce.arc)
endif()
endif()

Expand Down
33 changes: 33 additions & 0 deletions modules/elasticity/check/bar.2D.cartesian.Dirichlet.bodyForce.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
0 8.0064062295911014e-27 2.3723021327985032e-27 0
1 0.013756891762350012 0.01555698911366124 0
2 0.026630517653400913 0.056641823869228065 0
3 0.037861469054070479 0.12208424832924299 0
4 0.047623935376293447 0.20846213351173193 0
5 0.055877962062811419 0.31286987231106073 0
6 0.062632713632189238 0.43228338075322031 0
7 0.067886087986112079 0.56370575038597281 0
8 0.071638567304731254 0.70413383944683405 0
9 0.073890040922272957 0.85056593573339989 0
10 0.0746405345125635 0.99999999999999989 0
11 -4.4120682326440819e-32 -3.943987464834752e-27 0
12 -3.8374894682216023e-08 0.013908908563276439 0
13 -7.7035651517652771e-08 0.055551171208090257 0
14 -1.096545898259127e-07 0.12104513703688911 0
15 -1.3822488462103379e-07 0.20759060089421802 0
16 -1.6235808939650968e-07 0.31213930241909726 0
17 -1.8210643745415583e-07 0.43169987858846243 0
18 -1.9746662455268483e-07 0.56326791563159384 0
19 -2.0843800511248949e-07 0.70384199325425756 0
20 -2.150208705316076e-07 0.8504200046321797 0
21 -2.172151555115487e-07 0.99999999999999989 0
22 -8.0064571089083509e-27 2.3723284992874597e-27 0
23 -0.013756970737749631 0.015557007345367153 0
24 -0.026630670507927019 0.056641837208414474 0
25 -0.037861688086121711 0.12208426027924697 0
26 -0.047624211379992454 0.20846214376045599 0
27 -0.055878286353389386 0.31286988084173539 0
28 -0.062633077418684707 0.43228338758039653 0
29 -0.067886482492577255 0.56370575550590607 0
30 -0.071638983754100286 0.70413384286017155 0
31 -0.073890470537343725 0.85056593744006748 0
32 -0.074640968516208342 0.99999999999999989 0
31 changes: 31 additions & 0 deletions modules/elasticity/check/bar.3D.cartesian.Dirichlet.bodyForce.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
0 7.7700902941794504e-29 2.2618243469203384e-29 6.8768219899362665e-29
1 0.013491379687793507 0.014841847772143174 0.0010392840652825876
2 0.026487552677058813 0.055573881744004898 0.00069720853324282603
3 0.03780008825370821 0.12077651558682061 0.00065738990125176872
4 0.047626001162942119 0.20707334643407968 0.00055414244167348379
5 0.055938431044721869 0.31152070998513282 0.00046345832897524178
6 0.062739193294142473 0.43107805513225761 0.00037060350498843822
7 0.068028931970547629 0.56272669968228561 0.00027750151629013948
8 0.071807576108579865 0.70344375882423915 0.00018714835578265493
9 0.07407116857037381 0.85020321070525695 8.4492338780060229e-05
10 0.074848749700326178 0.99999999999999989 3.4364118296371063e-05
11 -4.7428417705605954e-34 -3.8217941461143502e-29 -6.1701766633215602e-34
12 -4.0653523802303174e-08 0.013705502884576091 -2.991485050399951e-09
13 -8.2451067674128873e-08 0.05480730849186019 -2.0283340543796139e-09
14 -1.1792762219475829e-07 0.12005196691654471 -1.880878014982167e-09
15 -1.4890186882805437e-07 0.20646465248651025 -1.5990079645346629e-09
16 -1.7509558945790663e-07 0.31101051313111644 -1.3331030061557807e-09
17 -1.9652182209573149e-07 0.43067064791242937 -1.0670485689632048e-09
18 -2.1318949793250934e-07 0.56242085531052988 -7.9869382677107955e-10
19 -2.2509497339821189e-07 0.7032402945649936 -5.3921149441978913e-10
20 -2.3222330566642148e-07 0.85010048641232516 -2.4001641117945786e-10
21 -2.347023329246417e-07 0.99999999999999989 -1.160730340042225e-10
22 -7.7701428904771305e-29 2.2618510404308142e-29 -6.8768845000910579e-29
23 -0.013491462752890808 0.014841861746983624 -0.0010392900287751355
24 -0.026487716662484943 0.055573892290116965 -0.00069721247569551055
25 -0.037800323865188196 0.12077652488575356 -0.000657393725548357
26 -0.047626298629392425 0.20707335444826938 -0.00055414561894466074
27 -0.055938780900207305 0.311520716649129 -0.00046346100045270339
28 -0.06273958600558828 0.43107806046555186 -0.00037060563792665782
29 -0.06802935801501156 0.56272670368358257 -0.00027750311394563918
30 -0.071808025967182026 0.70344376148564336 -0.00018714943437251857
44 changes: 44 additions & 0 deletions modules/elasticity/inputs/bar.2D.cartesian.Dirichlet.bodyForce.arc
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
<?xml version="1.0"?>
<case codename="Elasticity" xml:lang="en" codeversion="1.0">
<arcane>
<title>2D Linear Elasticity With Cartesian Mesh</title>
<timeloop>ElasticityLoop</timeloop>
</arcane>

<arcane-post-processing>
<output-period>1</output-period>
<output>
<variable>U</variable>
</output>
</arcane-post-processing>

<meshes>
<mesh>
<generator name="Cartesian2D" >
<nb-part-x>2</nb-part-x>
<nb-part-y>1</nb-part-y>
<origin>0.0 0.0</origin>
<generate-sod-groups>true</generate-sod-groups>
<x><n>10</n><length>1.0</length></x>
<y><n>2</n><length>0.1</length></y>
</generator>
</mesh>
</meshes>

<fem>
<hex-quad-mesh>true</hex-quad-mesh>
<E>21.0e5</E>
<nu>0.28</nu>
<f>-1.0 NULL</f>
<boundary-conditions>
<dirichlet>
<surface>XMIN</surface>
<value>0.0 0.0</value>
</dirichlet>
<dirichlet>
<surface>XMAX</surface>
<value>NULL 1.0</value>
</dirichlet>
</boundary-conditions>
</fem>
</case>
46 changes: 46 additions & 0 deletions modules/elasticity/inputs/bar.3D.cartesian.Dirichlet.bodyForce.arc
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0"?>
<case codename="Elasticity" xml:lang="en" codeversion="1.0">
<arcane>
<title>3D Linear Elasticity With Cartesian Mesh</title>
<timeloop>ElasticityLoop</timeloop>
</arcane>

<arcane-post-processing>
<output-period>1</output-period>
<output>
<variable>U</variable>
</output>
</arcane-post-processing>

<meshes>
<mesh>
<generator name="Cartesian3D" >
<nb-part-x>2</nb-part-x>
<nb-part-y>1</nb-part-y>
<nb-part-z>1</nb-part-z>
<origin>0.0 0.0 0.0</origin>
<generate-sod-groups>true</generate-sod-groups>
<x><n>10</n><length>1.0</length></x>
<y><n>2</n><length>0.1</length></y>
<z><n>2</n><length>0.04</length></z>
</generator>
</mesh>
</meshes>

<fem>
<hex-quad-mesh>true</hex-quad-mesh>
<E>21.0e5</E>
<nu>0.28</nu>
<f>-1.0 NULL NULL</f>
<boundary-conditions>
<dirichlet>
<surface>XMIN</surface>
<value>0.0 0.0 0.0</value>
</dirichlet>
<dirichlet>
<surface>XMAX</surface>
<value>NULL 1.0 NULL</value>
</dirichlet>
</boundary-conditions>
</fem>
</case>