forked from SimVascular/svFSI
-
Notifications
You must be signed in to change notification settings - Fork 0
/
svFSI_master.inp
executable file
·1655 lines (1566 loc) · 80.2 KB
/
svFSI_master.inp
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
#---------------------------------------------------------------------
# This is the master input file for svFSI with all possible options
# that the code can read. One may use this file as a reference for
# various commands and options, or as a template and modify it for
# their application.
#
# In general, the input file for svFSI is divided into three parts:
# 1. General simulation parameters
# 2. Mesh information
# 3. Equations
#
# As the name indicates, `General simulation parameters' describe
# the basic parameters about the problem including spatial dimension,
# time step control, file output, option to restart, etc. Mesh data
# is provided in the second part that may also include additional
# information such as domains, fiber orientation, initial values,
# prestress, etc. Finally, information on equations being solved
# is provided that includes the type of equation, coupling,
# boundary conditions, settings for the linear and nonlinear solver,
# and output control.
#
# The input file for svFSI is a scripting code that sets values to
# specific parameters. A colon ":" is used as a separator between
# the keyword and its value. If the parameters being set are single-
# valued constants, you may use a single line structure as,
#
# This is a keyword with value: 1.3
#
# First part, which is the part before ":", is the keyword to the
# parameter, and the second part, which is the part after ":", is the
# value. Keywords can occur in any order in the script.
#
# There are five types of values that a keyword can read:
# o logical (true/false)
# o integer values
# o real/float values
# o strings or characters
# o file paths
# o vector of real or integer values
#
# Some parameters have a range and should be selected from available
# choices only. If a range is required, it is shown by brackets and a
# dash, e.g. [0.0-inf) denotes a real number between 0.0 and
# infinity. In the case that there are limited choices, those
# choices are separated by slash /, e.g. (0/1) means either 0 or
# 1 must be selected. If there is no restriction on the selection,
# then no brackets are used.
#
# For logical false, any of `False', `0', `F', `f', `false' can be
# used. Likewise, for logical true, any of `True', `1', `T', `t',
# true can be used. Real numbers can be formatted as {10.0, 10.0D0,
# 1.e1, 1.D1}. Any line that begins with `#' is treated as a comment.
# You may add comments, have space before keywords or after ":".
#
# If the values to be set are a part of a bigger entity, you need
# to use braces ("{", "}") to mark the scope of that entity. E.g.:
#
# Domain: 1 {
# Density: 0.1 # [epsilon - inf)
# Poisson ratio: 0.35 # [0.0 - (0.5-epsilon)]
# }
#
# In this example, "Domain" is a keyword (i.e., the entity to be
# specified) and "1" refers to the first "Domain". Within this
# entity, "Density" is set to "0.1" and "Poisson ratio" is set to
# "0.35".
#
# Note that the order of lines doesn't matter within each block
# enclosed by "{" and "}". If a keyword doesn't have a default value,
# it has to be specified by the user. For the optional arguments,
# default value is shown.
# For more details, please refer to the examples provided in
# "svFSI-Tests" repository at GitHub. You may also refer to
# READFILES.f for a more complete set of available options.
#---------------------------------------------------------------------
######################################################################
# 1. General parameters
#---------------------------------------------------------------------
# Below are some of the basic and essential parameters for svFSI
Number of spatial dimensions: 2 # [2/3]
Number of time steps: 1000 # [1 - inf)
Time step size: 0.001 # (0 - inf)
#---------------------------------------------------------------------
Spectral radius of infinite time step: 0.5 # [0.0 - 1.0] [DEFAULT: 0.2]
# The code uses the generalized alpha method for time integration
# implemented using Newmark's predictor and multi-step corrector
# strategy. Spectral radius is used to compute parameters for the
# generalized alpha method. A value of 0.0 leads to an over-damped
# system while 1.0 leads to an undamped system. 0.5 is optimal.
#---------------------------------------------------------------------
Starting time step: 0 # [0 - inf) [DEFAULT: 0]
# This is the starting time step value that is usually 0 if the
# simulation is started from 0 or initialized from the restart file
# for a restarted simulation. The users can override by providing
# a specific number as the starting time step. This may be used in
# FSI simulations where an equilibrium flow has already been
# established using rigid walls and the users may want to start FSI
# thereafter.
#---------------------------------------------------------------------
Number of initialization time steps: 10 # (0 - inf) [DEFAULT: 0]
# "Number of initialization time steps" (nITS) could be used to
# initialize the simulation with a reduced time step (= dt/10). This
# is useful to avoid any numerical instability due to zero
# initialization.
#---------------------------------------------------------------------
Continue previous simulation: f # [f/t]
# The above parameter, if set to true, will restart the simulation
# by loading a svFSI compatible restart file. If the file is not
# available, the code will issue a warning and start the simulation
# from 0.
Restart file name: stFile.bin # [DEFAULT: stFile.bin]
# Name of the file to be read for restarting simulations. This must
# be the name of the file and not its path. The code will look for
# this file within the results folder set by the keyword
# "Save results in folder"
Overwrite restart file: t # [f/t] [DEFAULT: f]
# If set to true, restart files will be overwritten. Otherwise, a
# restart file is written to a separate file at a frequency set by
# the keyword "Increment in saving restart files".
Increment in saving restart files: 10 # [1 - inf) [DEFAULT: saveIncr/[10]]
#---------------------------------------------------------------------
Convert BIN to VTK format: f # [t/f] [DEFAULT: f]
# If set to true, the code will read all the available restart files
# and output desired quantities to vtk format for visualization in
# Paraview. This feature will allow modifying output variables at a
# later time if not already written during the original simulation.
# The code will scan for all the restart files in the results folder
# set by the keyword "Save results in folder" at a frequency set by
# "Increment in saving restart files". However, if any restart file
# is not found, the code will skip that time step to the next one.
#---------------------------------------------------------------------
Simulation initialization file path: result001.vtu
# Could be used to initialize variables from vtu format. However,
# caution must be exercised when using this feature as the code will
# only look for state variables such as velocity, pressure, displace-
# ment, temperature, etc. for initialization. It is the user's
# responsibility to make sure that this data is available in the vtu
# file.
#---------------------------------------------------------------------
# Below are some VTK output control parameters
Save results to VTK format: t # [f/t]
Name prefix of saved VTK files: result
Start saving after time step: 20 # [1 - inf) [DEFAULT: 1]
Increment in saving VTK files: 5 # [1 - inf) [DEFAULT: 10]
#---------------------------------------------------------------------
Save averaged results: t # [f/t] [DEFAULT: f]
# Computes time-averaged results from the entire simulation. Note
# that the averaging operation is performed after the last time step
# of the simulation using vtu files written at a frequency specified
# by "Increment in saving VTK files". An error is thrown if a vtu
# file is not found. For cardiovascular simulations, the user should
# ensure that the total number of time steps corresponds to the
# period of the cardiac cycle.
Start averaging from zero: t # [f/t] [DEFAULT: f]
# If set to true, averaging is performed from the first time step to
# the last time step using vtu files written at a frequency specified
# by "Increment in saving VTK files". If set to false, for e.g., when
# a simulation is restarted, averaging starts from the time step when
# the simulation is restarted from. This feature may be useful for
# cases where averaging is desired only for the last cardiac cycle.
#---------------------------------------------------------------------
Save results in folder: foldername # [DEFAULT: *-procs]
#---------------------------------------------------------------------
Searched file name to trigger stop: STOP_SIM [DEFAULT: STOP_SIM]
# If the user wants to terminate a simulation but plans to restart it
# later, instead of abruptly terminating the simulation using
# Ctrl[Cmd]+C or analogous command, the user may create an empty file
# named as, for e.g., STOP_SIM, within the results folder specified
# by "Save results in folder". The code would then come to a clean
# halt by writing a restart file. If an integer value is provided at
# the beginning of the file, the code would then terminate at that
# particular time step. An empty file could be created using Linux
# command `touch' (for e.g., < touch 24-procs/STOP_SIM >).
#---------------------------------------------------------------------
Check IEN order: t # [f/t] [DEFAULT: t]
# Checks for a compatible ordering of the element connectivity.
#---------------------------------------------------------------------
Simulation requires remeshing: f # [f/t] [DEFAULT: f]
# This feature is used for FSI simulation where the fluid mesh is
# deformed. The solver will monitor for the element Jacobian as the
# measure of element distortion, and perform an on-the-fly remeshing
# if Jacobian <= 0. All the data structures will be projected from
# the old mesh to the new mesh and the solver writes information
# related to the new mesh and its new partitioning to the folder,
# ".remesh_tmp_dir" within the results folder set by the
# "Save results in folder" command. The new mesh and its partitioning
# will be used if and when the simulation is restarted. Note that the
# remeshing step could be expensive and depends on the edge size and
# number of processors used. This feature is currently available for
# linear tetrahedral elements only.
#---------------------------------------------------------------------
Colorful terminal output: t # [f/t] [DEFAULT: t]
Use separator in the history file: t # [f/t] [DEFAULT: f]
# If set to true, a separator is added in the screen output and
# history file between each equation when solving multiple equations.
# Below parameters control the level of screen output.
# [Verbose] prints detailed messages to screen and the history file.
# [Warning] prints out warning messages if the code finds unexpected
# behavior or inputs. [Debug] prints out additional information that
# may be used for debugging purposes.
Verbose: t # [f/t] [DEFAULT: t]
Warning: t # [f/t] [DEFAULT: t]
Debug: f # [f/t] [DEFAULT: f]
######################################################################
# 2. Mesh Data:
# Below are the different example formats for reading mesh in svFSI.
# Multiples meshes can be loaded for the same or different equations
# within svFSI. svFSI supports reading multiple mesh formats as noted
# below. Some additional information specific to an equation may also
# be loaded within the mesh attribute such as domains, fiber
# directions, and initial values.
# SimVascular-based vtu/vtp format for mesh/faces is the default
# choice. svFSI supports below element types in vtu/vtp format:
# - line (linear, quadratic)
# - triangle (linear, quadratic)
# - quadrilateral (bilinear, serendipity, biquadratic)
# - tetrahedron (linear, quadratic)
# - hexagonal brick (trilinear, quadratic/serendipity, triquadratic)
# - wedge
# svFSI also supports loading NURBS meshes. Limited support is
# available to import a bilinear quadrilateral mesh from Gambit-based
# ".msh". An option to convert this into a biquadratic mesh is also
# available. svFSI also supports importing mesh in the form of a list
# of nodal coordinates and element connectivity. It is, however, the
# user's responsibility to provide information on faces. The face
# connectivity should include a "GlobalElementID" mapping between the
# face element and the corresponding mesh element to which the face
# belongs.
# Nested keywords "Add mesh" and "Add face" could be used to provide
# paths to the mesh and face files. The users should also provide a
# string-based name for each mesh and face immediately after the
# colon.
#---------------------------------------------------------------------
# Add mesh using vtu/vtp format
Add mesh: mesh_name {
# Path to the mesh file
Mesh file path: ./mesh/mesh-complete.mesh.vtu
# Add multiples faces using "Add face" keyword and provide
# path to the corresponding face mesh file (.vtp format)
Add face: < face_name_1 > {
Face file path: ./mesh/mesh-surfaces/face_1.vtp
}
Add face: face_name_ 2 {
Face file path: ./mesh/mesh-surfaces/face_2.vtp
}
Add face: face_name_3 {
Face file path: ./mesh/mesh-surfaces/face_3.vtp
}
#------------------------------------------------------------------
# DOMAINS: The users should also provide information on domains to
# specify properties for solving the equations. For e.g., density
# and viscosity should be provided for fluid eqn., material
# properties for the solid dynamics eqn., etc. Note that svFSI
# uses bits to identify domains. Therefore, a maximum of 32
# domains are allowed for a 4-byte integer (INT32) system.
# A constant Domain ID may be specified for uniform properties.
Domain: 1
# Domain IDs can also be loaded from file for multiple domains.
# The file can be in vtu format with an element-based data array
# named as, "DOMAIN_ID".
# Domain file path: ./mesh/domains_from_file.vtu
# An ASCII-formatted text file may also be provided for domains.
# Each line of the file must contain an integer-valued domain ID.
# IDs must be provided for all the elements of the mesh. This
# implies that the code expects to match the number of lines with
# the number of elements of the mesh.
# Domain file path: ./mesh/domains_from_file_ASCII.dat
#-----------------------------------------------------------------
# A mesh scaling factor could be optionally applied. For e.g., if
# the parameters are in CGS units while the mesh is in mm-scale, a
# scale factor "0.1" may be used as,
Mesh scale factor: 0.1
#------------------------------------------------------------------
# Additional data may be provided depending on the equation solved
# # For FSI simulations, fluid domain may initialized as:
# Initial pressures file path: ./init/flow_from_rigid_walls.vtu
# Initial velocities file path: ./init/flow_from_rigid_walls.vtu
# # For prestress-based FSI, solid domain may be initialized as:
# Prestress file path: ./init/wall_prestress.vtu
# Initial displacements file path: ./init/wall_disps.vtu
#------------------------------------------------------------------
# # Fiber directions may be loaded for some material models. Fiber
# # direction must be stored at the element level using the data
# # array name, "FIB_DIR", in the vtu format.
# Fiber direction file path: ./mesh/fibers_longitudinal.vtu
# Fiber direction file path: ./mesh/fibers_sheet.vtu
#------------------------------------------------------------------
# Fiber mesh: If the loaded mesh is a one-dimensional network of
# fibers, then the keyword, "Set mesh as fibers" should be set.
# This setting is useful, for e.g., in loading the Purkinje network
# for cardiac electrophysiology simulations.
# Set mesh as fibers: t
#
# Couple 1D fibers to 3D domain:
# For simulating cardiac electrophysiology in a combined model
# of Purkinje fibers and myocardium, additional information is
# needed to couple the gap junction between 1D Purkinje fibers
# and 3D myocardium.
# a. The Purkinje mesh should be set as fibers.
# b. The end nodes of the Purkinje mesh should be loaded as a face.
# c. A projection should be performed between the end-nodes loaded
# as a face, and the endocardial face.
#
# An example is provided below:
# # (a) Load purkinje mesh
# # Add mesh: pfib {
# # Set mesh as fibers: t
# # Mesh file path: mesh/purkinje.vtu
# # Add face: pfib_ends {
# # End nodes face file path: mesh/purkinje_end_nodes.txt
# # }
# # }
#
# # (b) Load myocardium mesh
# # Add mesh: myo {
# # Mesh file path: mesh/myocardium.vtu
# # Add face: endo {
# # Face file path: mesh/mesh-surfaces/myo-endocardium.vtp
# # }
# # Add face: epi {
# # Face file path: mesh/mesh-surfaces/myo-epicardium.vtp
# # }
# # Add face: base {
# # Face file path: mesh/mesh-surfaces/myo-base.vtp
# # }
# # }
#
# # (c) Project Purkinje ends from endocardium
# # Add projection: pfib_ends{
# # Project from face: endo
# # Projection tolerance: -1.0
# # }
#
#------------------------------------------------------------------
# Below command loads the mesh as a shell so that the "shell"
# equation could be solved. This is also required for initializing
# CMM equation using inflation or prestress. See svFSI-Tests for
# more details.
# # Set mesh as shell: t
#
}
#---------------------------------------------------------------------
# Add mesh using position coordinates and connectivity. Face data
# is provided using eBC format where in addition to the face
# connectivity, a mapping "GlobalElementID" should be provided that
# maps the face element to the corresponding mesh element to which
# the face belongs.
Add mesh: msh_from_connectivity_coordinates {
Coordinates file path: ./mesh/mesh.coordinates
Connectivity file path: ./mesh/mesh.connectivity
Domain file path: ./mesh/domains.txt
Add face: face_from_eBC_1 {
Connectivity file (eBC) path: ./mesh/mesh-surfaces/face_1.eBC
}
Add face: face_from_eBC_2 {
Connectivity file (eBC) path: ./MESH/mesh-surfaces/face_2.eBC
}
Add face: face_from_eBC_3 {
Connectivity file (eBC) path: ./MESH/mesh-surfaces/face_3.eBC
}
}
#---------------------------------------------------------------------
# Add a NURBS mesh
Add mesh: NRB_msh {
Mesh scale factor: 10.0 (0 - inf) [DEFAULT: 1.0]
NURBS data file path: ./mesh/nrb.msh
Domain: 3 [0 - 32)
Set direction: 1 {
Number of knot insertion: 10
Inserted knots repetition: 1 [DEFAULT: 1]
Number of Gauss points: 1 [DEFAULT: p+1]
Number of sample points: 3 [DEFAULT: p+1]
Start face name: left_face [DEFAULT: <X,Y,Z>N_<mesh_name>]
End face name: right_face [DEFAULT: <X,Y,Z>P_<mesh_name>]
}
}
#---------------------------------------------------------------------
# Add mesh from a Gambit .msh file. Note that only quadrilateral
# elements are supported using this choice. An option to convert to
# biquadratic element is available.
Add mesh: msh_from_gambit_file {
Gambit mesh file path: ./mesh/gambit_2D_quad.msh
Convert elements to biquadratic elements: t [f/t] [DEFAULT: f]
Set domain: solid {
Domain: 1 [0 - 32)
}
}
#---------------------------------------------------------------------
# Projection for fluid-structure interaction (FSI) simulations:
# svFSI uses a monolithic coupling at the interface between the fluid
# and the solid domains to satisfy the kinematic and dynamic
# conditions. This is achieved through combining the individual faces
# of the fluid and the solid domains at the interface into a single
# face structure. This is performed through a projection step at the
# interface between the meeting faces. Therefore, it is required to
# have a nodal match between the fluid and solid surfaces meshes
# at the interface. Below, the fluid/lumen interface to the solid/
# wall interface as,
Add projection: wall_interface {
Project from face: lumen_interface
}
# Note that face names set using "Add face" keyword have to be used
# for the projection step and not the actual file names/paths.
######################################################################
# 3. Equations
# svFSI is a multiphysics finite element solver. The equation solved
# is specified using the "Add equation" keyword. Below is a list of
# all the equation names and their description:
# |------------------------|---------------------------------------|
# | Name | Description |
# |------------------------|---------------------------------------|
# | heatS/laplace/poisson | unsteady diffusion equation |
# |------------------------|---------------------------------------|
# | heatF/dyeTransport/ | unsteady advection-diffusion |
# | scalarTransport/AD | equation |
# |------------------------|---------------------------------------|
# | lElas | linear elastodynamics equation |
# |------------------------|---------------------------------------|
# | struct | nonlinear elastodynamics equation |
# |------------------------|---------------------------------------|
# | ustruct | nonlinear elastodynamics using |
# | | mixed VMS-stabilized formulation |
# |------------------------|---------------------------------------|
# | stokes | unsteady Stokes equations |
# |------------------------|---------------------------------------|
# | fluid | unsteady viscous incompressible |
# | | fluid flow (Navier-Stokes equations) |
# |------------------------|---------------------------------------|
# | CMM | the coupled momentum method for |
# | | fluid-structure interaction (FSI) |
# |------------------------|---------------------------------------|
# | FSI | FSI using arbitrary Lagrangian- |
# | | Eulerian (ALE) formulation |
# |------------------------|---------------------------------------|
# | mesh | solves a modified lElas for mesh |
# | | motion; should be used with FSI; |
# |------------------------|---------------------------------------|
# | CEP | solves the mono-domain model of |
# | | cardiac electrophysiology |
# |------------------------|---------------------------------------|
# | shell | solves nonlinear thin shell |
# | | mechanics (Kirchhoff-Love theory) |
# |------------------------|---------------------------------------|
#---------------------------------------------------------------------
# Below we will use FSI as an example equation. Note that the code
# mandates a separate equation for "mesh" when one of the equations
# is FSI. Also, if multiple equations are solved and fluid/FSI is
# involved, the code expects fluid/FSI to be always the first
# equation. When FSI is solved, the "mesh" equation should follow
# immediately before using other equations such as "scalarTransport",
# etc.
Add equation: FSI # [heatS/heatF/lElas/struct/ustruct/stokes/fluid/CMM/FSI/mesh/CEP/shell]
{
#------------------------------------------------------------------
# In a multi-equation system, if Coupled is set to true, svFSI
# couples the convergence of the equations. This implies that in a
# time step, the nonlinear iterations are performed on all the
# coupled system of equations till convergence is achieved.
# If set to false, that particular equation is uncoupled implying
# convergence of the uncoupled equation is achieved separately
# within the time step.
Coupled: 1 # [f/t] [DEFAULT: t]
# svFSI uses a full Newton method to achieve convergence of the
# nonlinear system of equations. Parameters for the nonlinear
# Newton-Raphson solver are set below:
Min iterations: 1 # [1 - inf) [DEFAULT: 1]
Max iterations: 5 # [1 - inf) [DEFAULT: 5]
Tolerance: 1e-3 # [0.0 - inf) [DEFAULT: 1e64]
# Note that the tolerance set above is the relative tolerance.
#------------------------------------------------------------------
# Domain parameters:
# Domain parameters are set using the Domain keyword identifying
# the domain ID followed by a nested block of parameters. If the
# mesh comprises a single domain with uniform properties, the
# domain parameters can be simply listed without nesting inside
# "Domain" keyword and the "Equation" setting as the domain
# parameter is not needed.
# For e.g., if the equation is fluid, the domain parameters can be
# listed as,
#
# Density: 1.04
# Viscosity: Constant { Value: 0.04 }
# Backflow stabilization coefficient: 0.2
# Force_X: 0.0
# Force_Y: 0.0
# Force_Z: 981.0
#
# However, if we have multiple domains (for e.g., FSI with fluid
# and solid domains), the parameters have to be nested within the
# Domain keyword. Each "Domain" should also include the type of
# equation being solved.
# The Domain parameters for different types of equations are
# described at the end of the file.
# Fluid domain with constant viscosity (Newtonian)
Domain: 0 {
Equation: fluid
Density: 1.04 # (0 - inf)
Viscosity: Constant { Value: 0.04 }
Backflow stabilization coefficient: 0.1 # [0.0 - inf) [DEFAULT: 0.2]
Force_X: 0.0
Force_Y: 0.0
Force_Z: 981.0
}
# Solid domain modeled as NeoHookean material with a quadratic
# dilational penalty
Domain: 1 {
Equation: struct
Density: 1.0 # (epsilon - inf)
Elasticity modulus: 2.5e6 # (epsilon - inf)
Poisson ratio: 0.35 # [0.0 - 0.5)
Force_Z: 981.0
Constitutive model: nHK
Dilational penalty model: quad
}
#------------------------------------------------------------------
# Linear solver:
# svFSI offers multiple choices for linear solvers and
# preconditioners. While the default package comes with its own
# linear solver (svFSILS), svFSI can also be coupled with Trilinos
# for access to advanced preconditioners. svFSI uses diagonal
# preconditioner by default.
# The following linear solvers are available within svFSI:
# |--------------|----------------------------------------------|
# | *LS name* | Default Equations |
# |--------------|----------------------------------------------|
# | NS / BIPN | Navier-Stokes solver based on bipartition |
# | | method for "fluid" equation |
# |--------------|----------------------------------------------|
# | GMRES | heatF, ustruct, CMM, stokes, and FSI |
# |--------------|----------------------------------------------|
# | CG | heatS, lElas, mesh, struct, shell, and CEP |
# |--------------|----------------------------------------------|
# | BICG | |
# |--------------|----------------------------------------------|
#
# Note that except for NS/BIPN, the remaining linear solvers are
# available with svFSI and Trilinos package.
#
# The following preconditioners are available from Trilinos:
# |-------------------------|-----------------------------------|
# | Trilinos-Diagonal | diagonal preconditioner |
# |-------------------------|-----------------------------------|
# | Trilinos-BlockJacobi | block Jacobi preconditioner |
# |-------------------------|-----------------------------------|
# | Trilinos-ILU | incomplete LU preconditioner |
# |-------------------------|-----------------------------------|
# | Trilinos-ILUT | thresholded ILU preconditioner |
# |-------------------------|-----------------------------------|
# | Trilinos-IC | incomplete Cholesky |
# |-------------------------|-----------------------------------|
# | Trilinos-ICT | thresholded IC preconditioner |
# |-------------------------|-----------------------------------|
# | Trilinos-ML | multilevel smoothed aggregation |
# |-------------------------|-----------------------------------|
#
# Note that Trilinos preconditioners cannot be used with NS/BIPN
# as the linear solver.
#
# Below is an example of NS/BIPN linear solver parameter setting:
LS type: BIPN
{
Tolerance: 1e-3 # (0 - 1.0) [DEFAULT: 0.4 for NS, 0.1 for the GMRES and 0.01 for CG and BICG]
Max iterations: 10 # [1 - inf) [DEFAULT: 10 for NS, 4 for GMRES, 1000 for CG, 500 for BICG]
Krylov space dimension: 50 # [1 - inf) [DEFAULT: 200]
Absolute tolerance: 1e-12 # (0 - 1.0) [DEFAULT: 1e-10]
# Below are additional settings used for NS/BIPN only. These
# are not required for GMRES/CG/BICG
NS-GM tolerance: 1e-3 # (0 - 1.0) [DEFAULT: 0.01]
NS-GM max iterations: 3 # [1 - inf) [DEFAULT: 1]
NS-CG tolerance: 1e-3 # (0 - 1.0) [DEFAULT: 0.2]
NS-CG max iterations: 500 # [1 - inf) [DEFAULT: 500]
}
# Below is a case of using a Trilinos preconditioner with GMRES:
# LS type: GMRES
# {
# Preconditioner: Trilinos-ILUT # [DEFAULT: Trilinos-Diagonal]
# Max iterations: 100 # [1 - inf) [DEFAULT: 4]
# Tolerance: 1e-4 # (0 - 1.0) [DEFAULT: 0.1 for GMRES]
# Krylov space dimension: 50 # [1 - inf) [DEFAULT: 250]
# }
#------------------------------------------------------------------
# Output types and settings:
# svFSI allows three different types of output:
#
# 1. Spatial : these quantities are written to a vtu file
# visualized in Paraview.
#
# 2. B_INT / Boundary_integral : these quantities represent flux
# through all the faces such as velocity flux, energy flux, etc.
#
# 3. V_INT / Volume_integral : these quantities represent volume-
# averaged quantities integrated over domains.
#
# The output variables depends on the equation being solved and
# below is a list of all possible outputs for the corresponding
# equation:
#
# |-----------------------|-------------------------------------|
# | Name | Output Name |
# |-----------------------|-------------------------------------|
# | heatS/laplace/poisson | Temperature, Heat_flux |
# |-----------------------|-------------------------------------|
# | heatF/dyeTransport/ | Temperature, Heat_flux |
# | scalarTransport/AD | |
# |-----------------------|-------------------------------------|
# | lElas (p) | Displacement, Stress, Strain |
# | | |
# | lElas | Displacement, VonMises_stress, |
# | | Stress, Strain, Jacobian, Area/ |
# | | Volume, Velocity, Acceleration |
# |-----------------------|-------------------------------------|
# | struct (p) | Displacement, Stress, Cauchy_stress,|
# | | Strain |
# | struct | Displacement, VonMises_stress, |
# | | Stress, Cauchy_stress, Strain, |
# | | Jacobian, Def_grad, Area/Volume, |
# | | Fiber_direction, Fiber_alignment, |
# | | Velocity, Acceleration |
# |-----------------------|-------------------------------------|
# | ustruct | Displacement, VonMises_stress, |
# | | Stress, Cauchy_stress, Strain, |
# | | Jacobian, Def_grad, Area/Volume, |
# | | Fiber_direction, Fiber_alignment, |
# | | Velocity, Pressure, Acceleration, |
# | | Divergence |
# |-----------------------|-------------------------------------|
# | stokes | Velocity, Pressure, WSS, Vorticity, |
# | | Traction, Strain_invariants, |
# | | Viscosity, Divergence |
# |-----------------------|-------------------------------------|
# | fluid | Velocity, Pressure, WSS, Traction, |
# | | Vorticity, Vortex, Energy_flux, |
# | | Strain_invariants, Acceleration, |
# | | Viscosity, Divergence |
# |-----------------------|-------------------------------------|
# | CMM (i) | Displacement |
# | CMM (p) | Displacement, Stress |
# | CMM | Velocity, Pressure, Displacement, |
# | | WSS, Vorticity, Vortex, Energy_flux,|
# | | Strain_invariants, Acceleration, |
# | | Traction, Viscosity, Divergence |
# |-----------------------|-------------------------------------|
# | FSI | Velocity, Pressure, Displacement, |
# | | VonMises_stress, WSS, Traction, |
# | | Vorticity, Vortex, Energy_flux, |
# | | Strain_invariants, Viscosity, |
# | | Absolute_velocity, Stress, Strain, |
# | | Cauchy_stress, Jacobian, Deg_grad, |
# | | Area/Volume, Fiber_direction, |
# | | Fiber_alignment, Divergence, |
# | | Acceleration |
# |-----------------------|-------------------------------------|
# | mesh | Displacement, Velocity, Acceleration|
# |-----------------------|-------------------------------------|
# | CEP | Action_potential |
# |-----------------------|-------------------------------------|
# | shell | Displacement, Velocity, Area |
# |-----------------------|-------------------------------------|
#
# In the above equations, "lElas (p)/struct (p)" indicates that
# prestress is solved. "CMM (i)" indicates that CMM is initialized
# using inflation whereas "CMM (p)" indicates that CMM is
# initialized using prestress approach.
#
Output: Spatial {
Pressure: t
Velocity: t
Displacement: f
WSS: t
}
Output: Boundary_integral {
Velocity: t
Pressure: t
Energy_flux: t
}
Output: Volume_integral {
Velocity: t
Pressure: t
}
# If multiple equations are solved (e.g., FSI, 3 Laplace eqns.
# with different boundary conditions or source terms, etc.),
# the naming of output variables could be changed so that the
# vtu file has an appropriate name when visualized in Paraview.
# If the vtu file has data arrays with identical names, Paraview
# will display only the first occurrence. The "Alias" keyword
# will allow users to provide custom names to output data.
#
# # Output: Alias {
# # Displacement: Displacement_fs
# # }
#
# # Output: Alias { Temperature: Temperature_Eq_1 }
#
#------------------------------------------------------------------
# Boundary conditions (BCs):
# BCs are an integral part of the problem and svFSI has
# multiple options to set BCS. BCs are set on a face using the
# "Add BC" keyword tagged to the face-name and followed by a nested
# set of commands. The basic types include:
#
# |-------------------|-----------------------------------------|
# | Boundary Condition "Type" |
# |-------------------|-----------------------------------------|
# | Dirichlet / Dir | sets values on the state variable |
# |-------------------|-----------------------------------------|
# | Neumann / Neu | imposes a normal force on the face |
# |-------------------|-----------------------------------------|
# | Traction / Trac | applied force can be along any direction|
# |-------------------|-----------------------------------------|
# | Robin / Rbn | force from a spring-mass-damper |
# |-------------------|-----------------------------------------|
# | Coupled Momentum | identifies the face to be treated |
# | / CMM | using coupled momentum method (CMM) |
# |-------------------|-----------------------------------------|
#
# Further, users can provide both temporal and spatial distribution
# using "Time dependence" and "Profile" keywords. For e.g.,
#
# Add BC: face_1 {
# Type: Dirichlet
# Time dependence: Steady
# Value: 10.0
# Profile: Parabolic
# }
#
# where we are setting a Parabolic profile and a constant value
# of the state variable on the face "face_1". The state variable
# refers to the unknown of the equation. For e.g., velocity is the
# state variable for fluid.
#
# Below is a list of state variables on which a Dirichlet BC is
# applied depending on the equation:
#
# |-------------------|-----------------------------------------|
# | "State Variable" | "Equations" |
# |-------------------|-----------------------------------------|
# | velocity | stokes, fluid, ustruct, CMM, FSI |
# |-------------------|-----------------------------------------|
# | displacement | lElas, struct, shell, mesh |
# |-------------------|-----------------------------------------|
# | temperature | heatS, heatF |
# |-------------------|-----------------------------------------|
# | action_potential | CEP |
# |-------------------|-----------------------------------------|
#
#-------------- Time Dependence Settings Description ------------|
#
# Below are the options available for setting "Time dependence":
# - Steady : [DEFAULT] A constant value is imposed on the state
# variable. The code expects to read a "Value" command that is
# usually a scalar value or a vector such as,
#
# Value: 10.0 # for scalar value (Dirichlet/Neumann)
# Value: {1.0, -1.0, 0.0} # for vector valued (Traction)
#
# - Unsteady : A file input is expected to set an unsteady boundary
# condition. The file can contain time-dependent values of the
# state variable itself, or the Fourier coefficients from an
# interpolation fit could be directly provided as input.
#
# Temporal values file path: unsteady_BC_values.dat
# Fourier coefficients file path: unsteady_BC_fcs.dat
#
# If temporal values are provided as input, the code computes
# Fourier modes internally to interpolate data at intermediate
# time points. The code assumes that the input data is
# periodic with a time period equal to the time point of the
# last data entry.
#
# If the users, however, want to ramp the boundary value
# instead of impulsively starting a simulation with a steady
# value, "Ramp function: t" can be set. The code then reads
# only the first two entries from the input file, linearly
# increments from the first value to the second value, and
# maintains a steady value thereafter. This feature is useful
# for performing quasi-static simulations in solid mechanics.
#
# - Coupled : This indicates that the face is coupled to either
# GenBC or cplBC 0D reduced-order modeling codes.
#
# - Resistance : A resistance value is applied only when a Neu/
# Neumann boundary condition type is used. Resistance value is
# input using the "Value" command. For e.g., "Value : 8850.0".
# Note that a resistance BC can be applied for fluid/CMM/FSI
# equations only.
#
# - RCR/Windkessel : An RCR BC can be applied as a vector input.
# Similar to Resistance BC, an RCR BC can be applied for Neu/
# Neumann BC type, and for fluid/CMM/FSI equations only.
#
# Type: Neu
# Time dependence: RCR
# RCR values: {100.0, 0.1, 1.0e3}
# Distal pressure: 0.0
# Initial pressure: 0.0
#
# The order of "RCR values" is {proximal resistance,
# compliance/capacitance, distal resistance}. Distal and
# initial pressures used to initialize RCR can also be
# specified.
#
# - Spatial : This is allowed for Neumann or Traction BC types
# only where a spatially varying load (pressure/traction) is
# applied by reading a vtp file.
#
# Type: Neu # or Trac
# Time dependence: Spatial
# Spatial values file path: face_pressure_file.vtp
#
# - General : This is the most general type of BC where both the
# spatial and temporal variations are provided in a file. The
# solver can load a SimVascular-compatible "BCt" file such as
# "BCt.vtp" or can be loaded in the form of an ASCII formatted
# text file.
#
# Time dependence: General
# # BCT file path: BCt.vtp
# Temporal and spatial values file path: general_BC.dat
#
# Note that BCT file loading is available for fluid/CMM/FSI
# simulation where only velocity information is loaded. The
# code expects vtp file to have data arrays named as,
# "velocity_<time point>" starting with 0 and should be
# monotonically increasing.
#
#
#------------------- Profile Settings Description -------------|
#
# svFSI allows prescribing a spatial profile for the applied
# boundary condition. Three options are currently available:
#
# - Flat [DEFAULT]
# - Parabolic
# - User_defined
#
# For the "User_defined" setting, the code to load a spatial
# in a file set by the command, "Spatial profile file path".
#
#
#----------------- Additional Settings Description ------------|
#
# Other settings on the boundary conditions include:
#
# 1. Impose flux: [DEFAULT : f] If set to true, the code will
# normalize the spatial profile with the area of the face so
# that an imposed flux value is appropriately converted into
# the state variable. For e.g., "Impose flux: f".
#
# 2. Impose on state variable integral: This setting is typically
# used for applying a Dirichlet BC on the displacement
# degrees of freedom when velocity is the state variable
# (e.g., fluid, CMM, FSI, and ustruct). Note that this flag
# is set to true for lElas/mesh/struct/shell equations.
#
# #------------ Additional Dirichlet BC controls
# 3. Effective direction: This applies to Dirichlet BC only. Users
# can enforce a Dirichlet BC along a particular Cartesian
# coordinate vector. The argument for the keyword
# "Effective direction" is an integer-valued vector denoting
# the Cartesian directions. For e.g.,
# "Effective direction: (1,0,0)" sets a Dir BC along X-axis.
#
# 4. Zero out perimeter: This applies to to Dirichlet BC only.
# Default setting is true for Dirichlet BC. When the flag is
# set to true, the solver will zero out the `ring' formed at
# the conjoining of two faces. The nodal values at the ring
# will then be 0. It is not required that the "zero out
# perimeter" needs to be true on both the meeting faces.
# Setting the flag on either one despite having distinct
# BC types can lead to zeroing out the perimeter. Note that
# for CMM type BC, zero out is required to be true and is
# enforced.
#
# 5. Weakly applied: This applies to to Dirichlet BC only and
# defaults to false. If "Weakly applied" is set to true, the
# Dirichlet BC is applied weakly using augmented Lagrange-
# multiplier formulation. This setting is applied to fluid/
# FSI equations only. Invoking this requires specifying
# penalty parameters using the "Penalty parameter" keyword.
# Directional control can be achieved using "Penalty
# parameter (tangential)" or "Penalty parameter (normal)"
# keywords.
#
# #------------ Additional Neumann BC controls
# 6. Follower pressure load: This applies to Neumann BC only.
# If set to true, the applied load `follows' deformation,
# implying that the magnitude of the load is proportional
# to the surface area during the deformation. The expression
# for applied force becomes, h = -p nA, where p is the
# applied pressure, n is the surface normal in the current
# configuration and A is the magnitude of area in the
# current configuration that changes with deformation.
#
# 7. Undeforming Neu face: This applies to for Neu BC and
# ustruct equation only. If set to true, this setting will
# mimic clamped condition on a specimen routinely done in
# experiments. Clamping will not allow the surface, on which
# the load is applied, to deform.
#
# #------------ Additional Traction BC controls
# 8. Traction values file path: Applicable for Traction BC only.
# Traction can be loaded directly by providing a vtp file
# containing nodally varying traction on the fluid wall.
#
# 9. Traction multiplier: [DEFAULT: 1.0] Applicable for Traction
# BC only. A real/float value can be given as input that
# acts as a scalar multiplier on the traction loaded from a
# vtp file. This setting may be useful when the direction of
# traction needs to be flipped ("Traction multiplier: -1.0").
#
# #------------ Additional Robin BC controls
# 10. Robin BC types involves a spring-mass-damper-type force
# application on the surface upon which Robin BC is applied.
# The mathematical expression evaluates to,
# \sigma.n = -(k*u + c*v + p*n),
# where k is the stiffness parameter and c is the damping
# constant, while u and v are the surface displacement and
# velocity, respectively. p is the external pressure acting
# along normal direction.
# In svFSI, Robin BC is only an extension to the Neumann
# boundary condition and therefore, all the commands for the
# Neumann BC are accepted for Robin BC as well. However,
# additional parameters must be provided for Robin BC that
# include "Stiffness" and "Damping" constants, and whether