Changeset 22004


Ignore:
Timestamp:
08/25/17 12:11:22 (8 years ago)
Author:
Eric.Larour
Message:

ADD and CHG: introducing new love solution. This involves a new fourierlove class, a new .love field
in the model, new enums, new materials class in particular, which can now dynamically, during the constructor
phase, initialize internal structure fields relevant to only 'ice', 'litho', or any other material. The
goal is to fade away the m/classes/material classes (matice, maticeenhanced, etc...) in favor of the @materials
class, which will be all encompassing. New love_core core, and new FourierLoveCorex module, where all of the
fortran files from Lambert Caron are placed, with all his love solution code. Interfacing is done between C++
and Fortran in this module. Also, rheology_law now taken out of the parameters, should be in the materials themeselves.

Location:
issm/trunk-jpl/src
Files:
17 added
41 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/Makefile.am

    r21931 r22004  
    9999                                        ./classes/Materials/Materials.cpp\
    100100                                        ./classes/Materials/Matice.cpp\
     101                                        ./classes/Materials/Matlitho.cpp\
    101102                                        ./classes/Materials/Matestar.cpp\
    102103                                        ./classes/Materials/Matpar.cpp\
     
    471472endif
    472473#}}}
     474#Love sources  {{{
     475if LOVE
     476issm_sources +=  ./cores/love_core.cpp\
     477                                 ./analyses/LoveAnalysis.cpp\
     478                                ./modules/FourierLoveCorex/FourierLoveCorex.cpp\
     479                                ./modules/FourierLoveCorex/lnb_param.f90\
     480                                ./modules/FourierLoveCorex/model.f90\
     481                                ./modules/FourierLoveCorex/util.f90\
     482                                ./modules/FourierLoveCorex/lovenb_sub.f90\
     483                                ./modules/FourierLoveCorex/love_numbers.f90
     484endif
     485#}}}
    473486#Esa sources  {{{
    474487if ESA
  • issm/trunk-jpl/src/c/analyses/EnthalpyAnalysis.cpp

    r21895 r22004  
    15251525                /*Update Rheology only if converged (we must make sure that the temperature is below melting point
    15261526                 * otherwise the rheology could be negative*/
    1527                 element->FindParam(&rheology_law,MaterialsRheologyLawEnum);
     1527                rheology_law=element->material->GetRheologyLaw();
    15281528                element->GetInputListOnNodes(&surface[0],SurfaceEnum);
    15291529                switch(rheology_law){
  • issm/trunk-jpl/src/c/analyses/EnumToAnalysis.cpp

    r22001 r22004  
    111111                #endif
    112112                #ifdef _HAVE_LOVE_
    113                 //case LoveAnalysisEnum : return new LoveAnalysis();
     113                case LoveAnalysisEnum : return new LoveAnalysis();
    114114                #endif
    115115                #ifdef _HAVE_LEVELSET_
  • issm/trunk-jpl/src/c/analyses/ThermalAnalysis.cpp

    r21875 r22004  
    809809                /*Update Rheology only if converged (we must make sure that the temperature is below melting point
    810810                 * otherwise the rheology could be negative*/
    811                 element->FindParam(&rheology_law,MaterialsRheologyLawEnum);
     811                rheology_law=element->material->GetRheologyLaw();
    812812                element->GetInputListOnNodes(&surface[0],SurfaceEnum);
    813813                switch(rheology_law){
  • issm/trunk-jpl/src/c/analyses/analyses.h

    r21931 r22004  
    2424#include "./FreeSurfaceTopAnalysis.h"
    2525#include "./GiaIvinsAnalysis.h"
     26#include "./LoveAnalysis.h"
    2627#include "./EsaAnalysis.h"
    2728#include "./HydrologyDCEfficientAnalysis.h"
  • issm/trunk-jpl/src/c/classes/Elements/ElementHook.cpp

    r21512 r22004  
    4646
    4747        /*retrieve material_id: */
    48         matpar_id = iomodel->numberofelements+1;
     48        matpar_id = iomodel->matparcounter;
    4949
    5050        /*retrieve material_id*/
  • issm/trunk-jpl/src/c/classes/FemModel.cpp

    r21953 r22004  
    678678                        analyses_temp[numanalyses++]=GiaIvinsAnalysisEnum;
    679679                        break;
    680                
     680
     681                case LoveSolutionEnum:
     682                        analyses_temp[numanalyses++]=LoveAnalysisEnum;
     683                        break;
     684
    681685                case EsaSolutionEnum:
    682686                        analyses_temp[numanalyses++]=EsaAnalysisEnum;
  • issm/trunk-jpl/src/c/classes/IoModel.h

    r20977 r22004  
    8787                int loadcounter;         //keep track of how many loads are being created in each analysis
    8888                int nodecounter;         //keep track of how many nodes are being created in each analysis
     89                int matparcounter;       //keep track of where we end up putting this object accessed by every element.
    8990
    9091                /*Methods*/
  • issm/trunk-jpl/src/c/classes/Materials/Material.h

    r21826 r22004  
    4242                virtual void       GetViscosity_D(IssmDouble* pviscosity,IssmDouble epseff)=0;
    4343                virtual void       GetViscosity2dDerivativeEpsSquare(IssmDouble* pmu_prime, IssmDouble* pepsilon)=0;
     44                virtual int        GetRheologyLaw()=0;
    4445                virtual bool       IsDamage()=0;
    4546                virtual bool       IsEnhanced()=0;
  • issm/trunk-jpl/src/c/classes/Materials/Matestar.cpp

    r21826 r22004  
    4141        this->mid=matestar_mid;
    4242
     43        /*rheology law:*/
     44        iomodel->FetchData(&this->rheology_law,"md.materials.rheology_law");
     45
    4346        /*Hooks: */
    4447        matestar_eid=index+1;
     
    367370void  Matestar::GetViscosity2dDerivativeEpsSquare(IssmDouble* pmu_prime, IssmDouble* epsilon){/*{{{*/
    368371        _error_("not implemented yet");
     372}
     373/*}}}*/
     374int Matestar::GetRheologyLaw(){/*{{{*/
     375        return this->rheology_law;
    369376}
    370377/*}}}*/
  • issm/trunk-jpl/src/c/classes/Materials/Matestar.h

    r21826 r22004  
    2828                Hook    *helement;
    2929                Element *element;
     30                int      rheology_law;
    3031
    3132        public:
     
    6364                void       GetViscosity_D(IssmDouble* pviscosity, IssmDouble eps_eff);
    6465                void       GetViscosity2dDerivativeEpsSquare(IssmDouble* pmu_prime, IssmDouble* pepsilon);
     66                int        GetRheologyLaw();
    6567                IssmDouble GetA();
    6668                IssmDouble GetAbar();
  • issm/trunk-jpl/src/c/classes/Materials/Matice.cpp

    r21826 r22004  
    4040   int materialtype;
    4141   iomodel->FindConstant(&materialtype,"md.materials.type");
     42   iomodel->FindConstant(&this->rheology_law,"md.materials.rheology_law");
    4243        this->Init(matice_mid,index,materialtype);
    4344
     
    639640}
    640641/*}}}*/
     642int   Matice::GetRheologyLaw(){/*{{{*/
     643        return this->rheology_law;
     644}
     645/*}}}*/
    641646void  Matice::InputUpdateFromConstant(IssmDouble constant, int name){/*{{{*/
    642647        /*Nothing updated yet*/
  • issm/trunk-jpl/src/c/classes/Materials/Matice.h

    r21826 r22004  
    2828                bool     isdamaged;
    2929                bool     isenhanced;
     30                int      rheology_law;
    3031                Hook    *helement;
    3132                Element *element;
     
    6768                void       GetViscosity_D(IssmDouble* pviscosity, IssmDouble eps_eff);
    6869                void       GetViscosity2dDerivativeEpsSquare(IssmDouble* pmu_prime, IssmDouble* pepsilon);
     70                int        GetRheologyLaw();
    6971                IssmDouble GetA();
    7072                IssmDouble GetAbar();
  • issm/trunk-jpl/src/c/classes/Materials/Matpar.cpp

    r21677 r22004  
    1717}
    1818/*}}}*/
    19 Matpar::Matpar(int matpar_mid, IoModel* iomodel){/*{{{*/
     19Matpar::Matpar(IoModel* iomodel){/*{{{*/
    2020
    2121        rho_ice                   = 0;
     
    7171        time_relaxation_damage    = 0;
    7272
     73       
     74        int nnat,dummy;
     75        int* nature=NULL;
     76
    7377        bool isefficientlayer;
    7478        int  hydrology_model,smb_model,materials_type;
     
    7781        iomodel->FindConstant(&materials_type,"md.materials.type");
    7882
    79         this->mid = matpar_mid;
     83        this->mid = iomodel->matparcounter;
    8084
    8185        switch(materials_type){
     
    169173                        /*slr:*/
    170174                        iomodel->FindConstant(&this->earth_density,"md.materials.earth_density");
     175
     176                        break;
     177                case MaterialsEnum:
     178                        //we have several types of materials. Retrieve this info first:
     179                        iomodel->FetchData(&nature,&nnat,&dummy,"md.materials.nature");
     180
     181                        //go through list of materials, and create constant parameters accordingly:
     182                        for(int i=0;i<nnat;i++){
     183                                switch(IoCodeToEnumMaterials(nature[i])){ //{{{
     184                                        case MatlithoEnum:
     185                                                break;
     186                                        case MaticeEnum:
     187                                        case MatdamageiceEnum:
     188                                        case MatenhancediceEnum:
     189                                        case MatestarEnum:
     190                                                iomodel->FindConstant(&this->rho_ice,"md.materials.rho_ice");
     191                                                iomodel->FindConstant(&this->rho_water,"md.materials.rho_water");
     192                                                iomodel->FindConstant(&this->rho_freshwater,"md.materials.rho_freshwater");
     193                                                iomodel->FindConstant(&this->mu_water,"md.materials.mu_water");
     194                                                iomodel->FindConstant(&this->heatcapacity,"md.materials.heatcapacity");
     195                                                iomodel->FindConstant(&this->thermalconductivity,"md.materials.thermalconductivity");
     196                                                iomodel->FindConstant(&this->temperateiceconductivity,"md.materials.temperateiceconductivity");
     197                                                iomodel->FindConstant(&this->latentheat,"md.materials.latentheat");
     198                                                iomodel->FindConstant(&this->beta,"md.materials.beta");
     199                                                iomodel->FindConstant(&this->meltingpoint,"md.materials.meltingpoint");
     200                                                iomodel->FindConstant(&this->referencetemperature,"md.constants.referencetemperature");
     201                                                iomodel->FindConstant(&this->mixed_layer_capacity,"md.materials.mixed_layer_capacity");
     202                                                iomodel->FindConstant(&this->thermal_exchange_velocity,"md.materials.thermal_exchange_velocity");
     203                                                iomodel->FindConstant(&this->g,"md.constants.g");
     204
     205                                                switch(smb_model){ //{{{
     206                                                        case SMBforcingEnum:
     207                                                                /*Nothing to add*/
     208                                                                break;
     209                                                        case SMBgembEnum:
     210                                                                iomodel->FindConstant(&this->albedo_ice,"md.smb.aIce");
     211                                                                iomodel->FindConstant(&this->albedo_snow,"md.smb.aSnow");
     212                                                                break;
     213                                                        case SMBpddEnum:
     214                                                                iomodel->FindConstant(&this->desfac,"md.smb.desfac");
     215                                                                iomodel->FindConstant(&this->rlaps,"md.smb.rlaps");
     216                                                                iomodel->FindConstant(&this->rlapslgm,"md.smb.rlapslgm");
     217                                                                break;
     218                                                        case SMBd18opddEnum:
     219                                                                iomodel->FindConstant(&this->desfac,"md.smb.desfac");
     220                                                                iomodel->FindConstant(&this->rlaps,"md.smb.rlaps");
     221                                                                iomodel->FindConstant(&this->rlapslgm,"md.smb.rlapslgm");
     222                                                                iomodel->FindConstant(&this->dpermil,"md.smb.dpermil");                                 
     223                                                        case SMBgradientsEnum:
     224                                                                /*Nothing to add*/
     225                                                                break;
     226                                                        case SMBgradientselaEnum:
     227                                                                /*Nothing to add*/
     228                                                                break;
     229                                                        case SMBhenningEnum:
     230                                                                /*Nothing to add*/
     231                                                                break;
     232                                                        case SMBcomponentsEnum:
     233                                                                /*Nothing to add*/
     234                                                                break;
     235                                                        case SMBmeltcomponentsEnum:
     236                                                                /*Nothing to add*/
     237                                                                break;
     238                                                        default:
     239                                                                _error_("Surface mass balance model "<<EnumToStringx(smb_model)<<" not supported yet");
     240                                                }
     241                                                if(hydrology_model==HydrologydcEnum){
     242                                                        iomodel->FindConstant(&this->sediment_compressibility,"md.hydrology.sediment_compressibility");
     243                                                        iomodel->FindConstant(&this->sediment_porosity,"md.hydrology.sediment_porosity");
     244                                                        iomodel->FindConstant(&this->sediment_thickness,"md.hydrology.sediment_thickness");
     245                                                        iomodel->FindConstant(&this->water_compressibility,"md.hydrology.water_compressibility");
     246                                                        iomodel->FindConstant(&isefficientlayer,"md.hydrology.isefficientlayer");
     247
     248                                                        if(isefficientlayer){
     249                                                                iomodel->FindConstant(&this->epl_compressibility,"md.hydrology.epl_compressibility");
     250                                                                iomodel->FindConstant(&this->epl_porosity,"md.hydrology.epl_porosity");
     251                                                                iomodel->FindConstant(&this->epl_init_thickness,"md.hydrology.epl_initial_thickness");
     252                                                                iomodel->FindConstant(&this->epl_colapse_thickness,"md.hydrology.epl_colapse_thickness");
     253                                                                iomodel->FindConstant(&this->epl_max_thickness,"md.hydrology.epl_max_thickness");
     254                                                                iomodel->FindConstant(&this->epl_conductivity,"md.hydrology.epl_conductivity");
     255                                                        }
     256                                                }
     257                                                else if(hydrology_model==HydrologyshreveEnum){
     258                                                        /*Nothing to add*/
     259                                                }
     260                                                else if(hydrology_model==HydrologysommersEnum){
     261                                                        /*Nothing to add*/
     262                                                }
     263                                                else{
     264                                                        _error_("Hydrology model "<<EnumToStringx(hydrology_model)<<" not supported yet");
     265                                                }
     266
     267                                                /*gia: */
     268                                                iomodel->FindConstant(&this->lithosphere_shear_modulus,"md.materials.lithosphere_shear_modulus");
     269                                                iomodel->FindConstant(&this->lithosphere_density,"md.materials.lithosphere_density");
     270                                                iomodel->FindConstant(&this->mantle_shear_modulus,"md.materials.mantle_shear_modulus");
     271                                                iomodel->FindConstant(&this->mantle_density,"md.materials.mantle_density");
     272
     273                                                /*slr:*/
     274                                                iomodel->FindConstant(&this->earth_density,"md.materials.earth_density");
     275                                                //}}}
     276                                                break;
     277                                        default:
     278                                                _error_("Materials "<<EnumToStringx(IoCodeToEnumMaterials(nature[i]))<<" not supported");
     279
     280                                } //}}}
     281                        }
     282                        //Free ressources:
     283                        xDelete<int>(nature);
     284                        break;
    171285
    172286                        break;
  • issm/trunk-jpl/src/c/classes/Materials/Matpar.h

    r21826 r22004  
    7575        public:
    7676                Matpar();
    77                 Matpar(int matpar_id, IoModel* iomodel);
     77                Matpar(IoModel* iomodel);
    7878                ~Matpar();
    7979                void SetMid(int matpar_mid);
     
    107107                void       GetViscosity_D(IssmDouble* pviscosity,IssmDouble eps_eff){_error_("not supported");};
    108108                void       GetViscosity2dDerivativeEpsSquare(IssmDouble* pmu_prime, IssmDouble* pepsilon){_error_("not supported");};
     109                int        GetRheologyLaw(){_error_("not supported");};
    109110                IssmDouble GetA(){_error_("not supported");};
    110111                IssmDouble GetAbar(){_error_("not supported");};
  • issm/trunk-jpl/src/c/classes/Vertices.cpp

    r18521 r22004  
    144144        int vertex_max_sid;
    145145
     146        if (this->Size()==0)return 0;
     147
    146148        for(i=0;i<this->Size();i++){
    147149                Vertex* vertex=xDynamicCast<Vertex*>(this->GetObjectByOffset(i));
  • issm/trunk-jpl/src/c/classes/classes.h

    r21808 r22004  
    8484#include "./Materials/Material.h"
    8585#include "./Materials/Matice.h"
     86#include "./Materials/Matlitho.h"
    8687#include "./Materials/Matestar.h"
    8788#include "./Materials/Matpar.h"
  • issm/trunk-jpl/src/c/cores/CorePointerFromSolutionEnum.cpp

    r21583 r22004  
    7575                        solutioncore=&damage_core;
    7676                        break;
     77                case LoveSolutionEnum:
     78                        solutioncore=&love_core;
     79                        break;
     80
    7781                default:
    7882                        _error_("solution type: " << EnumToStringx(solutiontype) << " not supported yet!");
  • issm/trunk-jpl/src/c/cores/cores.h

    r21579 r22004  
    4747void dummy_core(FemModel* femmodel);
    4848void gia_core(FemModel* femmodel);
     49void love_core(FemModel* femmodel);
    4950void esa_core(FemModel* femmodel);
    5051void smb_core(FemModel* femmodel);
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/CreateElementsVerticesAndMaterials.cpp

    r21389 r22004  
    88#include "./ModelProcessorx.h"
    99
    10 void CreateElementsVerticesAndMaterials(Elements* elements,Vertices* vertices,Materials* materials,IoModel* iomodel,const int nummodels){
     10void CreateElementsVerticesAndMaterials(Elements* elements,Vertices* vertices,Materials* materials,IoModel* iomodel,const int nummodels,int solution_type){
    1111
    1212        /*Intermediary*/
     
    1515        bool control_analysis;
    1616        bool dakota_analysis;
     17        int nnat,dummy;
     18        int* nature=NULL;
    1719
    1820        /*Fetch parameters: */
     
    2325        /*Did we already create the elements? : */
    2426        _assert_(elements->Size()==0);
     27
     28        /*Setup matpar counter in iomodel before we call on element constructors: */
     29        iomodel->matparcounter=iomodel->numberofelements+1;
    2530
    2631        /*Create elements*/
     
    112117                        }
    113118                        break;
     119                case MaterialsEnum:
     120       
     121                        //we have several types of materials. Retrieve this info first:
     122                        iomodel->FetchData(&nature,&nnat,&dummy,"md.materials.nature");
     123
     124                        //make sure materials that are not tied to elements come last:  for now, only Matlitho qualifies.
     125                        for(int i=0;i<nnat;i++){
     126                                if (IoCodeToEnumMaterials(nature[i])==MatlithoEnum){
     127                                        int temp=nature[nnat-1];
     128                                        nature[nnat-1]=nature[i];
     129                                        nature[i]=temp;
     130                                }
     131                        }
     132
     133                        //go through list of materials, and create them:
     134                        for(int i=0;i<nnat;i++){
     135                                switch(IoCodeToEnumMaterials(nature[i])){ //{{{
     136                                        case MaticeEnum:
     137                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_B",MaterialsRheologyBEnum);
     138                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_n",MaterialsRheologyNEnum);
     139                                                for (i=0;i<iomodel->numberofelements;i++) if(iomodel->my_elements[i]) materials->AddObject(new Matice(i+1,i,iomodel));
     140                                                switch(iomodel->domaindim){
     141                                                        case 2:
     142                                                                elements->InputDuplicate(MaterialsRheologyBEnum,MaterialsRheologyBbarEnum);
     143                                                                break;
     144                                                        case 3:
     145                                                                break;
     146                                                        default:
     147                                                                _error_("Mesh not supported yet");
     148                                                }
     149                                                break;
     150                                        case MatlithoEnum:
     151                                                iomodel->FetchData(9,"md.materials.radius","md.materials.viscosity","md.materials.lame_lambda","md.materials.lame_mu","md.materials.burgers_viscosity","md.materials.burgers_mu","md.materials.isburgers","md.materials.issolid","md.materials.density");
     152                                                materials->AddObject(new Matlitho(materials->Size()+1,iomodel));
     153                                                iomodel->DeleteData(9,"md.materials.radius","md.materials.viscosity","md.materials.lame_lambda","md.materials.lame_mu","md.materials.burgers_viscosity","md.materials.burgers_mu","md.materials.isburgers","md.materials.issolid","md.materials.density");
     154                                                break;
     155
     156                                        case MatenhancediceEnum:
     157                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_B",MaterialsRheologyBEnum);
     158                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_n",MaterialsRheologyNEnum);
     159                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_E",MaterialsRheologyEEnum);
     160                                                for (i=0;i<iomodel->numberofelements;i++) if(iomodel->my_elements[i]) materials->AddObject(new Matice(i+1,i,iomodel));
     161                                                switch(iomodel->domaindim){
     162                                                        case 2:
     163                                                                elements->InputDuplicate(MaterialsRheologyBEnum,MaterialsRheologyBbarEnum);
     164                                                                elements->InputDuplicate(MaterialsRheologyEEnum,MaterialsRheologyEbarEnum);
     165                                                                break;
     166                                                        case 3:
     167                                                                break;
     168                                                        default:
     169                                                                _error_("Mesh not supported yet");
     170                                                }
     171                                                break;
     172                                        case MatdamageiceEnum:
     173                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_B",MaterialsRheologyBEnum);
     174                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_n",MaterialsRheologyNEnum);
     175                                                iomodel->FetchDataToInput(elements,"md.damage.D",DamageDEnum);
     176                                                for (i=0;i<iomodel->numberofelements;i++) if(iomodel->my_elements[i]) materials->AddObject(new Matice(i+1,i,iomodel));
     177                                                switch(iomodel->domaindim){
     178                                                        case 2:
     179                                                                elements->InputDuplicate(MaterialsRheologyBEnum,MaterialsRheologyBbarEnum);
     180                                                                elements->InputDuplicate(DamageDEnum,DamageDbarEnum);
     181                                                                break;
     182                                                        case 3:
     183                                                                break;
     184                                                        default:
     185                                                                _error_("Mesh not supported yet");
     186                                                }
     187                                                break;
     188                                        case MatestarEnum:
     189                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_B",MaterialsRheologyBEnum);
     190                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_Ec",MaterialsRheologyEcEnum);
     191                                                iomodel->FetchDataToInput(elements,"md.materials.rheology_Es",MaterialsRheologyEsEnum);
     192                                                for(i=0;i<iomodel->numberofelements;i++) if(iomodel->my_elements[i]) materials->AddObject(new Matestar(i+1,i,iomodel));
     193                                                switch(iomodel->domaindim){
     194                                                        case 2:
     195                                                                elements->InputDuplicate(MaterialsRheologyBEnum,MaterialsRheologyBbarEnum);
     196                                                                elements->InputDuplicate(MaterialsRheologyEcEnum,MaterialsRheologyEcbarEnum);
     197                                                                elements->InputDuplicate(MaterialsRheologyEsEnum,MaterialsRheologyEsbarEnum);
     198                                                                break;
     199                                                        case 3:
     200                                                                break;
     201                                                        default:
     202                                                                _error_("Mesh not supported yet");
     203                                                }
     204                                                break;
     205
     206                                        default:
     207                                                _error_("Materials "<<EnumToStringx(IoCodeToEnumMaterials(nature[i]))<<" not supported");
     208
     209                                } //}}}
     210                        }
     211                        //Free ressources:
     212                        xDelete<int>(nature);
     213                        break;
     214
    114215                default:
    115216                        _error_("Materials "<<EnumToStringx(materials_type)<<" not supported");
     
    121222
    122223        /*Add new constant material property to materials, at the end: */
    123         materials->AddObject(new Matpar(iomodel->numberofelements+1,iomodel));//put it at the end of the materials
     224        materials->AddObject(new Matpar(iomodel));//put it at the end of the materials
    124225
    125226        /*Create vertices: */
     
    129230        if (iomodel->domaintype == Domain3DsurfaceEnum) iomodel->FetchData(3,"md.mesh.lat","md.mesh.long","md.mesh.r");
    130231       
    131         CreateNumberNodeToElementConnectivity(iomodel);
     232        CreateNumberNodeToElementConnectivity(iomodel,solution_type);
    132233
    133234        for(i=0;i<iomodel->numberofvertices;i++){
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/CreateNumberNodeToElementConnectivity.cpp

    r17692 r22004  
    1414#include "./ModelProcessorx.h"
    1515
    16 void CreateNumberNodeToElementConnectivity(IoModel* iomodel){
     16void CreateNumberNodeToElementConnectivity(IoModel* iomodel,int solution_type){
    1717
    1818        /*Intermediary*/
     
    2828
    2929        /*Some checks if debugging*/
    30         _assert_(iomodel->numberofvertices);
    31         _assert_(iomodel->numberofelements);
    32         _assert_(iomodel->elements);
     30        if (solution_type==LoveSolutionEnum){
     31                /*do nothing, we don't have a mesh. Just initialize to NULL*/
     32        }
     33        else{
    3334
    34         /*Allocate ouput*/
    35         connectivity=xNewZeroInit<int>(iomodel->numberofvertices);
     35                /*Some checks if debugging*/
     36                _assert_(iomodel->numberofvertices);
     37                _assert_(iomodel->numberofelements);
     38                _assert_(iomodel->elements);
    3639
    37         /*Get element width*/
    38         switch(iomodel->meshelementtype){
    39                 case TriaEnum:  elementswidth=3; break;
    40                 case TetraEnum: elementswidth=4; break;
    41                 case PentaEnum: elementswidth=6; break;
    42                 default:                   _error_("mesh not supported yet");
    43         }
     40                /*Allocate ouput*/
     41                connectivity=xNewZeroInit<int>(iomodel->numberofvertices);
    4442
    45         /*Create connectivity table*/
    46         for (i=0;i<iomodel->numberofelements;i++){
    47                 for (j=0;j<elementswidth;j++){
    48                         vertexid=iomodel->elements[elementswidth*i+j];
    49                         _assert_(vertexid>0 && vertexid-1<iomodel->numberofvertices);
    50                         connectivity[vertexid-1]+=1;
     43                /*Get element width*/
     44                switch(iomodel->meshelementtype){
     45                        case TriaEnum:  elementswidth=3; break;
     46                        case TetraEnum: elementswidth=4; break;
     47                        case PentaEnum: elementswidth=6; break;
     48                        default:                   _error_("mesh not supported yet");
     49                }
     50
     51                /*Create connectivity table*/
     52                for (i=0;i<iomodel->numberofelements;i++){
     53                        for (j=0;j<elementswidth;j++){
     54                                vertexid=iomodel->elements[elementswidth*i+j];
     55                                _assert_(vertexid>0 && vertexid-1<iomodel->numberofvertices);
     56                                connectivity[vertexid-1]+=1;
     57                        }
    5158                }
    5259        }
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/CreateParameters.cpp

    r21930 r22004  
    2323        char*       fieldname = NULL;
    2424        IssmDouble  time;
     25       
     26        /*love numbers: */
     27        IssmDouble* frequencies = NULL;
     28        int         nfreq=0;
     29        int         dummy;
    2530
    2631        /*parameters for mass flux:*/
     
    6166        parameters->AddObject(iomodel->CopyConstantObject("md.inversion.type",InversionTypeEnum));
    6267        parameters->AddObject(iomodel->CopyConstantObject("md.calving.law",CalvingLawEnum));
     68       
     69        /*gia: */
     70        parameters->AddObject(iomodel->CopyConstantObject("md.gia.cross_section_shape",GiaCrossSectionShapeEnum));
     71       
     72        /*love numbers: */
     73        iomodel->FetchData(&nfreq,"md.love.nfreq");
     74        parameters->AddObject(new IntParam(LoveNfreqEnum,nfreq));
     75
     76        iomodel->FetchData(&frequencies,&dummy,&dummy,"md.love.frequencies");
     77        parameters->AddObject(new DoubleVecParam(LoveFrequenciesEnum,frequencies,nfreq));
     78        xDelete<IssmDouble>(frequencies);
     79       
     80        parameters->AddObject(iomodel->CopyConstantObject("md.love.sh_nmax",LoveShNmaxEnum));
     81        parameters->AddObject(iomodel->CopyConstantObject("md.love.sh_nmin",LoveShNminEnum));
     82        parameters->AddObject(iomodel->CopyConstantObject("md.love.g0",LoveG0Enum));
     83        parameters->AddObject(iomodel->CopyConstantObject("md.love.r0",LoveR0Enum));
     84        parameters->AddObject(iomodel->CopyConstantObject("md.love.mu0",LoveMu0Enum));
     85        parameters->AddObject(iomodel->CopyConstantObject("md.love.allow_layer_deletion",LoveAllowLayerDeletionEnum));
     86        parameters->AddObject(iomodel->CopyConstantObject("md.love.forcing_type",LoveForcingTypeEnum));
     87
    6388          {/*This is specific to ice...*/
    6489                parameters->AddObject(iomodel->CopyConstantObject("md.mesh.elementtype",MeshElementtypeEnum));
     
    80105                parameters->AddObject(iomodel->CopyConstantObject("md.transient.iscoupler",TransientIscouplerEnum));
    81106                parameters->AddObject(iomodel->CopyConstantObject("md.transient.amr_frequency",TransientAmrFrequencyEnum));
    82                 parameters->AddObject(iomodel->CopyConstantObject("md.materials.rheology_law",MaterialsRheologyLawEnum));
    83107                parameters->AddObject(iomodel->CopyConstantObject("md.gia.cross_section_shape",GiaCrossSectionShapeEnum));
    84108
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/ModelProcessorx.cpp

    r20690 r22004  
    3636
    3737        /*Create elements, vertices and materials, independent of analysis_enum: */
    38         CreateElementsVerticesAndMaterials(elements,vertices,materials,iomodel,nummodels);
     38        CreateElementsVerticesAndMaterials(elements,vertices,materials,iomodel,nummodels,solution_enum);
    3939
    4040        /*Create Parameters*/
     
    6868
    6969        /*Solution specific updates*/
     70        if(VerboseMProcessor()) _printf0_("   updating elements and materials for control parameters" << "\n");
    7071        UpdateElementsAndMaterialsControl(elements,materials,iomodel);
    7172        #ifdef _HAVE_DAKOTA_
     73        if(VerboseMProcessor()) _printf0_("   updating elements and materials for uncertainty quantification" << "\n");
    7274        UpdateElementsAndMaterialsDakota(elements,materials,iomodel);
    7375        #endif
     
    7779
    7880        /*Output definitions dataset: */
     81        if(VerboseMProcessor()) _printf0_("   creating output definitions" << "\n");
    7982        CreateOutputDefinitions(elements,parameters,iomodel);
    8083
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/ModelProcessorx.h

    r18529 r22004  
    1212
    1313/*Creation of fem datasets: general drivers*/
    14 void CreateElementsVerticesAndMaterials(Elements* elements,Vertices* vertices,Materials* materials, IoModel* iomodel,const int nummodels);
     14void CreateElementsVerticesAndMaterials(Elements* elements,Vertices* vertices,Materials* materials, IoModel* iomodel,const int nummodels,int solution_type);
    1515void CreateParameters(Parameters*parameters,IoModel* iomodel,char* rootpath,FILE* toolkitfile,const int solution_type);
    1616void CreateParametersAutodiff(Parameters* parameters,IoModel* iomodel);
     
    3737/*Connectivity*/
    3838void CreateSingleNodeToElementConnectivity(IoModel* iomodel);
    39 void CreateNumberNodeToElementConnectivity(IoModel* iomodel);
     39void CreateNumberNodeToElementConnectivity(IoModel* iomodel,int solution_type);
    4040#endif
  • issm/trunk-jpl/src/c/modules/SetActiveNodesLSMx/SetActiveNodesLSMx.cpp

    r20470 r22004  
    7070
    7171        /*Initialize vector with number of vertices*/
    72         int numvertices=femmodel->vertices->NumberOfVertices();
     72        int numvertices=femmodel->vertices->NumberOfVertices(); if (numvertices==0)return;
    7373        Vector<IssmDouble>* vec_mask_ice=new Vector<IssmDouble>(numvertices); //vertices that have ice at next time step
    7474        /*Fill vector with values: */
  • issm/trunk-jpl/src/c/modules/modules.h

    r21577 r22004  
    3030#include "./GetVectorFromControlInputsx/GetVectorFromControlInputsx.h"
    3131#include "./GiaDeflectionCorex/GiaDeflectionCorex.h"
     32#include "./FourierLoveCorex/FourierLoveCorex.h"
    3233#include "./SetControlInputsFromVectorx/SetControlInputsFromVectorx.h"
    3334#include "./SetActiveNodesLSMx/SetActiveNodesLSMx.h"
  • issm/trunk-jpl/src/c/shared/io/Marshalling/IoCodeConversions.cpp

    r21802 r22004  
    118118                case 3: return MaticeEnum;
    119119                case 4: return MatenhancediceEnum;
     120                case 5: return MatlithoEnum;
     121                case 6: return MaterialsEnum;
    120122                default: _error_("Marshalled materials code \""<<enum_in<<"\" not supported yet");
    121123        }
  • issm/trunk-jpl/src/m/classes/maskpsl.m

    r20690 r22004  
    4242                end % }}}
    4343                function md = checkconsistency(self,md,solution,analyses) % {{{
     44                       
     45                        if strcmpi(solution,'LoveSolution'), return; end;
    4446
    4547                        md = checkfield(md,'fieldname','mask.groundedice_levelset','size',[md.mesh.numberofvertices 1]);
  • issm/trunk-jpl/src/m/classes/materials.m

    r21697 r22004  
    113113                                        self.numlayers=2;
    114114
    115                                         %surface, then the lab (lithosphere/asthenosphere boundary) then the center of the earth
     115                                        %center of the earth (approximation, must not be 0), then the lab (lithosphere/asthenosphere boundary) then the surface
    116116                                        %(with 1d3 to avoid numerical singularities)
    117                                         self.radius=[6378*1e3;6278*1e3;1e3];
    118 
    119                                         self.viscosity=[1e40;1e21]; %lithosphere and mantle viscosity (respectively) [Pa.s]
    120                                         self.lame_mu=[6.7*10^10;1.45*1e11];  % (Pa) %lithosphere and mantle shear modulus (respectively) [Pa]
    121                                         self.lame_lambda=[6.7*10^10;1.45*1e11];  % (Pa) %lithosphere and mantle lamba parameter (respectively) [Pa]
     117                                        self.radius=[1e3;6278*1e3;6378*1e3];
     118
     119                                        self.viscosity=[1e21;1e40]; %mantle and lithosphere viscosity (respectively) [Pa.s]
     120                                        self.lame_mu=[1.45*1e11;6.7*10^10];  % (Pa) %lithosphere and mantle shear modulus (respectively) [Pa]
     121                                        self.lame_lambda=self.lame_mu;  % (Pa) %mantle and lithosphere lamba parameter (respectively) [Pa]
    122122                                        self.burgers_viscosity=[NaN;NaN];
    123123                                        self.burgers_mu=[NaN;NaN];
    124                                         self.isburgers=[false;false];
    125                                         self.density=[3.32*1e3;3.34*1e3];  % (Pa) %lithosphere and mantle density [kg/m^3]
    126                                         self.issolid=[true;true]; % is layer solid or liquid.
     124                                        self.isburgers=[0;0];
     125                                        self.density=[5.51*1e3;5.50*1e3];  % (Pa) %mantle and lithosphere density [kg/m^3]
     126                                        self.issolid=[1;1]; % is layer solid or liquid.
    127127
    128128                                otherwise
     
    188188                                        md = checkfield(md,'fieldname','materials.numlayers','NaN',1,'Inf',1,'>',0,'numel',1);
    189189                                        md = checkfield(md,'fieldname','materials.radius','NaN',1,'Inf',1,'size',[md.materials.numlayers+1 1],'>',0);
    190                                         md = checkfield(md,'fieldname','materials.lame_mu','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0);
    191                                         md = checkfield(md,'fieldname','materials.lame_lambda','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0);
    192                                         md = checkfield(md,'fieldname','materials.issolid','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0,'<',2);
     190                                        md = checkfield(md,'fieldname','materials.lame_mu','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>=',0);
     191                                        md = checkfield(md,'fieldname','materials.lame_lambda','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>=',0);
     192                                        md = checkfield(md,'fieldname','materials.issolid','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>=',0,'<',2);
    193193                                        md = checkfield(md,'fieldname','materials.density','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0);
    194                                         md = checkfield(md,'fieldname','materials.viscosity','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0);
    195                                         md = checkfield(md,'fieldname','materials.isburgers','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0,'<',2);
    196                                         md = checkfield(md,'fieldname','materials.burgers_viscosity','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0);
    197                                         md = checkfield(md,'fieldname','materials.burgers_mu','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>',0);
    198 
    199                                 otherwise
    200                                         error('materials constructor error message: nature of the material not supported yet! (''ice'' or ''litho'')');
    201                                 end
    202                         end
    203 
    204                 end % }}}
    205                 function intnat = naturetointeger(strnat) % {{{
    206                         intnat=zeros(length(strnat),1);
    207                         for i=1:length(strnat),
    208                                 switch strnat{i},
    209                                 case 'damageice'
    210                                         intnat(i)=1;
    211                                 case 'estar'
    212                                         intnat(i)=2;
    213                                 case 'ice'
    214                                         intnat(i)=3;
    215                                 case 'enhancedice'
    216                                         intnat(i)=4;
    217                                 case 'litho'
    218                                         intnat(i)=5;
    219                                 otherwise
    220                                         error('materials constructor error message: nature of the material not supported yet! (''ice'' or ''litho'')');
    221                                 end
    222                         end
     194                                        md = checkfield(md,'fieldname','materials.viscosity','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>=',0);
     195                                        md = checkfield(md,'fieldname','materials.isburgers','NaN',1,'Inf',1,'size',[md.materials.numlayers 1],'>=',0,'<=',1);
     196                                        md = checkfield(md,'fieldname','materials.burgers_viscosity','Inf',1,'size',[md.materials.numlayers 1],'>=',0);
     197                                        md = checkfield(md,'fieldname','materials.burgers_mu','Inf',1,'size',[md.materials.numlayers 1],'>=',0);
     198
     199                                        for i=1:md.materials.numlayers,
     200                                                if md.materials.isburgers(i) & (isnan(md.materials.burgers_viscosity(i) | isnan(md.materials.burgers_mu(i)))),
     201                                                        error('materials checkconsistency error message: Litho burgers_viscosity or burgers_mu has NaN values, inconsistent with isburgers choice');
     202                                                end
     203                                        end
     204                                        if md.materials.issolid(1)==0 | md.materials.lame_mu(1)==0
     205                                                        error('First layer must be solid (issolid(1) > 0 AND lame_mu(1) > 0). Add a weak inner core if necessary.');
     206                                        end
     207                                        ind=find(md.materials.issolid==0);
     208                                        if sum(ismember(diff(ind),1)>=1) %if there are at least two consecutive indices that contain issolid = 0
     209                                                        error(['Fluid layers detected at layers #', num2str(ind'), ', but having 2 or more adjacent fluid layers is not supported yet. Consider merging them.'])
     210                                        end
     211                                otherwise
     212                                        error('materials constructor error message: nature of the material not supported yet! (''ice'' or ''litho'')');
     213                                end
     214                        end
     215
    223216                end % }}}
    224217                function marshall(self,prefix,md,fid) % {{{
     
    226219                        %1: MatdamageiceEnum 2: MatestarEnum 3: MaticeEnum 4: MatenhancediceEnum 5: MaterialsEnum
    227220                        WriteData(fid,prefix,'name','md.materials.type','data',6,'format','Integer');
    228                         WriteData(fid,prefix,'name','md.materials.nature','data',naturetointeger(self.nature),'format','IntMat','mattype',1);
     221                        WriteData(fid,prefix,'name','md.materials.nature','data',naturetointeger(self.nature),'format','IntMat','mattype',3);
    229222
    230223                        for i=1:length(self.nature),
     
    248241                                        WriteData(fid,prefix,'data',self.rheology_law,'name','md.materials.rheology_law','format','String');
    249242                                case 'litho'
    250                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','numlayers','format','Double');
    251                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','radius','format','DoubleMat','mattype',1);
    252                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','lame_mu','format','DoubleMat','mattype',1);
    253                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','lame_lambda ','format','DoubleMat','mattype',1);
    254                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','issolid','format','BooleanMat','mattype',1);
    255                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','density','format','DoubleMat','mattype',1);
    256                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','viscosity','format','DoubleMat','mattype',1);
    257                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','isburgers','format','BooleanMat','mattype',1);
    258                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','burgers_viscosity','format','DoubleMat','mattype',1);
    259                                         WriteData(fid,prefix,'object',self,'class','materials','fieldname','burgers_mu','format','DoubleMat','mattype',1);
     243                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','numlayers','format','Integer');
     244                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','radius','format','DoubleMat','mattype',3);
     245                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','lame_mu','format','DoubleMat','mattype',3);
     246                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','lame_lambda','format','DoubleMat','mattype',3);
     247                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','issolid','format','DoubleMat','mattype',3);
     248                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','density','format','DoubleMat','mattype',3);
     249                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','viscosity','format','DoubleMat','mattype',3);
     250                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','isburgers','format','DoubleMat','mattype',3);
     251                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','burgers_viscosity','format','DoubleMat','mattype',3);
     252                                        WriteData(fid,prefix,'object',self,'class','materials','fieldname','burgers_mu','format','DoubleMat','mattype',3);
    260253                                otherwise
    261254                                        error('materials constructor error message: nature of the material not supported yet! (''ice'' or ''litho'')');
     
    316309        end
    317310end
    318 
    319 
     311                function intnat = naturetointeger(strnat) % {{{
     312                        intnat=zeros(length(strnat),1);
     313                        for i=1:length(strnat),
     314                                switch strnat{i},
     315                                case 'damageice'
     316                                        intnat(i)=1;
     317                                case 'estar'
     318                                        intnat(i)=2;
     319                                case 'ice'
     320                                        intnat(i)=3;
     321                                case 'enhancedice'
     322                                        intnat(i)=4;
     323                                case 'litho'
     324                                        intnat(i)=5;
     325                                otherwise
     326                                        error('materials constructor error message: nature of the material not supported yet! (''ice'' or ''litho'')');
     327                                end
     328                        end
     329                end % }}}
  • issm/trunk-jpl/src/m/classes/mesh2d.m

    r21049 r22004  
    8080                end % }}}
    8181                function md = checkconsistency(self,md,solution,analyses) % {{{
     82                       
     83                        if strcmpi(solution,'LoveSolution'), return; end
    8284
    8385                        md = checkfield(md,'fieldname','mesh.x','NaN',1,'Inf',1,'size',[md.mesh.numberofvertices 1]);
  • issm/trunk-jpl/src/m/classes/mesh2dvertical.m

    r21049 r22004  
    7979                end % }}}
    8080                function md = checkconsistency(self,md,solution,analyses) % {{{
     81                       
     82                        if strcmpi(solution,'LoveSolution'), return; end
    8183
    8284                        md = checkfield(md,'fieldname','mesh.x','NaN',1,'Inf',1,'size',[md.mesh.numberofvertices 1]);
  • issm/trunk-jpl/src/m/classes/mesh3dprisms.m

    r21501 r22004  
    9090                end % }}}
    9191                function md = checkconsistency(self,md,solution,analyses) % {{{
     92                       
     93                        if strcmpi(solution,'LoveSolution'), return; end
    9294
    9395                        md = checkfield(md,'fieldname','mesh.x','NaN',1,'Inf',1,'size',[md.mesh.numberofvertices 1]);
  • issm/trunk-jpl/src/m/classes/mesh3dsurface.m

    r21049 r22004  
    8080                end % }}}
    8181                function md = checkconsistency(obj,md,solution,analyses) % {{{
     82
     83                        if strcmpi(solution,'LoveSolution'), return; end
    8284
    8385                        md = checkfield(md,'fieldname','mesh.x','NaN',1,'Inf',1,'size',[md.mesh.numberofvertices 1]);
  • issm/trunk-jpl/src/m/classes/mesh3dtetras.m

    r20970 r22004  
    9090                end % }}}
    9191                function md = checkconsistency(self,md,solution,analyses) % {{{
     92                       
     93                        if strcmpi(solution,'LoveSolution'), return; end
    9294
    9395                        md = checkfield(md,'fieldname','mesh.x','NaN',1,'Inf',1,'size',[md.mesh.numberofvertices 1]);
  • issm/trunk-jpl/src/m/classes/model.m

    r21827 r22004  
    4040                levelset                          = 0;
    4141                calving          = 0;
    42                 gia                               = 0;
     42                love                     = 0;
     43                gia                              = 0;
    4344                esa              = 0;
    4445
     
    11501151                        md.levelset                       = levelset();
    11511152                        md.calving          = calving();
    1152                         md.gia                            = giaivins();
     1153                        md.gia                          = giaivins();
     1154                        md.love                         = fourierlove();
    11531155                        md.esa              = esa();
    11541156                        md.autodiff         = autodiff();
     
    13241326                        disp(sprintf('%19s: %-22s -- %s','calving'         ,['[1x1 ' class(self.calving) ']'],'parameters for calving'));
    13251327                        disp(sprintf('%19s: %-22s -- %s','gia'        ,['[1x1 ' class(self.gia) ']'],'parameters for gia solution'));
     1328                        disp(sprintf('%19s: %-22s -- %s','love'        ,['[1x1 ' class(self.love) ']'],'parameters for love solution'));
    13261329                        disp(sprintf('%19s: %-22s -- %s','esa'             ,['[1x1 ' class(self.esa) ']'],'parameters for elastic adjustment solution'));
    13271330                        disp(sprintf('%19s: %-22s -- %s','autodiff'        ,['[1x1 ' class(self.autodiff) ']'],'automatic differentiation parameters'));
  • issm/trunk-jpl/src/m/classes/model.py

    r21827 r22004  
    1818from levelset import levelset
    1919from calving import calving
     20from fourierlove import fourierlove
    2021from calvinglevermann import calvinglevermann
    2122#from calvingpi import calvingpi
     
    109110                self.levelset         = levelset()
    110111                self.calving          = calving()
     112                self.love             = fourierlove()
    111113                self.gia              = giaivins()
    112114
     
    153155                        'levelset',\
    154156                        'calving',\
    155                                         'gia',\
     157                        'gia',\
     158                        'love',\
    156159                        'autodiff',\
    157160                        'inversion',\
     
    195198                string="%s\n%s" % (string,"%19s: %-22s -- %s" % ("levelset","[%s,%s]" % ("1x1",obj.levelset.__class__.__name__),"parameters for moving boundaries (level-set method)"))
    196199                string="%s\n%s" % (string,"%19s: %-22s -- %s" % ("calving","[%s,%s]" % ("1x1",obj.calving.__class__.__name__),"parameters for calving"))
     200                string="%s\n%s" % (string,'%19s: %-22s -- %s' % ("love","[%s,%s]" % ("1x1",obj.love.__class__.__name__),"parameters for love solution"))
    197201                string="%s\n%s" % (string,"%19s: %-22s -- %s" % ("autodiff","[%s,%s]" % ("1x1",obj.autodiff.__class__.__name__),"automatic differentiation parameters"))
    198202                string="%s\n%s" % (string,"%19s: %-22s -- %s" % ("inversion","[%s,%s]" % ("1x1",obj.inversion.__class__.__name__),"parameters for inverse methods"))
  • issm/trunk-jpl/src/m/consistency/ismodelselfconsistent.m

    r21584 r22004  
    6666        elseif strcmp(solutiontype,'GiaSolution')
    6767                analyses={'GiaIvinsAnalysis'};
     68        elseif strcmp(solutiontype,'LoveSolution')
     69                analyses={'LoveAnalysis'};
    6870        elseif strcmp(solutiontype,'EsaSolution')
    6971                analyses={'EsaAnalysis'};
  • issm/trunk-jpl/src/m/consistency/ismodelselfconsistent.py

    r21584 r22004  
    3333        elif solutiontype == 'GiaSolution':
    3434                analyses=['GiaIvinsAnalysis']
     35
     36        elif solutiontype == 'LoveSolution':
     37                analyses=['LoveAnalysis']
    3538
    3639        elif solutiontype == 'TransientSolution':
  • issm/trunk-jpl/src/m/solve/marshall.py

    r21097 r22004  
    2020                raise IOError("marshall error message: could not open '%s.bin' file for binary writing." % md.miscellaneous.name)
    2121
    22         #Go through all model fields: check that it is a class and call checkconsistency
    23         fields=vars(md)
    24 
    25 #       for field in fields.iterkeys():
    2622        for field in md.properties():
    2723
  • issm/trunk-jpl/src/m/solve/solve.m

    r21584 r22004  
    2121%                - 'Esa'                or 'esa'
    2222%                - 'Sealevelrise'       or 'slr'
     23%                - 'Love'               or 'lv'
    2324%
    2425%  extra options:
     
    6465elseif strcmpi(solutionstring,'gia') || strcmpi(solutionstring,'Gia')
    6566        solutionstring = 'GiaSolution';
     67elseif strcmpi(solutionstring,'lv') || strcmpi(solutionstring,'Love')
     68        solutionstring = 'LoveSolution';
    6669elseif strcmpi(solutionstring,'esa') || strcmpi(solutionstring,'Esa')
    6770        solutionstring = 'EsaSolution';
  • issm/trunk-jpl/src/m/solve/solve.py

    r21584 r22004  
    3030                 - 'Gia'              or 'gia'
    3131                 - 'Sealevelrise'     or 'slr'
     32                 - 'Love'             or 'lv'
    3233
    3334           extra options:
     
    6667        elif solutionstring.lower() == 'gia' or solutionstring.lower() == 'gia':
    6768                solutionstring = 'GiaSolution';
     69        elif solutionstring.lower() == 'lv' or solutionstring.lower() == 'love':
     70                solutionstring = 'LoveSolution';
    6871        elif solutionstring.lower() == 'slr' or solutionstring.lower() == 'sealevelrise':
    6972                solutionstring = 'SealevelriseSolution';
Note: See TracChangeset for help on using the changeset viewer.