Changeset 11656


Ignore:
Timestamp:
03/07/12 13:38:04 (13 years ago)
Author:
Mathieu Morlighem
Message:

updated compilation flag definition for ADIC

Location:
issm/trunk-jpl/src/c
Files:
9 edited

Legend:

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

    r11643 r11656  
    204204                                        ./shared/Elements/GetGlobalDofList.cpp\
    205205                                        ./shared/Elements/GetNumberOfDofs.cpp\
    206                                         ./shared/Elements/CoordinateSystemTransform.cpp\
    207206                                        ./shared/String/sharedstring.h\
    208207                                        ./toolkits/petsc\
     
    502501                                              ./modules/ModelProcessorx/DiagnosticHutter/CreateConstraintsDiagnosticHutter.cpp \
    503502                                              ./modules/ModelProcessorx/DiagnosticHutter/CreateLoadsDiagnosticHutter.cpp \
     503                                                        ./shared/Elements/CoordinateSystemTransform.cpp\
    504504                                                        ./shared/Elements/TransformLoadVectorCoord.cpp \
    505505                                                        ./shared/Elements/TransformStiffnessMatrixCoord.cpp \
  • issm/trunk-jpl/src/c/objects/Elements/Element.h

    r11508 r11656  
    5858                virtual void   RequestedOutput(int output_enum,int step,double time)=0;
    5959               
     60                virtual int    NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units)=0;
    6061                virtual void   InputScale(int enum_type,double scale_factor)=0;
    6162                virtual void   GetVectorFromInputs(Vec vector, int name_enum)=0;
     
    8889                virtual void   ElementResponse(double* presponse,int response_enum,bool process_units)=0;
    8990                virtual double IceVolume(void)=0;
    90                 virtual int    NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units)=0;
    9191                #endif
    9292
  • issm/trunk-jpl/src/c/objects/Elements/Penta.cpp

    r11508 r11656  
    23252325        extern int my_rank;
    23262326        return my_rank;
     2327}
     2328/*}}}*/
     2329/*FUNCTION Penta::NodalValue {{{1*/
     2330int    Penta::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
     2331
     2332        int i;
     2333        int found=0;
     2334        double value;
     2335        Input* data=NULL;
     2336        GaussPenta* gauss=NULL;
     2337
     2338        /*First, serarch the input: */
     2339        data=inputs->GetInput(natureofdataenum);
     2340
     2341        /*figure out if we have the vertex id: */
     2342        found=0;
     2343        for(i=0;i<NUMVERTICES;i++){
     2344                if(index==nodes[i]->GetVertexId()){
     2345                        /*Do we have natureofdataenum in our inputs? :*/
     2346                        if(data){
     2347                                /*ok, we are good. retrieve value of input at vertex :*/
     2348                                gauss=new GaussPenta(); gauss->GaussVertex(i);
     2349                                data->GetInputValue(&value,gauss);
     2350                                found=1;
     2351                                break;
     2352                        }
     2353                }
     2354        }
     2355
     2356        if(found)*pvalue=value;
     2357        return found;
    23272358}
    23282359/*}}}*/
     
    30023033}
    30033034/*}}}*/
    3004 /*FUNCTION Penta::NodalValue {{{1*/
    3005 int    Penta::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
    3006 
    3007         int i;
    3008         int found=0;
    3009         double value;
    3010         Input* data=NULL;
    3011         GaussPenta* gauss=NULL;
    3012 
    3013         /*First, serarch the input: */
    3014         data=inputs->GetInput(natureofdataenum);
    3015 
    3016         /*figure out if we have the vertex id: */
    3017         found=0;
    3018         for(i=0;i<NUMVERTICES;i++){
    3019                 if(index==nodes[i]->GetVertexId()){
    3020                         /*Do we have natureofdataenum in our inputs? :*/
    3021                         if(data){
    3022                                 /*ok, we are good. retrieve value of input at vertex :*/
    3023                                 gauss=new GaussPenta(); gauss->GaussVertex(i);
    3024                                 data->GetInputValue(&value,gauss);
    3025                                 found=1;
    3026                                 break;
    3027                         }
    3028                 }
    3029         }
    3030 
    3031         if(found)*pvalue=value;
    3032         return found;
    3033 }
    3034 /*}}}*/
    30353035/*FUNCTION Penta::MinVel{{{1*/
    30363036void  Penta::MinVel(double* pminvel, bool process_units){
  • issm/trunk-jpl/src/c/objects/Elements/Penta.h

    r11508 r11656  
    118118                void   Update(int index, IoModel* iomodel,int analysis_counter,int analysis_type);
    119119                int    UpdatePotentialSheetUngrounding(double* potential_sheet_ungrounding,Vec vec_nodes_on_iceshelf,double* nodes_on_iceshelf);
     120                int    NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
    120121                double TimeAdapt();
    121122                int*   GetHorizontalNeighboorSids(void);
     
    129130                void   MinVy(double* pminvy, bool process_units);
    130131                void   MinVz(double* pminvz, bool process_units);
    131                 int    NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
    132132                double MassFlux(double* segment,bool process_units);
    133133                void   MaxAbsVx(double* pmaxabsvx, bool process_units);
  • issm/trunk-jpl/src/c/objects/Elements/Tria.cpp

    r11563 r11656  
    21232123}
    21242124/*}}}*/
     2125/*FUNCTION Tria::NodalValue {{{1*/
     2126int    Tria::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
     2127
     2128        int i;
     2129        int found=0;
     2130        double value;
     2131        Input* data=NULL;
     2132        GaussTria *gauss                            = NULL;
     2133
     2134        /*First, serarch the input: */
     2135        data=inputs->GetInput(natureofdataenum);
     2136
     2137        /*figure out if we have the vertex id: */
     2138        found=0;
     2139        for(i=0;i<NUMVERTICES;i++){
     2140                if(index==nodes[i]->GetVertexId()){
     2141                        /*Do we have natureofdataenum in our inputs? :*/
     2142                        if(data){
     2143                                /*ok, we are good. retrieve value of input at vertex :*/
     2144                                gauss=new GaussTria(); gauss->GaussVertex(i);
     2145                                data->GetInputValue(&value,gauss);
     2146                                found=1;
     2147                                break;
     2148                        }
     2149                }
     2150        }
     2151
     2152        if(found)*pvalue=value;
     2153        return found;
     2154}
     2155/*}}}*/
    21252156/*FUNCTION Tria::PatchFill{{{1*/
    21262157void  Tria::PatchFill(int* prow, Patch* patch){
     
    27372768        /*Assign output pointers:*/
    27382769        *pminvz=minvz;
    2739 }
    2740 /*}}}*/
    2741 /*FUNCTION Tria::NodalValue {{{1*/
    2742 int    Tria::NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units){
    2743 
    2744         int i;
    2745         int found=0;
    2746         double value;
    2747         Input* data=NULL;
    2748         GaussTria *gauss                            = NULL;
    2749 
    2750         /*First, serarch the input: */
    2751         data=inputs->GetInput(natureofdataenum);
    2752 
    2753         /*figure out if we have the vertex id: */
    2754         found=0;
    2755         for(i=0;i<NUMVERTICES;i++){
    2756                 if(index==nodes[i]->GetVertexId()){
    2757                         /*Do we have natureofdataenum in our inputs? :*/
    2758                         if(data){
    2759                                 /*ok, we are good. retrieve value of input at vertex :*/
    2760                                 gauss=new GaussTria(); gauss->GaussVertex(i);
    2761                                 data->GetInputValue(&value,gauss);
    2762                                 found=1;
    2763                                 break;
    2764                         }
    2765                 }
    2766         }
    2767 
    2768         if(found)*pvalue=value;
    2769         return found;
    27702770}
    27712771/*}}}*/
  • issm/trunk-jpl/src/c/objects/Elements/Tria.h

    r11508 r11656  
    106106                void   MaterialUpdateFromTemperature(void){_error_("not implemented yet");};
    107107                void   MigrateGroundingLine(double* oldfloating,double* sheet_ungrounding);
     108                int    NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
    108109                void   PotentialSheetUngrounding(Vec potential_sheet_ungrounding);
    109110                void   PositiveDegreeDay(void);
     
    127128                void   MinVy(double* pminvy, bool process_units);
    128129                void   MinVz(double* pminvz, bool process_units);
    129                 int    NodalValue(double* pvalue, int index, int natureofdataenum,bool process_units);
    130130                double MassFlux(double* segment,bool process_units);
    131131                void   MaxAbsVx(double* pmaxabsvx, bool process_units);
  • issm/trunk-jpl/src/c/objects/Loads/Pengrid.cpp

    r10576 r11656  
    319319
    320320        switch(analysis_type){
     321                #ifdef _HAVE_DIAGNOSTIC_
    321322                case DiagnosticHorizAnalysisEnum: case AdjointHorizAnalysisEnum:
    322323                        Ke=PenaltyCreateKMatrixDiagnosticStokes(kmax);
    323324                        break;
     325                #endif
     326                #ifdef _HAVE_THERMAL_
    324327                case ThermalAnalysisEnum:
    325328                        Ke=PenaltyCreateKMatrixThermal(kmax);
     
    328331                        Ke=PenaltyCreateKMatrixMelting(kmax);
    329332                        break;
     333                #endif
    330334                default:
    331335                        _error_("analysis %i (%s) not supported yet",analysis_type,EnumToStringx(analysis_type));
     
    348352
    349353        switch(analysis_type){
     354                #ifdef _HAVE_DIAGNOSTIC_
    350355                case ThermalAnalysisEnum:
    351356                        pe=PenaltyCreatePVectorThermal(kmax);
    352357                        break;
     358                #endif
     359                #ifdef _HAVE_THERMAL_
    353360                case MeltingAnalysisEnum:
    354361                        pe=PenaltyCreatePVectorMelting(kmax);
     
    356363                case DiagnosticHorizAnalysisEnum: case AdjointHorizAnalysisEnum:
    357364                        break;
     365                #endif
    358366                default:
    359367                        _error_("analysis %i (%s) not supported yet",analysis_type,EnumToStringx(analysis_type));
     
    539547}
    540548/*}}}1*/
     549#ifdef _HAVE_DIAGNOSTIC_
    541550/*FUNCTION Pengrid::PenaltyCreateKMatrixDiagnosticStokes {{{1*/
    542551ElementMatrix* Pengrid::PenaltyCreateKMatrixDiagnosticStokes(double kmax){
     
    571580}
    572581/*}}}1*/
     582#endif
     583#ifdef _HAVE_THERMAL_
    573584/*FUNCTION Pengrid::PenaltyCreateKMatrixMelting {{{1*/
    574585ElementMatrix* Pengrid::PenaltyCreateKMatrixMelting(double kmax){
     
    690701}
    691702/*}}}1*/
     703#endif
    692704/*FUNCTION Pengrid::ResetConstraint {{{1*/
    693705void  Pengrid::ResetConstraint(void){
  • issm/trunk-jpl/src/c/objects/Loads/Pengrid.h

    r11327 r11656  
    8484                /*}}}*/
    8585                /*Pengrid management {{{1*/
     86                #ifdef _HAVE_DIAGNOSTIC_
    8687                ElementMatrix* PenaltyCreateKMatrixDiagnosticStokes(double kmax);
     88                #endif
     89                #ifdef _HAVE_THERMAL_
    8790                ElementMatrix* PenaltyCreateKMatrixThermal(double kmax);
    8891                ElementMatrix* PenaltyCreateKMatrixMelting(double kmax);
    8992                ElementVector* PenaltyCreatePVectorThermal(double kmax);
    9093                ElementVector* PenaltyCreatePVectorMelting(double kmax);
     94                #endif
    9195                void  ConstraintActivate(int* punstable);
    9296                void  ConstraintActivateThermal(int* punstable);
  • issm/trunk-jpl/src/c/shared/Elements/elements.h

    r11197 r11656  
    1717int*   GetLocalDofList( Node** nodes,int numnodes,int setenum,int approximation_enum);
    1818int*   GetGlobalDofList(Node** nodes,int numnodes,int setenum,int approximation_enum);
     19#ifdef _HAVE_DIAGNOSTIC_
    1920void   CoordinateSystemTransform(double** ptransform,Node** nodes,int numnodes,int* cs_array);
    20 #ifdef _HAVE_DIAGNOSTIC_
    2121void   TransformInvStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int cs_enum);
    2222void   TransformInvStiffnessMatrixCoord(ElementMatrix* Ke,Node** nodes,int numnodes,int* cs_array);
Note: See TracChangeset for help on using the changeset viewer.