Changeset 19264
- Timestamp:
- 04/07/15 14:12:36 (10 years ago)
- Location:
- issm/trunk-jpl/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/classes/Elements/Element.cpp
r19254 r19264 539 539 input2->GetInputValue(&TemperaturesLgm[iv][month],gauss,month/12.*yts); 540 540 input3->GetInputValue(&PrecipitationsPresentday[iv][month],gauss,month/12.*yts); 541 542 PrecipitationsPresentday[iv][month]=PrecipitationsPresentday[iv][month]*yts; 541 543 } 542 544 } … … 570 572 default: _error_("Not implemented yet"); 571 573 } 572 for(i=0;i<numvertices;i++) tmp[i]=monthlyprec[i][imonth] ;574 for(i=0;i<numvertices;i++) tmp[i]=monthlyprec[i][imonth]/yts; 573 575 switch(this->ObjectEnum()){ 574 576 case TriaEnum: NewPrecipitationInput->AddTimeInput(new TriaInput(SurfaceforcingsPrecipitationEnum,&tmp[0],P1Enum),time_yr+imonth/12.*yts); break; … … 629 631 input3->GetInputValue(&PrecipitationsPresentday[iv][month],gauss,month/12.*yts); 630 632 input4->GetInputValue(&PrecipitationsLgm[iv][month],gauss,month/12.*yts); 633 634 PrecipitationsPresentday[iv][month]=PrecipitationsPresentday[iv][month]*yts; 635 PrecipitationsLgm[iv][month]=PrecipitationsLgm[iv][month]*yts; 631 636 } 632 637 } … … 655 660 default: _error_("Not implemented yet"); 656 661 } 657 for(i=0;i<numvertices;i++) tmp[i]=monthlyprec[i][imonth] ;662 for(i=0;i<numvertices;i++) tmp[i]=monthlyprec[i][imonth]/yts; 658 663 switch(this->ObjectEnum()){ 659 664 case TriaEnum: NewPrecipitationInput->AddTimeInput(new TriaInput(SurfaceforcingsPrecipitationEnum,&tmp[0],P1Enum),time_yr+imonth/12.*yts); break; … … 714 719 input->GetInputValue(&TemperaturesPresentday[iv][month],gauss,month/12.*yts); 715 720 input2->GetInputValue(&PrecipitationsPresentday[iv][month],gauss,month/12.*yts); 721 722 PrecipitationsPresentday[iv][month]=PrecipitationsPresentday[iv][month]*yts; 716 723 } 717 724 } … … 738 745 default: _error_("Not implemented yet"); 739 746 } 740 for(i=0;i<numvertices;i++) tmp[i]=monthlyprec[i][imonth] ;747 for(i=0;i<numvertices;i++) tmp[i]=monthlyprec[i][imonth]/yts; 741 748 switch(this->ObjectEnum()){ 742 749 case TriaEnum: NewPrecipitationInput->AddTimeInput(new TriaInput(SurfaceforcingsPrecipitationEnum,&tmp[0],P1Enum),time_yr+imonth/12.*yts); break; … … 1687 1694 monthlytemperatures[iv][month]=monthlytemperatures[iv][month]-273.15; // conversion from Kelvin to celcius for PDD module 1688 1695 input2->GetInputValue(&monthlyprec[iv][month],gauss,time_yr+month/12.*yts); 1696 monthlyprec[iv][month]=monthlyprec[iv][month]*yts; 1689 1697 } 1690 1698 } -
issm/trunk-jpl/src/m/classes/SMBd18opdd.m
r19263 r19264 107 107 108 108 if self.isd18opd 109 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1 );110 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1 );111 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype', 3,'timeserieslength',2);109 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1); 110 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1); 111 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype',1,'timeserieslength',2); 112 112 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','dpermil','format','Double'); 113 113 end -
issm/trunk-jpl/src/m/classes/SMBd18opdd.py
r19263 r19264 111 111 112 112 if self.isd18opd: 113 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1 )114 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1 )113 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1) 114 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1) 115 115 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype',1,'timeserieslength',2) 116 116 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','dpermil','format','DoubleMat','mattype',1) -
issm/trunk-jpl/src/m/classes/SMBpdd.m
r19263 r19264 108 108 fielddisplay(self,'rlaps','present day lapse rate [degree/km]'); 109 109 fielddisplay(self,'rlapslgm','LGM lapse rate [degree/km]'); 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 110 if(self.isdelta18o==0 & self.ismungsm==0) 111 fielddisplay(self,'monthlytemperatures',['monthly surface temperatures [K], required if pdd is activated and delta18o not activated']); 112 fielddisplay(self,'precipitation',['monthly surface precipitation [m/yr water eq], required if pdd is activated and delta18o or mungsm not activated']); 113 elseif(self.isdelta18o==1) 114 fielddisplay(self,'delta18o','delta18o [per mil], required if pdd is activated and delta18o activated'); 115 fielddisplay(self,'delta18o_surface','surface elevation of the delta18o site, required if pdd is activated and delta18o activated'); 116 fielddisplay(self,'temperatures_presentday','monthly present day surface temperatures [K], required if delta18o/mungsm is activated'); 117 fielddisplay(self,'temperatures_lgm','monthly LGM surface temperatures [K], required if delta18o or mungsm is activated'); 118 fielddisplay(self,'precipitations_presentday','monthly surface precipitation [m/yr water eq], required if delta18o/mungsm is activated'); 119 fielddisplay(self,'precipitations_lgm','monthly surface precipitation [m/yr water eq], required if delta18o/mungsm is activated'); 120 fielddisplay(self,'Tdiff','time interpolation parameter for temperature, 1D(year), required if mungsm is activated'); 121 fielddisplay(self,'sealev','sea level [m], 1D(year), required if mungsm is activated'); 122 elseif(self.ismungsm==1) 123 fielddisplay(self,'temperatures_presentday','monthly present day surface temperatures [K], required if delta18o/mungsm is activated'); 124 fielddisplay(self,'temperatures_lgm','monthly LGM surface temperatures [K], required if delta18o or mungsm is activated'); 125 fielddisplay(self,'precipitations_presentday','monthly surface precipitation [m/yr water eq], required if delta18o/mungsm is activated'); 126 fielddisplay(self,'precipitations_lgm','monthly surface precipitation [m/yr water eq], required if delta18o/mungsm is activated'); 127 fielddisplay(self,'Pfac','time interpolation parameter for precipitation, 1D(year), required if mungsm is activated'); 128 fielddisplay(self,'Tdiff','time interpolation parameter for temperature, 1D(year), required if mungsm is activated'); 129 fielddisplay(self,'sealev','sea level [m], 1D(year), required if mungsm is activated'); 130 end 131 131 end % }}} 132 132 function marshall(self,md,fid) % {{{ … … 149 149 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitation','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1); 150 150 elseif self.isdelta18o 151 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1 );152 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1 );153 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1 );154 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1 );155 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o_surface','format','DoubleMat','mattype',1 );156 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype',1 );151 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1); 152 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1); 153 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1); 154 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1); 155 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o_surface','format','DoubleMat','mattype',1,'timeserieslength',2); 156 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype',1,'timeserieslength',2); 157 157 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','Tdiff','format','DoubleMat','mattype',1,'timeserieslength',2); 158 158 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','sealev','format','DoubleMat','mattype',1,'timeserieslength',2); 159 159 elseif self.ismungsm 160 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1 );161 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1 );162 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1 );163 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1 );160 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1); 161 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1); 162 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1); 163 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1); 164 164 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','Pfac','format','DoubleMat','mattype',1,'timeserieslength',2); 165 165 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','Tdiff','format','DoubleMat','mattype',1,'timeserieslength',2); -
issm/trunk-jpl/src/m/classes/SMBpdd.py
r19263 r19264 152 152 153 153 if (self.isdelta18o==0 and self.ismungsm==0): 154 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','monthlytemperatures','format','DoubleMat','mattype',1 )154 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','monthlytemperatures','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1) 155 155 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitation','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1) 156 156 elif self.isdelta18o: 157 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1 )158 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1 )159 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1 )160 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1 )161 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o_surface','format','DoubleMat','mattype',1 )162 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype',1 )157 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1) 158 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1) 159 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1) 160 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1) 161 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o_surface','format','DoubleMat','mattype',1,'timeserieslength',2) 162 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','delta18o','format','DoubleMat','mattype',1,'timeserieslength',2) 163 163 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','Tdiff','format','DoubleMat','mattype',1,'timeserieslength',2) 164 164 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','sealev','format','DoubleMat','mattype',1,'timeserieslength',2) 165 165 elif self.ismungsm: 166 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1 )167 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1 )168 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1 )169 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1 )166 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_presentday','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1) 167 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','temperatures_lgm','format','DoubleMat','mattype',1,'timeserieslength',md.mesh.numberofvertices+1) 168 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_presentday','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1) 169 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','precipitations_lgm','format','DoubleMat','mattype',1,'scale',1./yts,'timeserieslength',md.mesh.numberofvertices+1) 170 170 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','Pfac','format','DoubleMat','mattype',1,'timeserieslength',2) 171 171 WriteData(fid,'object',self,'class','surfaceforcings','fieldname','Tdiff','format','DoubleMat','mattype',1,'timeserieslength',2)
Note:
See TracChangeset
for help on using the changeset viewer.