source: issm/oecreview/Archive/12321-12677/ISSM-12559-12560.diff@ 12679

Last change on this file since 12679 was 12679, checked in by Mathieu Morlighem, 13 years ago

Added 12321-12677

File size: 8.7 KB
RevLine 
[12679]1Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/TriaP1ElementResult.h
2===================================================================
3--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/TriaP1ElementResult.h (revision 12559)
4+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/TriaP1ElementResult.h (revision 12560)
5@@ -16,9 +16,9 @@
6
7 private:
8 int enum_type;
9- IssmDouble values[3];
10+ IssmPDouble values[3];
11 int step;
12- IssmDouble time;
13+ IssmPDouble time;
14
15 public:
16
17@@ -37,7 +37,7 @@
18 /*}}}*/
19 /*ElementResult virtual functions definitions: {{{*/
20 ElementResult* SpawnTriaElementResult(int* indices);
21- IssmDouble GetTime(void){return time;};
22+ IssmPDouble GetTime(void){return time;};
23 int GetStep(void){return step;};
24 void ProcessUnits(Parameters* parameters);
25 int NumberOfNodalValues(void);
26Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/PentaP1ElementResult.cpp
27===================================================================
28--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/PentaP1ElementResult.cpp (revision 12559)
29+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/PentaP1ElementResult.cpp (revision 12560)
30@@ -29,9 +29,9 @@
31 int i;
32
33 enum_type=in_enum_type;
34- for(i=0;i<6;i++)values[i]=in_values[i];
35+ for(i=0;i<6;i++)values[i]=reCast<IssmPDouble>(in_values[i]);
36 step=in_step;
37- time=in_time;
38+ time=reCast<IssmPDouble>(in_time);
39 }
40 /*}}}*/
41 /*FUNCTION PentaP1ElementResult::~PentaP1ElementResult(){{{*/
42@@ -94,7 +94,7 @@
43
44 /*output*/
45 TriaP1ElementResult* outresult=NULL;
46- IssmDouble newvalues[3];
47+ IssmPDouble newvalues[3];
48
49 /*Loop over the new indices*/
50 for(int i=0;i<3;i++){
51@@ -139,10 +139,10 @@
52 /*FUNCTION PentaP1ElementResult::GetVectorFromResults{{{*/
53 void PentaP1ElementResult::GetVectorFromResults(Vector* vector,int* doflist,int* connectivitylist,int numdofs){
54
55- IssmDouble data[6];
56+ IssmPDouble data[6];
57
58 if(numdofs!=6)_error2_("Result " << EnumToStringx(this->enum_type) << " is a PentaP1ElementResult and cannot write vector of " << numdofs << " dofs");
59- for(int i=0;i<6;i++) data[i]=this->values[i]/(IssmDouble)connectivitylist[i];
60+ for(int i=0;i<6;i++) data[i]=this->values[i]/(IssmPDouble)connectivitylist[i];
61 vector->SetValues(numdofs,doflist,&data[0],ADD_VAL);
62
63 } /*}}}*/
64Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/DoubleElementResult.cpp
65===================================================================
66--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/DoubleElementResult.cpp (revision 12559)
67+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/DoubleElementResult.cpp (revision 12560)
68@@ -27,9 +27,9 @@
69 DoubleElementResult::DoubleElementResult(int in_enum_type,IssmDouble in_value,int in_step, IssmDouble in_time){
70
71 enum_type=in_enum_type;
72- value=in_value;
73+ value=reCast<IssmPDouble>(in_value);
74 step=in_step;
75- time=in_time;
76+ time=reCast<IssmPDouble>(in_time);
77 }
78 /*}}}*/
79 /*FUNCTION DoubleElementResult::~DoubleElementResult(){{{*/
80Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/PentaP1ElementResult.h
81===================================================================
82--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/PentaP1ElementResult.h (revision 12559)
83+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/PentaP1ElementResult.h (revision 12560)
84@@ -17,9 +17,9 @@
85
86 private:
87 int enum_type;
88- IssmDouble values[6];
89+ IssmPDouble values[6];
90 int step;
91- IssmDouble time;
92+ IssmPDouble time;
93
94 public:
95
96@@ -38,7 +38,7 @@
97 /*}}}*/
98 /*ElementResult virtual functions definitions: {{{*/
99 ElementResult* SpawnTriaElementResult(int* indices);
100- IssmDouble GetTime(void){return time;};
101+ IssmPDouble GetTime(void){return time;};
102 int GetStep(void){return step;};
103 void ProcessUnits(Parameters* parameters);
104 int NumberOfNodalValues(void);
105Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/DoubleElementResult.h
106===================================================================
107--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/DoubleElementResult.h (revision 12559)
108+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/DoubleElementResult.h (revision 12560)
109@@ -1,6 +1,6 @@
110 /*! \file DoubleElementResult.h
111- * \brief: header file for IssmDouble result object
112- * A IssmDouble result object is just derived from a DoubleInput object, with additional time and step information.
113+ * \brief: header file for IssmPDouble result object
114+ * A IssmPDouble result object is just derived from a DoubleInput object, with additional time and step information.
115 */
116
117
118@@ -18,9 +18,9 @@
119
120 private:
121 int enum_type;
122- IssmDouble value;
123+ IssmPDouble value;
124 int step;
125- IssmDouble time;
126+ IssmPDouble time;
127
128 public:
129
130@@ -39,7 +39,7 @@
131 /*}}}*/
132 /*ElementResult virtual functions definitions: {{{*/
133 ElementResult* SpawnTriaElementResult(int* indices);
134- IssmDouble GetTime(void){return time;};
135+ IssmPDouble GetTime(void){return time;};
136 int GetStep(void){return step;};
137 void ProcessUnits(Parameters* parameters);
138 int NumberOfNodalValues(void);
139Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/BoolElementResult.h
140===================================================================
141--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/BoolElementResult.h (revision 12559)
142+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/BoolElementResult.h (revision 12560)
143@@ -20,7 +20,7 @@
144 int enum_type;
145 bool value;
146 int step;
147- IssmDouble time;
148+ IssmPDouble time;
149
150 public:
151
152@@ -39,7 +39,7 @@
153 /*}}}*/
154 /*ElementResult virtual functions definitions: {{{*/
155 ElementResult* SpawnTriaElementResult(int* indices);
156- IssmDouble GetTime(void){return time;};
157+ IssmPDouble GetTime(void){return time;};
158 int GetStep(void){return step;};
159 void ProcessUnits(Parameters* parameters);
160 int NumberOfNodalValues(void);
161Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/TriaP1ElementResult.cpp
162===================================================================
163--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/TriaP1ElementResult.cpp (revision 12559)
164+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/TriaP1ElementResult.cpp (revision 12560)
165@@ -27,11 +27,11 @@
166 TriaP1ElementResult::TriaP1ElementResult(int in_enum_type,IssmDouble* in_values,int in_step, IssmDouble in_time){
167
168 enum_type=in_enum_type;
169- values[0]=in_values[0];
170- values[1]=in_values[1];
171- values[2]=in_values[2];
172+ values[0]=reCast<IssmPDouble>(in_values[0]);
173+ values[1]=reCast<IssmPDouble>(in_values[1]);
174+ values[2]=reCast<IssmPDouble>(in_values[2]);
175 step=in_step;
176- time=in_time;
177+ time=reCast<IssmPDouble>(in_time);
178 }
179 /*}}}*/
180 /*FUNCTION TriaP1ElementResult::~TriaP1ElementResult(){{{*/
181@@ -127,10 +127,10 @@
182 /*FUNCTION TriaP1ElementResult::GetVectorFromResults{{{*/
183 void TriaP1ElementResult::GetVectorFromResults(Vector* vector,int* doflist,int* connectivitylist,int numdofs){
184
185- IssmDouble data[3];
186+ IssmPDouble data[3];
187
188 if(numdofs!=3)_error2_("Result " << EnumToStringx(this->enum_type) << " is a TriaP1ElementResult and cannot write vector of " << numdofs << " dofs");
189- for(int i=0;i<3;i++) data[i]=this->values[i]/(IssmDouble)connectivitylist[i];
190+ for(int i=0;i<3;i++) data[i]=this->values[i]/(IssmPDouble)connectivitylist[i];
191 vector->SetValues(numdofs,doflist,&data[0],ADD_VAL);
192
193 } /*}}}*/
194Index: /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/ElementResult.h
195===================================================================
196--- /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/ElementResult.h (revision 12559)
197+++ /u/astrid-r1b/morlighe/issmuci/trunk-jpl/../trunk-jpl/src/c/objects/ElementResults/ElementResult.h (revision 12560)
198@@ -18,7 +18,7 @@
199 virtual ~ElementResult(){};
200
201 virtual ElementResult* SpawnTriaElementResult(int* indices)=0;
202- virtual IssmDouble GetTime(void)=0;
203+ virtual IssmPDouble GetTime(void)=0;
204 virtual int GetStep(void)=0;
205 virtual void ProcessUnits(Parameters* parameters)=0;
206 virtual int NumberOfNodalValues(void)=0;
Note: See TracBrowser for help on using the repository browser.