Changeset 25201 for issm/trunk-jpl/src/c/analyses/AdjointHorizAnalysis.cpp
- Timestamp:
- 07/03/20 06:23:13 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/analyses/AdjointHorizAnalysis.cpp
r24933 r25201 1103 1103 if(control_type!=MaterialsRheologyBbarEnum && 1104 1104 control_type!=FrictionCoefficientEnum && 1105 control_type!=FrictionCEnum && 1105 1106 control_type!=FrictionAsEnum && 1106 1107 control_type!=DamageDbarEnum && … … 1126 1127 switch(control_type){ 1127 1128 case FrictionCoefficientEnum: 1129 case FrictionCEnum: 1128 1130 switch(approximation){ 1129 1131 case SSAApproximationEnum: GradientJDragSSA(element,gradient,control_index); break; … … 1652 1654 /*Intermediaries*/ 1653 1655 int domaintype,dim; 1656 int frictionlaw; 1654 1657 Element* basalelement; 1655 1658 … … 1690 1693 basalelement->GetVerticesCoordinates(&xyz_list); 1691 1694 basalelement->GradientIndexing(&vertexpidlist[0],control_index); 1692 Input2* dragcoefficient_input = basalelement->GetInput2(FrictionCoefficientEnum); _assert_(dragcoefficient_input); 1695 1696 /* get the friction law: if 11-Schoof, use a special name for the coefficient*/ 1697 element->FindParam(&frictionlaw, FrictionLawEnum); 1698 Input2* dragcoefficient_input; 1699 switch(frictionlaw) { 1700 case 11: 1701 dragcoefficient_input = basalelement->GetInput2(FrictionCEnum); _assert_(dragcoefficient_input); 1702 break; 1703 default: 1704 dragcoefficient_input = basalelement->GetInput2(FrictionCoefficientEnum); _assert_(dragcoefficient_input); 1705 } 1706 1693 1707 DatasetInput2* weights_input = basalelement->GetDatasetInput2(InversionCostFunctionsCoefficientsEnum); _assert_(weights_input); 1694 1708 … … 1939 1953 /*Fetch number of vertices for this finite element*/ 1940 1954 int numvertices = basalelement->GetNumberOfVertices(); 1955 int frictionlaw; 1941 1956 1942 1957 /*Initialize some vectors*/ … … 1955 1970 Input2* adjointx_input = basalelement->GetInput2(AdjointxEnum); _assert_(adjointx_input); 1956 1971 Input2* adjointy_input = basalelement->GetInput2(AdjointyEnum); _assert_(adjointy_input); 1957 Input2* dragcoeff_input = basalelement->GetInput2(FrictionCoefficientEnum); _assert_(dragcoeff_input); 1972 1973 /* get the friction law: 1- Budd, 11-Schoof*/ 1974 element->FindParam(&frictionlaw, FrictionLawEnum); 1975 Input2* dragcoeff_input; 1976 switch(frictionlaw) { 1977 case 1: 1978 dragcoeff_input = basalelement->GetInput2(FrictionCoefficientEnum); _assert_(dragcoeff_input); 1979 break; 1980 case 11: 1981 dragcoeff_input = basalelement->GetInput2(FrictionCEnum); _assert_(dragcoeff_input); 1982 break; 1983 default: 1984 _error_("Friction law "<< frictionlaw <<" not supported in the inversion."); 1985 } 1958 1986 1959 1987 /* Start looping on the number of gaussian points: */
Note:
See TracChangeset
for help on using the changeset viewer.