Changeset 12470


Ignore:
Timestamp:
06/20/12 08:41:52 (13 years ago)
Author:
utke
Message:

type renames

Location:
issm/trunk-jpl/src/c/modules
Files:
50 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/c/modules/CreateJacobianMatrixx/CreateJacobianMatrixx.cpp

    r11679 r12470  
    1010#include "../../EnumDefinitions/EnumDefinitions.h"
    1111
    12 void CreateJacobianMatrixx(Matrix** pJff,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,double kmax){
     12void CreateJacobianMatrixx(Matrix** pJff,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,IssmDouble kmax){
    1313       
    1414        int      i,connectivity;
  • issm/trunk-jpl/src/c/modules/CreateJacobianMatrixx/CreateJacobianMatrixx.h

    r11679 r12470  
    1010
    1111/* local prototypes: */
    12 void CreateJacobianMatrixx(Matrix** pJff,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,double kmax);
     12void CreateJacobianMatrixx(Matrix** pJff,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,IssmDouble kmax);
    1313
    1414#endif  /* _CREATEJACOBIANMATRIXX_H */
  • issm/trunk-jpl/src/c/modules/EnumToStringx/EnumToStringx.cpp

    r12450 r12470  
    467467        len=strlen(EnumToStringx(enum_in));
    468468        string=xNew<char>(len+1);
    469         memcpy(string,EnumToStringx(enum_in),(len+1)*sizeof(char));
     469        xMemCpy<char>(string,EnumToStringx(enum_in),(len+1));
    470470
    471471        /*Assign output pointer*/
  • issm/trunk-jpl/src/c/modules/GetVectorFromInputsx/GetVectorFromInputsx.cpp

    r11695 r12470  
    4141}
    4242
    43 void GetVectorFromInputsx( double** pvector, Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters, int name, int type){
     43void GetVectorFromInputsx( IssmDouble** pvector, Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters, int name, int type){
    4444       
    4545        /*output: */
    46         double* vector=NULL;
     46        IssmDouble* vector=NULL;
    4747       
    4848        /*intermediary: */
  • issm/trunk-jpl/src/c/modules/GetVectorFromInputsx/GetVectorFromInputsx.h

    r11695 r12470  
    1010/* local prototypes: */
    1111void    GetVectorFromInputsx( Vector** pvector, Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,int name,int type);
    12 void    GetVectorFromInputsx( double** pvector, Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,int name,int type);
     12void    GetVectorFromInputsx( IssmDouble** pvector, Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,int name,int type);
    1313
    1414#endif  /* _GETVECTORFROMINPUTSXX_H */
  • issm/trunk-jpl/src/c/modules/InputArtificialNoisex/InputArtificialNoisex.cpp

    r5578 r12470  
    99#include "../../EnumDefinitions/EnumDefinitions.h"
    1010
    11 void InputArtificialNoisex( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,int enum_name,double min,double max){
     11void InputArtificialNoisex( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,int enum_name,IssmDouble min,IssmDouble max){
    1212
    1313        int i;
  • issm/trunk-jpl/src/c/modules/InputArtificialNoisex/InputArtificialNoisex.h

    r5578 r12470  
    1010
    1111/* local prototypes: */
    12 void    InputArtificialNoisex( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,int enum_name,double min,double max);
     12void    InputArtificialNoisex( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,int enum_name,IssmDouble min,IssmDouble max);
    1313
    1414#endif  /* _UPDATEINPUTSFROMVECTORXX_H */
  • issm/trunk-jpl/src/c/modules/InputConvergencex/InputConvergencex.cpp

    r12450 r12470  
    99#include "../../EnumDefinitions/EnumDefinitions.h"
    1010
    11 bool InputConvergencex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int* enums, int num_enums, int* criterionenums, double* criterionvalues,int num_criterionenums){
     11bool InputConvergencex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int* enums, int num_enums, int* criterionenums, IssmDouble* criterionvalues,int num_criterionenums){
    1212
    1313        /*intermediary:*/
     
    1616        int      num_notconverged   = 0;
    1717        int      total_notconverged;
    18         double  *eps                = NULL;
     18        IssmDouble  *eps                = NULL;
    1919        Element *element            = NULL;
    2020
    2121        /*allocate dynamic memory: */
    22         eps=xNew<double>(num_criterionenums);
     22        eps=xNew<IssmDouble>(num_criterionenums);
    2323
    2424        /*Go through elements, and ask them to do the job: */
     
    3737
    3838        /*Free ressources:*/
    39         xDelete<double>(eps);
     39        xDelete<IssmDouble>(eps);
    4040
    4141        /*return: */
  • issm/trunk-jpl/src/c/modules/InputConvergencex/InputConvergencex.h

    r4778 r12470  
    88
    99/* local prototypes: */
    10 bool InputConvergencex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int* enums, int num_enums, int* criterionenums, double* criterionvalues,int num_criterionenums);
     10bool InputConvergencex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int* enums, int num_enums, int* criterionenums, IssmDouble* criterionvalues,int num_criterionenums);
    1111
    1212#endif  /* _INPUTCONVERGENCEX_H */
  • issm/trunk-jpl/src/c/modules/InputScalex/InputScalex.cpp

    r4573 r12470  
    99#include "../../EnumDefinitions/EnumDefinitions.h"
    1010
    11 void InputScalex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int enum_type, double scale_factor){
     11void InputScalex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int enum_type, IssmDouble scale_factor){
    1212
    1313        /*intermediary:*/
  • issm/trunk-jpl/src/c/modules/InputScalex/InputScalex.h

    r4236 r12470  
    99
    1010/* local prototypes: */
    11 void InputScalex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int enum_type, double scale_factor);
     11void InputScalex(Elements* elements,Nodes* nodes,Vertices* vertices,Loads* loads,Materials* materials,Parameters* parameters,int enum_type, IssmDouble scale_factor);
    1212
    1313#endif  /* _SCALEINPUTX_H */
  • issm/trunk-jpl/src/c/modules/InputToResultx/InputToResultx.cpp

    r11827 r12470  
    1313        /*intermediary:*/
    1414        int      step;
    15         double   time;
     15        IssmDouble   time;
    1616        Element *element = NULL;
    1717
  • issm/trunk-jpl/src/c/modules/InputUpdateFromConstantx/InputUpdateFromConstantx.cpp

    r4573 r12470  
    4949        }
    5050}
    51 void InputUpdateFromConstantx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,double constant, int name){
     51void InputUpdateFromConstantx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,IssmDouble constant, int name){
    5252
    5353        int i;
  • issm/trunk-jpl/src/c/modules/InputUpdateFromConstantx/InputUpdateFromConstantx.h

    r4236 r12470  
    1212void            InputUpdateFromConstantx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters, bool   constant, int name);
    1313void            InputUpdateFromConstantx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters, int    constant, int name);
    14 void            InputUpdateFromConstantx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters, double constant, int name);
     14void            InputUpdateFromConstantx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters, IssmDouble constant, int name);
    1515
    1616#endif  /* _UPDATEINPUTSFROMCONSTANTXX_H */
  • issm/trunk-jpl/src/c/modules/InputUpdateFromSolutionx/InputUpdateFromSolutionx.cpp

    r12450 r12470  
    1111void InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,Vector* solution){
    1212
    13         double* serial_solution=NULL;
     13        IssmDouble* serial_solution=NULL;
    1414
    1515        /*Serialize solution, so that elements can index into it on every CPU: */
     
    2020
    2121        /*Free ressources:*/
    22         xDelete<double>(serial_solution);
     22        xDelete<IssmDouble>(serial_solution);
    2323}
    2424
    2525
    26 void InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,double* solution){
     26void InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,IssmDouble* solution){
    2727
    2828        /*Intermediary*/
  • issm/trunk-jpl/src/c/modules/InputUpdateFromSolutionx/InputUpdateFromSolutionx.h

    r11679 r12470  
    1111/* local prototypes: */
    1212void            InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,Vector* solution);
    13 void        InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,double* solution);
     13void        InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,IssmDouble* solution);
    1414
    1515//with timestep
    1616void            InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,Vector* solution,int timestep);
    17 void        InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,double* solution, int timestep);
     17void        InputUpdateFromSolutionx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,IssmDouble* solution, int timestep);
    1818
    1919#endif  /* _UPDATEINPUTSFROMSOLUTIONXX_H */
  • issm/trunk-jpl/src/c/modules/InputUpdateFromVectorx/InputUpdateFromVectorx.cpp

    r12450 r12470  
    1111void InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,Vector* vector, int name, int type){
    1212
    13         double* serial_vector=NULL;
     13        IssmDouble* serial_vector=NULL;
    1414
    1515        serial_vector=vector->ToMPISerial();
     
    1818
    1919        /*Free ressources:*/
    20         xDelete<double>(serial_vector);
     20        xDelete<IssmDouble>(serial_vector);
    2121}
    2222
    2323       
    24 void InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,double* vector, int name, int type){
     24void InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,IssmDouble* vector, int name, int type){
    2525
    2626        int i;
  • issm/trunk-jpl/src/c/modules/InputUpdateFromVectorx/InputUpdateFromVectorx.h

    r11695 r12470  
    1111/* local prototypes: */
    1212void    InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,Vector* vector, int name,int type);
    13 void    InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,double* vector, int name,int type);
     13void    InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,IssmDouble* vector, int name,int type);
    1414void    InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,int* vector, int name,int type);
    1515void    InputUpdateFromVectorx( Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials,  Parameters* parameters,bool* vector, int name,int type);
  • issm/trunk-jpl/src/c/modules/IoModelToConstraintsx/IoModelToConstraintsx.cpp

    r12442 r12470  
    2222        int     counter;
    2323        int     nods;
    24         double* times=NULL;
    25         double* values=NULL;
     24        IssmDouble* times=NULL;
     25        IssmDouble* values=NULL;
    2626        bool    spcpresent=false;
    2727        int     count=0;
     
    2929
    3030        /*variables being fetched: */
    31         double *doublevector  = NULL;
     31        IssmDouble *IssmDoublevector  = NULL;
    3232        int     M,N;
    3333
     
    3838        fid=iomodel->SetFilePointerToData(&code, &vector_layout,vector_enum);
    3939
    40         if(code!=7)_error_("%s%s"," expecting a double vector for constraints with enum ",EnumToStringx(vector_enum));
     40        if(code!=7)_error_("%s%s"," expecting a IssmDouble vector for constraints with enum ",EnumToStringx(vector_enum));
    4141        if(vector_layout!=1)_error_("%s%s"," expecting a nodal vector for constraints with enum ",EnumToStringx(vector_enum));
    4242
    4343        /*Fetch vector:*/
    44         iomodel->FetchData(&doublevector,&M,&N,vector_enum);
     44        iomodel->FetchData(&IssmDoublevector,&M,&N,vector_enum);
    4545
    4646        /*Transient or static?:*/
     
    5555                        if((iomodel->my_vertices[i])){
    5656
    57                                 if (!isnan(doublevector[i])){
     57                                if (!isnan(IssmDoublevector[i])){
    5858
    59                                         constraints->AddObject(new SpcStatic(iomodel->constraintcounter+count+1,iomodel->nodecounter+i+1,1,doublevector[i],analysis_type));
     59                                        constraints->AddObject(new SpcStatic(iomodel->constraintcounter+count+1,iomodel->nodecounter+i+1,1,IssmDoublevector[i],analysis_type));
    6060                                        count++;
    6161                                }
     
    6969
    7070                /*figure out times: */
    71                 times=xNew<double>(N);
     71                times=xNew<IssmDouble>(N);
    7272                for(j=0;j<N;j++){
    73                         times[j]=doublevector[(M-1)*N+j];
     73                        times[j]=IssmDoublevector[(M-1)*N+j];
    7474                }
    7575                /*unit conversion: */
     
    8383
    8484                                /*figure out times and values: */
    85                                 values=xNew<double>(N);
     85                                values=xNew<IssmDouble>(N);
    8686                                spcpresent=false;
    8787                                for(j=0;j<N;j++){
    88                                         values[j]=doublevector[i*N+j];
     88                                        values[j]=IssmDoublevector[i*N+j];
    8989                                        if(!isnan(values[j]))spcpresent=true; //NaN means no spc by default
    9090                                }
     
    9494                                        count++;
    9595                                }
    96                                 xDelete<double>(values);
     96                                xDelete<IssmDouble>(values);
    9797                        }
    9898                }
     
    103103
    104104        /*Free ressources:*/
    105         xDelete<double>(doublevector);
    106         xDelete<double>(times);
    107         xDelete<double>(values);
     105        xDelete<IssmDouble>(IssmDoublevector);
     106        xDelete<IssmDouble>(times);
     107        xDelete<IssmDouble>(values);
    108108}
  • issm/trunk-jpl/src/c/modules/MeshPartitionx/MeshPartitionx.cpp

    r12450 r12470  
    99#include "../../EnumDefinitions/EnumDefinitions.h"
    1010
    11 int MeshPartitionx(int** pepart, int** pnpart, int numberofelements,int numberofnodes,double* elements,
    12                 int numberofelements2d,int numberofnodes2d,double* elements2d,int numlayers,int elements_width, int dim,int num_procs){
     11int MeshPartitionx(int** pepart, int** pnpart, int numberofelements,int numberofnodes,IssmDouble* elements,
     12                int numberofelements2d,int numberofnodes2d,IssmDouble* elements2d,int numlayers,int elements_width, int dim,int num_procs){
    1313
    1414        int noerr=1;
  • issm/trunk-jpl/src/c/modules/MeshPartitionx/MeshPartitionx.h

    r8303 r12470  
    66#define _MESHPARTITIONX_H
    77
     8#include "../../include/include.h"
     9
    810/* local prototypes: */
    9 int MeshPartitionx(int** pepart, int** pnpart, int numberofelements,int numberofnodes,double* elements,
    10                 int numberofelements2d,int numberofnodes2d,double* elements2d,int numlayers,int elements_width, int dim,int numareas);
     11int MeshPartitionx(int** pepart, int** pnpart, int numberofelements,int numberofnodes,IssmDouble* elements,
     12                int numberofelements2d,int numberofnodes2d,IssmDouble* elements2d,int numlayers,int elements_width, int dim,int numareas);
    1113       
    1214#endif /* _MESHPARTITIONX_H */
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/CreateNumberNodeToElementConnectivity.cpp

    r12450 r12470  
    2323        int    numberofelements;
    2424        int    numberofvertices;
    25         double* elements=NULL;
     25        IssmDouble* elements=NULL;
    2626
    2727        /*output*/
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/CreateParameters.cpp

    r12450 r12470  
    2424        int         numoutputs;
    2525        Parameters *parameters       = NULL;
    26         double     *requestedoutputs = NULL;
     26        IssmDouble     *requestedoutputs = NULL;
    2727       
    2828        if(*pparameters)return; //do not create parameters twice!
     
    105105        parameters->AddObject(new IntParam(DiagnosticNumRequestedOutputsEnum,numoutputs));
    106106        if(numoutputs)parameters->AddObject(new IntVecParam(DiagnosticRequestedOutputsEnum,requestedoutputs,numoutputs));
    107         xDelete<double>(requestedoutputs);
     107        xDelete<IssmDouble>(requestedoutputs);
    108108        iomodel->FetchData(&requestedoutputs,&numoutputs,NULL,TransientRequestedOutputsEnum);
    109109        parameters->AddObject(new IntParam(TransientNumRequestedOutputsEnum,numoutputs));
    110110        if(numoutputs)parameters->AddObject(new IntVecParam(TransientRequestedOutputsEnum,requestedoutputs,numoutputs));
    111         xDelete<double>(requestedoutputs);
     111        xDelete<IssmDouble>(requestedoutputs);
    112112        iomodel->FetchData(&requestedoutputs,&numoutputs,NULL,SteadystateRequestedOutputsEnum);
    113113        parameters->AddObject(new IntParam(SteadystateNumRequestedOutputsEnum,numoutputs));
    114114        if(numoutputs)parameters->AddObject(new IntVecParam(SteadystateRequestedOutputsEnum,requestedoutputs,numoutputs));
    115         xDelete<double>(requestedoutputs);
     115        xDelete<IssmDouble>(requestedoutputs);
    116116       
    117117        /*Before returning, create parameters in case we are running Qmu or control types runs: */
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/CreateSingleNodeToElementConnectivity.cpp

    r12450 r12470  
    2323        int    numberofelements;
    2424        int    numberofvertices;
    25         double* elements=NULL;
     25        IssmDouble* elements=NULL;
    2626
    2727        /*output*/
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/DistributeNumDofs.cpp

    r12450 r12470  
    77#include "../../EnumDefinitions/EnumDefinitions.h"
    88       
    9 void DistributeNumDofs(DofIndexing* index,int analysis_type,double* vertices_type){
     9void DistributeNumDofs(DofIndexing* index,int analysis_type,IssmDouble* vertices_type){
    1010
    1111        /*For now, we distribute by analysis_type, later, we will distribute using the analysis_type,
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/ElementsAndVerticesPartitioning.cpp

    r12450 r12470  
    4242        int  el1,el2;
    4343        int    dim;
    44         double* elements=NULL;
    45         double* elements2d=NULL;
    46         double* riftinfo=NULL;
    47         double* vertex_pairing=NULL;
     44        IssmDouble* elements=NULL;
     45        IssmDouble* elements2d=NULL;
     46        IssmDouble* riftinfo=NULL;
     47        IssmDouble* vertex_pairing=NULL;
    4848
    4949        /*Fetch parameters: */
     
    7676
    7777        /*Free elements and elements2d: */
    78         xDelete<double>(elements);
    79         xDelete<double>(elements2d);
     78        xDelete<IssmDouble>(elements);
     79        xDelete<IssmDouble>(elements2d);
    8080
    8181        /*Deal with rifts, they have to be included into one partition only, not several: */
     
    8787                        epart[el2]=epart[el1]; //ensures that this pair of elements will be in the same partition, as well as the corresponding vertices;
    8888                }
    89                 xDelete<double>(riftinfo);
     89                xDelete<IssmDouble>(riftinfo);
    9090        }
    9191
     
    119119        }//for (i=0;i<numberofelements;i++)
    120120        /*Free data : */
    121         xDelete<double>(elements);
     121        xDelete<IssmDouble>(elements);
    122122
    123123        /*We might have vertex_pairing in which case, some vertices have to be cloned:
     
    130130                }
    131131        }
    132         xDelete<double>(vertex_pairing);
     132        xDelete<IssmDouble>(vertex_pairing);
    133133        iomodel->FetchData(&vertex_pairing,&numvertex_pairing,NULL,PrognosticVertexPairingEnum);
    134134        for(i=0;i<numvertex_pairing;i++){
     
    137137                }
    138138        }
    139         xDelete<double>(vertex_pairing);
     139        xDelete<IssmDouble>(vertex_pairing);
    140140
    141141        /*Free ressources:*/
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/ModelProcessorx.h

    r10576 r12470  
    108108
    109109/*Distribution of dofs: */
    110 void DistributeNumDofs(DofIndexing* index,int analysis_type,double* vertices_type);
     110void DistributeNumDofs(DofIndexing* index,int analysis_type,IssmDouble* vertices_type);
    111111
    112112#endif
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/NodesPartitioning.cpp

    r12450 r12470  
    7171        int     i1,i2;
    7272        int     cols;
    73         double  e1,e2;
     73        IssmDouble  e1,e2;
    7474        int     pos;
    7575        int     numberofedges;
    76         double* edges=NULL;
    77         double* elements=NULL;
     76        IssmDouble* edges=NULL;
     77        IssmDouble* elements=NULL;
    7878
    7979        /*Fetch parameters: */
     
    158158
    159159        /*Free data: */
    160         xDelete<double>(elements);
    161         xDelete<double>(edges);
     160        xDelete<IssmDouble>(elements);
     161        xDelete<IssmDouble>(edges);
    162162
    163163        /*Assign output pointers:*/
  • issm/trunk-jpl/src/c/modules/ModelProcessorx/Prognostic/CreateLoadsPrognostic.cpp

    r12450 r12470  
    6161
    6262        /*Create Penpair for vertex_pairing: */
    63         double *vertex_pairing=NULL;
    64         double *nodeonbed=NULL;
     63        IssmDouble *vertex_pairing=NULL;
     64        IssmDouble *nodeonbed=NULL;
    6565        iomodel->FetchData(&vertex_pairing,&numvertex_pairing,NULL,PrognosticVertexPairingEnum);
    6666        iomodel->FetchData(&nodeonbed,NULL,NULL,MeshVertexonbedEnum);
     
    9090
    9191        /*free ressources: */
    92         xDelete<double>(vertex_pairing);
    93         xDelete<double>(nodeonbed);
     92        xDelete<IssmDouble>(vertex_pairing);
     93        xDelete<IssmDouble>(nodeonbed);
    9494
    9595        /*Assign output pointer: */
  • issm/trunk-jpl/src/c/modules/NodalValuex/NodalValuex.cpp

    r12102 r12470  
    1010#include "../../EnumDefinitions/EnumDefinitions.h"
    1111
    12 void NodalValuex( double* pnodalvalue, int natureofdataenum,Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,bool process_units){
     12void NodalValuex( IssmDouble* pnodalvalue, int natureofdataenum,Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,bool process_units){
    1313
    1414        extern int my_rank;
     
    1616        int index;
    1717        Element* element=NULL;
    18         double value;
     18        IssmDouble value;
    1919        int found;
    2020        int sumfound;
  • issm/trunk-jpl/src/c/modules/NodalValuex/NodalValuex.h

    r9206 r12470  
    1010
    1111/* local prototypes: */
    12 void NodalValuex( double* pnodalvalue, int natureofdataenum,Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,bool process_units);
     12void NodalValuex( IssmDouble* pnodalvalue, int natureofdataenum,Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters,bool process_units);
    1313
    1414#endif  /* _NODALVALUEX_H */
  • issm/trunk-jpl/src/c/modules/ParsePetscOptionsx/ParsePetscOptionsx.cpp

    r12450 r12470  
    2727
    2828        /*intermediary: */
    29         double* analyses=NULL;
     29        IssmPDouble* analyses=NULL;
    3030        char** strings=NULL;
    3131        int numanalyses;
     
    4848
    4949                /*Now, allocate analyses and strings: */
    50                 analyses=xNew<double>(numanalyses);
     50                analyses=xNew<IssmPDouble>(numanalyses);
    5151                strings=xNew<char*>(numanalyses);
    5252                for(i=0;i<numanalyses;i++)strings[i]=NULL;
     
    7171                                if(strings[numanalyses-1]==NULL){
    7272                                        string=xNew<char>((strlen(line)+1));
    73                                         memcpy(string,line,(strlen(line)+1)*sizeof(char));
     73                                        xMemCpy<char>(string,line,(strlen(line)+1));
    7474
    7575                                        strings[numanalyses-1]=string;
     
    7878                                        string=strings[numanalyses-1];
    7979                                        newstring=xNew<char>((strlen(line)+1));
    80                                         memcpy(newstring,line,(strlen(line)+1)*sizeof(char));
     80                                        xMemCpy<char>(newstring,line,(strlen(line)+1));
    8181
    8282                                        /*concatenate:*/
    8383                                        catstring=xNew<char>(strlen(string)+1+strlen(newstring)+1+1); //fit in a space " "
    84                                         memcpy(catstring,string,(strlen(string)+1)*sizeof(char));
     84                                        xMemCpy<char>(catstring,string,(strlen(string)+1));
    8585
    8686                                        strcat(catstring," ");
     
    9898        MPI_Bcast(&numanalyses,1,MPI_INT,0,MPI_COMM_WORLD);
    9999        if(my_rank!=0){
    100                 analyses=xNew<double>(numanalyses);
     100                analyses=xNew<IssmPDouble>(numanalyses);
    101101                strings=xNew<char*>(numanalyses);
    102102        }
     
    124124        for(i=0;i<numanalyses;i++) xDelete<char>(strings[i]);
    125125        xDelete<char*>(strings);
    126         xDelete<double>(analyses);
     126        xDelete<IssmPDouble>(analyses);
    127127        return;
    128128}
  • issm/trunk-jpl/src/c/modules/PositiveDegreeDayx/PositiveDegreeDayx.cpp

    r12450 r12470  
    2323
    2424  int    i, it, jj, itm;
    25   double DT = 0.02, sigfac, snormfac;
    26   double signorm = 5.5;      // signorm : sigma of the temperature distribution for a normal day
    27   double siglim;       // sigma limit for the integration which is equal to 2.5 sigmanorm
    28   double signormc = signorm - 0.5;     // sigma of the temperature distribution for cloudy day
    29   double siglimc, siglim0, siglim0c;
    30   double tstep, tsint, tint, tstepc;
     25  IssmDouble DT = 0.02, sigfac, snormfac;
     26  IssmDouble signorm = 5.5;      // signorm : sigma of the temperature distribution for a normal day
     27  IssmDouble siglim;       // sigma limit for the integration which is equal to 2.5 sigmanorm
     28  IssmDouble signormc = signorm - 0.5;     // sigma of the temperature distribution for cloudy day
     29  IssmDouble siglimc, siglim0, siglim0c;
     30  IssmDouble tstep, tsint, tint, tstepc;
    3131  int    NPDMAX = 1504, NPDCMAX = 1454;
    32   //double pdds[NPDMAX]={0};
    33   //double pds[NPDCMAX]={0};
    34   double pddt, pd ; // pd : snow/precip fraction, precipitation falling as snow
    35   double PDup, PDCUT = 2.0;    // PDcut: rain/snow cutoff temperature (C)
    36   double tstar; // monthly mean surface temp
     32  //IssmDouble pdds[NPDMAX]={0};
     33  //IssmDouble pds[NPDCMAX]={0};
     34  IssmDouble pddt, pd ; // pd : snow/precip fraction, precipitation falling as snow
     35  IssmDouble PDup, PDCUT = 2.0;    // PDcut: rain/snow cutoff temperature (C)
     36  IssmDouble tstar; // monthly mean surface temp
    3737 
    38   double* pdds=NULL;
    39   double* pds=NULL;
     38  IssmDouble* pdds=NULL;
     39  IssmDouble* pds=NULL;
    4040  Element* element = NULL;
    4141 
    42   pdds=xNew<double>(NPDMAX+1);
    43   pds=xNew<double>(NPDCMAX+1);
     42  pdds=xNew<IssmDouble>(NPDMAX+1);
     43  pds=xNew<IssmDouble>(NPDCMAX+1);
    4444 
    4545  // initialize PDD (creation of a lookup table)
     
    106106  }
    107107  /*free ressouces: */
    108   xDelete<double>(pdds);
    109   xDelete<double>(pds);
     108  xDelete<IssmDouble>(pdds);
     109  xDelete<IssmDouble>(pds);
    110110 
    111111}
  • issm/trunk-jpl/src/c/modules/Reducevectorgtofx/Reducevectorgtofx.cpp

    r12450 r12470  
    1515        int configuration_type;
    1616        int fsize;
    17         double* ug_serial=NULL;
     17        IssmDouble* ug_serial=NULL;
    1818
    1919        /*first figure out fsize: */
     
    5151
    5252        /*Free ressources:*/
    53         xDelete<double>(ug_serial);
     53        xDelete<IssmDouble>(ug_serial);
    5454
    5555        /*Assign output pointers:*/
  • issm/trunk-jpl/src/c/modules/RequestedOutputsx/RequestedOutputsx.cpp

    r11827 r12470  
    1313        int      output_enum;
    1414        int      step;
    15         double   time;
    16         double   output_value;
     15        IssmDouble   time;
     16        IssmDouble   output_value;
    1717        Element *element      = NULL;
    1818
  • issm/trunk-jpl/src/c/modules/Responsex/Responsex.cpp

    r11202 r12470  
    1616#include "../modules.h"
    1717
    18 void Responsex(double* responses,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,const char* response_descriptor,bool process_units,int weight_index){
     18void Responsex(IssmDouble* responses,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,const char* response_descriptor,bool process_units,int weight_index){
    1919
    2020        switch (StringToEnumx(response_descriptor)){
  • issm/trunk-jpl/src/c/modules/Responsex/Responsex.h

    r11202 r12470  
    99#include "../../Container/Container.h"
    1010
    11 void Responsex(double* presponse,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,const char* response_descriptor,bool process_units,int weight_index);
     11void Responsex(IssmDouble* presponse,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,const char* response_descriptor,bool process_units,int weight_index);
    1212
    1313#endif  /* _RESPONSESXX_H */
  • issm/trunk-jpl/src/c/modules/Solverx/DofTypesToIndexSet.cpp

    r12450 r12470  
    2020
    2121        int         start,end;
    22         double*     df_local=NULL;
     22        IssmDouble*     df_local=NULL;
    2323        int         df_local_size;
    2424        int         i;
  • issm/trunk-jpl/src/c/modules/Solverx/Solverx.h

    r12417 r12470  
    2424#ifdef _HAVE_GSL_
    2525void SolverxGsl(SeqVec** puf,SeqMat* Kff, SeqVec* pf);
    26 void SolverxGsl(double** pX,double* A,double* B,int n);
     26void SolverxGsl(IssmDouble** pX,IssmDouble* A,IssmDouble* B,int n);
    2727#endif
    2828
  • issm/trunk-jpl/src/c/modules/Solverx/SolverxGsl.cpp

    r12450 r12470  
    2121        int M,N,N2,s;
    2222        SeqVec *uf = NULL;
    23         double *x  = NULL;
     23        IssmDouble *x  = NULL;
    2424
    2525        Kff->GetSize(&M,&N);
     
    3535        *puf=uf;
    3636}/*}}}*/
    37 void SolverxGsl(double** pX,double* A,double* B,int n){/*{{{*/
     37void SolverxGsl(IssmDouble** pX,IssmDouble* A,IssmDouble* B,int n){/*{{{*/
    3838
    3939        /*GSL Matrices and vectors: */
     
    4545
    4646        /*A will be modified by LU decomposition. Use copy*/
    47         double* Acopy = xNew<double>(n*n);
    48         memcpy(Acopy,A,n*n*sizeof(double));
     47        IssmDouble* Acopy = xNew<IssmDouble>(n*n);
     48        xMemCpy<IssmDouble>(Acopy,A,n*n);
    4949
    5050        /*Initialize gsl matrices and vectors: */
     
    6262
    6363        /*Copy result*/
    64         double* X = xNew<double>(n);
    65         memcpy(X,gsl_vector_ptr(x,0),n*sizeof(double));
     64        IssmDouble* X = xNew<IssmDouble>(n);
     65        memcpy(X,gsl_vector_ptr(x,0),n*sizeof(IssmDouble));
    6666
    6767        /*Clean up and assign output pointer*/
    68         xDelete<double>(Acopy);
     68        xDelete<IssmDouble>(Acopy);
    6969        gsl_permutation_free(p);
    7070        gsl_vector_free(x);
  • issm/trunk-jpl/src/c/modules/SurfaceAreax/SurfaceAreax.cpp

    r12102 r12470  
    1111#include "../InputUpdateFromConstantx/InputUpdateFromConstantx.h"
    1212
    13 void SurfaceAreax( double* pS, Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials,Parameters* parameters){
     13void SurfaceAreax( IssmDouble* pS, Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials,Parameters* parameters){
    1414       
    1515        /*Intermediary*/
     
    1818
    1919        /*output: */
    20         double S=0;
    21         double S_sum;
     20        IssmDouble S=0;
     21        IssmDouble S_sum;
    2222       
    2323        /*Compute gradients: */
  • issm/trunk-jpl/src/c/modules/SurfaceAreax/SurfaceAreax.h

    r4236 r12470  
    1010
    1111/* local prototypes: */
    12 void SurfaceAreax( double* pS, Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters);
     12void SurfaceAreax( IssmDouble* pS, Elements* elements,Nodes* nodes, Vertices* vertices, Loads* loads, Materials* materials, Parameters* parameters);
    1313
    1414#endif  /* _SURFACEAREAX_H */
  • issm/trunk-jpl/src/c/modules/SystemMatricesx/SystemMatricesx.cpp

    r12365 r12470  
    1010#include "../../EnumDefinitions/EnumDefinitions.h"
    1111
    12 void SystemMatricesx(Matrix** pKff, Matrix** pKfs, Vector** ppf, Vector** pdf, double* pkmax,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,bool kflag,bool pflag,bool penalty_kflag,bool penalty_pflag){
     12void SystemMatricesx(Matrix** pKff, Matrix** pKfs, Vector** ppf, Vector** pdf, IssmDouble* pkmax,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,bool kflag,bool pflag,bool penalty_kflag,bool penalty_pflag){
    1313       
    1414        /*intermediary: */
     
    2525        Vector*    pf   = NULL;
    2626        Vector*    df=NULL;
    27         double kmax = 0;
     27        IssmDouble kmax = 0;
    2828
    2929        /*Display message*/
  • issm/trunk-jpl/src/c/modules/SystemMatricesx/SystemMatricesx.h

    r11679 r12470  
    1010
    1111/* local prototypes: */
    12 void SystemMatricesx(Matrix** pKff, Matrix** pKfs, Vector** ppf, Vector** pdf, double* pkmax,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,
     12void SystemMatricesx(Matrix** pKff, Matrix** pKfs, Vector** ppf, Vector** pdf, IssmDouble* pkmax,Elements* elements,Nodes* nodes, Vertices* vertices,Loads* loads,Materials* materials, Parameters* parameters,
    1313                        bool kflag=true,bool pflag=true,bool penalty_kflag=true,bool penalty_pflag=true);
    1414
  • issm/trunk-jpl/src/c/modules/TimeAdaptx/TimeAdaptx.cpp

    r12102 r12470  
    1010#include "../../Container/Container.h"
    1111
    12 void TimeAdaptx(double* pdt, Elements* elements, Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials, Parameters* parameters){
     12void TimeAdaptx(IssmDouble* pdt, Elements* elements, Nodes* nodes, Vertices* vertices,Loads* loads, Materials* materials, Parameters* parameters){
    1313
    1414        int      i;
    1515
    1616        /*output: */
    17         double   dt;
     17        IssmDouble   dt;
    1818
    1919        /*intermediary: */
    2020        Element *element     = NULL;
    21         double   min_dt      = 0;
    22         double   node_min_dt = 0;
     21        IssmDouble   min_dt      = 0;
     22        IssmDouble   node_min_dt = 0;
    2323
    2424        /*Go through elements, and figure out the minimum of the time steps for each element (using CFL criterion): */
  • issm/trunk-jpl/src/c/modules/TimeAdaptx/TimeAdaptx.h

    r6130 r12470  
    99
    1010/* local prototypes: */
    11 void TimeAdaptx(double* pdt, Elements* elements, Nodes* nodes,Vertices* vertices,Loads* loads, Materials* materials, Parameters* parameters);
     11void TimeAdaptx(IssmDouble* pdt, Elements* elements, Nodes* nodes,Vertices* vertices,Loads* loads, Materials* materials, Parameters* parameters);
    1212
    1313#endif  /* _TIMEADAPTX_H */
  • issm/trunk-jpl/src/c/modules/UpdateConstraintsx/UpdateConstraintsx.cpp

    r9761 r12470  
    1414void UpdateConstraintsx(Nodes* nodes,Constraints* constraints,Parameters* parameters){
    1515
    16         double time;
     16        IssmDouble time;
    1717        int    analysis_type;
    1818
  • issm/trunk-jpl/src/c/modules/UpdateDynamicConstraintsx/UpdateDynamicConstraintsx.cpp

    r12450 r12470  
    1313       
    1414        int configuration_type;
    15         double* yg_serial=NULL;
     15        IssmDouble* yg_serial=NULL;
    1616
    1717        /*Get current configuration*/
     
    3434
    3535        /*Free ressources:*/
    36         xDelete<double>(yg_serial);
     36        xDelete<IssmDouble>(yg_serial);
    3737}
  • issm/trunk-jpl/src/c/modules/UpdateVertexPositionsx/UpdateVertexPositionsx.cpp

    r12450 r12470  
    1515        Vector*     vz        = NULL;
    1616        Vertex *vertex    = NULL;
    17         double *thickness = NULL;
    18         double *bed       = NULL;
     17        IssmDouble *thickness = NULL;
     18        IssmDouble *bed       = NULL;
    1919
    2020        /*get vertex vectors for bed and thickness: */
     
    3838
    3939        /*Free ressources:*/
    40         xDelete<double>(thickness);
    41         xDelete<double>(bed);
     40        xDelete<IssmDouble>(thickness);
     41        xDelete<IssmDouble>(bed);
    4242        xdelete(&vz);
    4343        return 1;
  • issm/trunk-jpl/src/c/modules/VecMergex/VecMergex.cpp

    r12450 r12470  
    1515        int i;
    1616        int configuration_type;
    17         double* uf_serial=NULL;
     17        IssmDouble* uf_serial=NULL;
    1818
    1919        /*retrieve parameters: */
     
    4141        }
    4242        /*Free ressources:*/
    43         xDelete<double>(uf_serial);
     43        xDelete<IssmDouble>(uf_serial);
    4444
    4545        /*Assemble vector: */
Note: See TracChangeset for help on using the changeset viewer.