Changeset 26705 for issm/trunk-jpl/src/jl/solve/friction.jl
- Timestamp:
- 12/03/21 11:18:50 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/jl/solve/friction.jl
r26704 r26705 1 1 #Friction class definition 2 struct Friction#{{{ 2 3 abstract type CoreFriction end 4 struct CoreBuddFriction#{{{ 3 5 H_input::ElementInput 4 6 b_input::ElementInput … … 8 10 g::Float64 9 11 end# }}} 10 function Friction(element::Tria) #{{{12 function CoreFriction(element::Tria) #{{{ 11 13 12 H_input = GetInput(element, ThicknessEnum) 13 b_input = GetInput(element, BaseEnum) 14 c_input = GetInput(element, FrictionCoefficientEnum) 14 frictionlaw = FindParam(element, FrictionLawEnum) 15 15 16 rho_ice = FindParam(element, MaterialsRhoIceEnum) 17 rho_water = FindParam(element, MaterialsRhoSeawaterEnum) 18 g = FindParam(element, ConstantsGEnum) 16 if frictionlaw==1 17 H_input = GetInput(element, ThicknessEnum) 18 b_input = GetInput(element, BaseEnum) 19 c_input = GetInput(element, FrictionCoefficientEnum) 19 20 20 return Friction(H_input, b_input, c_input, rho_ice, rho_water, g) 21 rho_ice = FindParam(element, MaterialsRhoIceEnum) 22 rho_water = FindParam(element, MaterialsRhoSeawaterEnum) 23 g = FindParam(element, ConstantsGEnum) 24 25 return CoreBuddFriction(H_input, b_input, c_input, rho_ice, rho_water, g) 26 else 27 error("Friction ",typeof(md.friction)," not supported yet") 28 end 21 29 end#}}} 22 30 23 31 #vertices functions 24 function Alpha2(friction:: Friction, gauss::GaussTria, i::Int64) #{{{32 function Alpha2(friction::CoreBuddFriction, gauss::GaussTria, i::Int64) #{{{ 25 33 26 34 #Get effective pressure
Note:
See TracChangeset
for help on using the changeset viewer.