!check keywords warn
!echo on
! Name of output files
$name = "Byrd_Prog_"
#MINH=1.0
#directmethod="mumps"
#slc = 0.1
!---LUA BEGIN
! function IfThenElse(condition,t,f)
! if condition then return t else return f end
! end
! assert(loadfile('./icematerial.lua'))()
! assert(loadfile('./accumulation.lua'))()
!---LUA END
Header
Mesh DB "." "teterousse0"
End
Constants
Water Density = Real #rhow*(yearinsec^(-2.0))*Pa2MPa
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Simulation
Coordinate System = Cartesian 3D
Simulation Type = Transient
Extruded Mesh Levels = Integer 9
Timestepping Method = "bdf"
BDF Order = 1
Output Intervals = 1 !#OutPutIntervals
Timestep Intervals = 5 !#Intervals
Timestep Sizes = #1.0
Steady State Min Iterations = 1
Steady State Max Iterations = 10
! usually, Dirichlet BC's are initialized before everything else. Sometimes those
! conditions are dependent on solutions of earlier solvers; next line ensures that
! this is not an issue.
!-----------------------------------------
Initialize Dirichlet Conditions = Logical False
Post File = $name$.vtu
Output File = $name$.result
! We need a restart to have the ZsDEM and ZbDEM variables for
! the initial condition of Zs and Zb
Restart File = "bedmachine_.result"
Restart Position = 0
Restart Time = Real 0.0
Restart Before Initial Conditions = Logical True
max output level = 3
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
! The ice
Body 1
Equation = 1
Body Force = 1
Material = 1
Initial Condition = 1
End
!The Upper Free surface
Body 2
Name= "surface"
Equation = 2
Material = 1
Body Force = 2
Initial Condition = 2
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Initial Condition 1
!Initial velocity is not really needed when using newtonian start
!Mesh Velocity 1 = Real 0.0
!Mesh Velocity 2 = Real 0.0
!Mesh Velocity 3 = Real 0.0
End
Initial Condition 2
Zs = Equals ZsDEM !!!add
!Ref Zs = Variable ZsDEM,ZbDEM
! Real lua "initzs(tx[0],tx[1])"
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Body Force 1
Flow BodyForce 1 = Real 0.0
Flow BodyForce 2 = Real 0.0
Flow BodyForce 3 = Real #gravity
Temperature Volume Source = Equals W
! This should be in Body Force 2 but not working
! for solver executed on a boundary
!Zs = Variable ZbDEM
! Real LUA "tx[0]+ 1.0"
End
!! accumulation flux in m/year
Body Force 2
Zs Accumulation Flux 1 = real 0.0
Zs Accumulation Flux 2 = real 0.0
Zs Accumulation Flux 3 = Variable Coordinate 3, glaciated
Real lua "accum(tx[0],tx[1])"
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Material 1
Density = Real #rhoi*(yearinsec^(-2.0))*Pa2MPa
Viscosity Model = String "glen"
Viscosity = 1.0 ! Dummy but avoid warning output
Glen Exponent = Real 3.0
Limit Temperature = Real -10.0
Rate Factor 1 = Real #A1
Rate Factor 2 = Real #A2
Activation Energy 1 = Real #Q1
Activation Energy 2 = Real #Q2
Glen Enhancement Factor = Real 1.0 !10!4.0!3.0!2.0!1.0
Critical Shear Rate = Real 1.0e-10
!Relative Temperature = Real -1.0
!Relative Temperature = Equals Temperature Homologous !!!!New Add
Cauchy = Logical True
! heat transfer
Temperature Heat Capacity = Variable Temperature
Real lua "capacity(tx[0])*yearinsec^(2.0)"
Temperature Heat Conductivity = Variable Temperature
Real lua "conductivity(tx[0])*yearinsec*Pa2MPa"
! Upper limit - pressure melting point
!Temperature Upper Limit = Variable Pressure
! Real lua "pressuremeltingpoint(tx[0])"
Temperature Upper Limit = Real 275.15
! lower limit (to be save) as 0 K
Temperature Lower Limit = Real 0.0
! Min Zs = Variable ZbDEM
! Real LUA "tx[0]+ 0.1"
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Solver 1
Exec Solver = Never
End
Solver 2
Exec Solver = "before simulation"
Equation = "MapCoordinate"
Procedure = "StructuredMeshMapper" "StructuredMeshMapper"
Active Coordinate = Integer 3
Mesh Velocity Variable = String "dSdt"
Mesh Update Variable = String "dS"
Mesh Velocity First Zero = Logical True
Displacement Mode = Logical False
Correct Surface = Logical True
Minimum Height = Real 1.0
Correct Surface Mask = String "Glaciated"
Dot Product Tolerance = 1.0e-3
! These are needed to host the variables that are read in
Variable = -nooutput "DummyMesh"
! Top and bottom surfaces defined from variables
Top Surface Variable Name = String "Zs"
Bottom Surface Variable Name = String "ZbDEM"
Exported Variable 1 = "ZbDEM"
!Exported Variable 1 Mask = String "BedRock"
Exported Variable 2 = "ZsDEM"
!Exported Variable 2 Mask = String "Surface"
End
Solver 3
Equation = "HeightDepth 1"
Procedure = "StructuredProjectToPlane" "StructuredProjectToPlane"
Active Coordinate = Integer 3
Project to everywhere = Logical True
Operator 1 = Thickness
Operator 2 = Depth
Operator 3 = Height
End
Solver 4
Equation = "Flowdepth"
Exec Solver = "Before Simulation"
Exec Solver = "Never"
Procedure = File "ElmerIceSolvers" "FlowDepthSolver"
Variable = String "Depth"
Variable DOFs = 1
Linear System Solver = Iterative
Linear System Iterative Method = umfpack
Linear System Preconditioning = ILU0
Linear System Convergence Tolerance = Real 1.0e-6
Linear System Max Iterations = 500
Linear System Residual Output = 500
Linear System Abort Not Converged = True
Nonlinear System Max Iterations = 50
Nonlinear System Convergence Tolerance = 1.0e-5
Nonlinear System Newton After Iterations = 5
Nonlinear System Newton After Tolerance = 1.0e-02
Nonlinear System Relaxation Factor = 1.00
Steady State Convergence Tolerance = Real 1.0e-3
Gradient = Real -1.0E00
!Freesurf Name = String "FreeSurf"
End
Solver 5
!Exec Solver = Never
Equation = "Stokes-Vec"
Procedure = "IncompressibleNSVec" "IncompressibleNSSolver"
Stokes Flow = logical true
Div-Curl Discretization = Logical False
Stabilization Method = String Stabilized
!linear settings:
!------------------------------
include linsys/gcr.sif
!Non-linear iteration settings:
!------------------------------
Nonlinear System Max Iterations = 20
Nonlinear System Convergence Tolerance = 1.0e-5
Nonlinear System Newton After Iterations = 4
Nonlinear System Newton After Tolerance = 1.0e-4
Nonlinear System Reset Newton = Logical True
Nonlinear System Abort Not Converged = Logical True
! Convergence on timelevel (not required here)
!---------------------------------------------
Steady State Convergence Tolerance = Real 1.0e-3
Relative Integration Order = -1
!Number of Integration Points = Integer 44 ! 21, 28, 44, 64, ...
! 1st iteration viscosity is constant
Constant-Viscosity Start = Logical False
!! Timing infos
!Bulk Assembly Timing = Logical True
!Linear System Timing = Logical True
!Linear System Timing Cumulative = Logical True
End
Solver 6
!Exec Solver = "Never"
Equation = Sij
Procedure = "ElmerIceSolvers" "ComputeDevStress"
Variable = -nooutput "Sij"
Variable DOFs = 1
Exported Variable 1 = -dofs 6 Stress
Stress Variable Name = String "Stress"
Flow Solver Name = String "Flow Solution"
Linear System Solver = Direct
Linear System Direct Method = umfpack
End
Solver 7
!Exec Solver = "Never"
Equation = "EigenStresses"
Procedure = "ElmerIceSolvers" "ComputeEigenValues"
Variable = -nooutput dumy
Variable DOFs = 1
! The 3 eigenvalues
Exported Variable 1 = EigenStress
Exported Variable 1 DOFS = 3
! The 3 eigenvectors (Option)
Exported Variable 2 = EigenVector1
Exported Variable 2 DOFS = 3
Exported Variable 3 = EigenVector2
Exported Variable 3 DOFS = 3
Exported Variable 4 = EigenVector3
Exported Variable 4 DOFS = 3
End
!!!This solver computes the volumetric heat produced by ice flow deformation!!!
Solver 8
Equation = DeformationalHeat
Variable = W
Variable DOFs = 1
procedure = "ElmerIceSolvers" "DeformationalHeatSolver"
Linear System Solver = direct
Linear System direct Method = umfpack
End
Solver 9
!Exec Solver = "Never"
Equation = String "Homologous Temperature Equation"
Procedure = File "ElmerIceSolvers" "TemperateIceSolver"
! Comment next line in parallel, as EliminateDirichlet does
! not work in parallel
!------------------------------------------------------------
!Before Linsolve = "EliminateDirichlet" "EliminateDirichlet"
Loop While Unconstrained Nodes = Logical True
Variable = String "Temperature"
Variable DOFs = 1
Linear System Solver = "Iterative"
Linear System Iterative Method = "BiCGStab"
Linear System Max Iterations = 500
Linear System Convergence Tolerance = 1.0E-07
Linear System Abort Not Converged = True
Linear System Preconditioning = "ILU0"
Linear System Residual Output = 1
Steady State Convergence Tolerance = 1.0E-04
Nonlinear System Convergence Tolerance = 1.0E-05
Nonlinear System Max Iterations = 50
Nonlinear System Relaxation Factor = Real 9.999E-01
! uses the contact algorithm (aka Dirichlet algorithm)
!-----------------------------------------------------
Apply Dirichlet = Logical True
Stabilize = True
! those two variables are needed in order to store
! the relative or homologous temperature as well
! as the residual
!-------------------------------------------------
Exported Variable 1 = String "Temperature Homologous"
Exported Variable 1 DOFs = 1
Exported Variable 2 = String "Temperature Residual"
Exported Variable 2 DOFs = 1
End
Solver 10
!Exec Solver = Never
Equation = String "Free Surface Evolution"
Procedure = "./MyFreeSurfaceSolver" "FreeSurfaceSolver"
Variable = "Zs"
Variable DOFs = 1
! calculate dz/dt (better than from mesh velocity in case os steady-state iterations)
Calculate Velocity = Logical True
! Apply internal limiters
Apply Dirichlet = Logical true
! Steb method
Stabilization Method = Stabilized
! linear settings
Linear System Solver = Iterative
Linear System Iterative Method = BiCGStab
Linear System Max Iterations = 1500
Linear System Preconditioning = ILU0
Linear System Convergence Tolerance = 1.0e-7 !!!10
! non-linear settings
Nonlinear System Max Iterations = 100 !!!20 ! variational inequality needs more than one round
Nonlinear System Min Iterations = 2
Nonlinear System Convergence Tolerance = 1.0e-6 !!!8
Steady State Convergence Tolerance = 1.0e-3 !!!6
! loads also takes into account dirichlet conditions
! to compute residual flux
calculate loads = Logical True
Exported Variable 1 = -nooutput "Zs Residual"
Exported Variable 2 = "Zs"
end
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Solver 11
! to be executed on top surface (need Thickness)
Exec Solver = Never
Equation = "Save 1D Vars"
Procedure = "ElmerIceSolvers" "Scalar_OUTPUT"
Variable = -nooutput "savescal"
File Name = File "1DVar_OUTPUT_prog.dat"
End
Equation 1
Active Solvers(9) = 1 2 3 4 5 6 7 8 9
Flow Solution Name = String "Flow Solution"
Convection = Computed
End
! Top surface
Equation 2
Active Solvers(2) = 10 11
Flow Solution Name = String "Flow Solution"
Convection = Computed
End
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
! lateral side of the glacier
Boundary Condition 1
!ComputeNormal = Logical False
Target Boundaries = 1
Velocity 1 = real 0.0
Velocity 2 = real 0.0
Flowdepth Skip = Logical True
!Zs = Equals "Ref Zs"
End
! cavity roof and Bedrock
Boundary Condition 2
ComputeNormal = Logical True
!Bottom Surface = Equals "ZbDEM"
Bedrock = Logical True
!include BCs/slip_linear.sif
!Normal-Tangential Velocity Rotate = Logical False
Normal-Tangential Velocity = Logical True
Velocity 1 = Real 0.0e0
Slip Coefficient 2 = Real 0.1
Slip Coefficient 3 = Real 0.1
Temperature Flux BC = Logical True
Temperature Heat Flux = Real #70E-03 * yearinsec * Pa2MPa ! 70 mW m^-2
!Height = Real 0.0
End
! Upper Surface
Boundary Condition 3
!Top Surface = Equals "ZsDEM"
Surface = Logical True
Temperature = Real 275.15
!Temperature = Variable Coordinate 3
! Real lua "SurfTemp(tx[0])"
Body Id = 2
!Depth = Real 0.0
End