Changeset 6860
- Timestamp:
- 12/30/10 07:40:15 (14 years ago)
- Location:
- issm/trunk/src/m
- Files:
-
- 1 deleted
- 16 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/m/model/modeldefault/modeldefault_process.m
r6088 r6860 6 6 7 7 %retrieve some paths 8 global ISSM_DIR 9 modeldatapath=[ISSM_DIR '/projects/ModelData']; 8 modeldatapath=[issmdir() '/projects/ModelData']; 10 9 11 10 %initialize output -
issm/trunk/src/m/model/modis.m
r6088 r6860 5 5 % [xm,ym,modis]=modis(modisgeotif,xlim,ylim) 6 6 % 7 8 global ISSM_TIER9 7 10 8 %find gdal coordinates … … 16 14 17 15 %Get path to gdal binaries 18 path_gdal=[ ISSM_TIER'/externalpackages/gdal/install/bin/'];16 path_gdal=[issmtier() '/externalpackages/gdal/install/bin/']; 19 17 20 18 %Was gdal compiled? 21 19 if ~exist([path_gdal 'gdal_translate']), 22 error(['modis error message: GDAL library needs to be compiled to use this routine. Compile GDAL in ' ISSM_TIER'/externalpackages/gdal to use this routine.']);20 error(['modis error message: GDAL library needs to be compiled to use this routine. Compile GDAL in ' issmtier() '/externalpackages/gdal to use this routine.']); 23 21 end 24 22 -
issm/trunk/src/m/model/multiplequeue/BuildMultipleQueueingScriptGeneric.m
r6088 r6860 5 5 % BuildMultipleQueueingScriptGeneric(executionpath,codepath) 6 6 7 global ISSM_TIER8 9 10 7 %not done yet 11 8 error('BuildMultipleQueueingScriptGenericerror message: not supported yet!'); -
issm/trunk/src/m/model/petscversion.m
r6854 r6860 1 function version=petscversion(issm_tier) 2 %PETSCVERSION: recover petsc version number, inside config.h file 1 function PETSC_VERSION=petscversion() 2 %PETSCVERSION - recover petsc version number, inside config.h file 3 % 4 % Usage: 5 % PETSC_VERSION=petscversion(); 3 6 4 7 5 fid=fopen([issm_tier '/config.h'],'r'); 8 configfile=[issmtier() '/config.h']; 9 if ~exist(configfile,'file'), 10 error(['File ' configfile ' not found. ISSM has not been configured yet!']); 11 end 6 12 7 13 %go through the file, and recover the line we want 14 fid=fopen(configfile,'r'); 8 15 while(1), 9 16 tline=fgets(fid); … … 11 18 if length(tline)>=25, 12 19 if strcmpi(tline(1:23),'#define _PETSC_VERSION_'), 13 version=str2num(tline(25));20 PETSC_VERSION=str2num(tline(25)); 14 21 end 15 22 end -
issm/trunk/src/m/model/plot/applyoptions.m
r6759 r6860 6 6 % 7 7 % See also: PLOTMODEL, PARSE_OPTIONS 8 9 global ISSM_DIR10 8 11 9 %fontsize … … 340 338 %box off 341 339 if strcmpi(md.hemisphere,'n') | strcmpi(md.hemisphere,'north'), 342 A=expread([ ISSM_DIR'/projects/Exp/Greenland.exp']);340 A=expread([ issmdir() '/projects/Exp/Greenland.exp']); 343 341 elseif strcmpi(md.hemisphere,'s') | strcmpi(md.hemisphere,'south'), 344 A=expread([ ISSM_DIR'/projects/Exp/Antarctica.exp']);342 A=expread([ issmdir() '/projects/Exp/Antarctica.exp']); 345 343 else 346 344 error('applyoptions error message: hemisphere not defined'); -
issm/trunk/src/m/model/plot/plotmodel.m
r6497 r6860 1 1 function plotmodel(md,varargin) 2 2 %At command prompt, type plotdoc for help on documentation. 3 4 global ISSM_TIER5 if isempty(ISSM_TIER),6 error('ISSM_TIER variable got erased! This variable is needed to run Ice code correctly. Please rerun your startup file.');7 end8 3 9 4 %First process options -
issm/trunk/src/m/model/plot/showregion.m
r6367 r6860 1 1 function showregion(md,insetpos) 2 global ISSM_DIR 2 %SHOWREGION - show region on plot 3 % 4 % Usage: 5 % showregion(md,insetpos); 3 6 4 7 %get inset relative position (x,y,width,height) … … 13 16 %box off 14 17 if strcmpi(md.hemisphere,'n') | strcmpi(md.hemisphere,'north'), 15 A=expread([ ISSM_DIR'projects/Exp/Greenland.exp']);18 A=expread([issmdir() 'projects/Exp/Greenland.exp']); 16 19 elseif strcmpi(md.hemisphere,'s') | strcmpi(md.hemisphere,'south'), 17 A=expread([ ISSM_DIR'/projects/Exp/Antarctica.exp']);20 A=expread([issmdir() '/projects/Exp/Antarctica.exp']); 18 21 else 19 22 error('applyoptions error message: hemisphere not defined'); -
issm/trunk/src/m/model/radarpower.m
r6670 r6860 9 9 % md=radarpower(md,options); 10 10 % md=radarpower(md) 11 12 global ISSM_TIER13 global MODELDATA14 15 %if MODELDATA has not been initialized (ie: empty), use default path.16 if isempty(MODELDATA), MODELDATA='/u/astrid-r1b/larour/ModelData'; end17 11 18 12 %Parse inputs … … 32 26 if ~exist(options,'overlay_image'), 33 27 if strcmpi(md.hemisphere,'n'), 34 if ~exist([ MODELDATA '/MOG/mog150_greenland_map.jpg']),35 error(['radarpower error message: file ' MODELDATA '/MOG/mog150_greenland_map.jpg not found. Check MODELDATA variable..']);28 if ~exist([issmdir() '/projects/ModelData/MOG/mog150_greenland_map.jpg']), 29 error(['radarpower error message: file ' issmdir() '/projects/ModelData/MOG/mog150_greenland_map.jpg not found.']); 36 30 end 37 jpgim=[ MODELDATA '/MOG/mog150_greenland_map.jpg'];38 geom=load([ MODELDATA '/MOG/mog150_greenland_map.jpgw'],'ascii');31 jpgim=[issmdir() '/projects/ModelData/MOG/mog150_greenland_map.jpg']; 32 geom=load([issmdir() '/projects/ModelData/MOG/mog150_greenland_map.jpgw'],'ascii'); 39 33 sizex=floor((x1-x0)/geom(1)); % x posting 40 34 sizey=floor((y1-y0)/geom(4)); % y posting … … 52 46 elseif strcmpi(md.hemisphere,'s'), 53 47 if highres, 54 if ~exist([ MODELDATA '/MosaicTiffRsat/amm125m_v2_200m.tif']),55 error(['radarpower error message: file ' MODELDATA '/MosaicTiffRsat/amm125m_v2_200m.tif not found. Check MODELDATA variable..']);48 if ~exist([issmdir() '/projects/ModelData/MosaicTiffRsat/amm125m_v2_200m.tif']), 49 error(['radarpower error message: file ' issmdir() '/projects/ModelData/MosaicTiffRsat/amm125m_v2_200m.tif not found.']); 56 50 end 57 geotiff_name=[ MODELDATA '/MosaicTiffRsat/amm125m_v2_200m.tif'];51 geotiff_name=[issmdir() '/projects/ModelData/MosaicTiffRsat/amm125m_v2_200m.tif']; 58 52 else 59 if ~exist([ MODELDATA '/MosaicTiffRsat/amm125m_v2_1km.tif']),60 error(['radarpower error message: file ' MODELDATA '/MosaicTiffRsat/amm125m_v2_1km.tif not found. Check MODELDATA variable..']);53 if ~exist([issmdir() '/projects/ModelData/MosaicTiffRsat/amm125m_v2_1km.tif']), 54 error(['radarpower error message: file ' issmdir() '/projects/ModelData/MosaicTiffRsat/amm125m_v2_1km.tif not found.']); 61 55 end 62 geotiff_name=[ MODELDATA '/MosaicTiffRsat/amm125m_v2_1km.tif'];56 geotiff_name=[issmdir() '/projects/ModelData/MosaicTiffRsat/amm125m_v2_1km.tif']; 63 57 end 64 58 -
issm/trunk/src/m/model/solve.m
r6569 r6860 13 13 % md=solve(md,'analysis_type',ThermalSolutionEnum,'sub_analysis_type',SteadyAnalysisEnum); 14 14 % md=solve(md,'analysis_type','ThermalAnalysis'); 15 16 %some checks on list of arguments17 global ISSM_TIER18 15 19 16 %recover options -
issm/trunk/src/m/model/solvers/mumpsoptions.m
r6858 r6860 5 5 % options=mumpsoptions; 6 6 7 global PETSC_VERSION8 9 7 %retrieve options provided in varargin 10 8 arguments=pairoptions(varargin{:}); 11 9 12 10 %default mumps options 11 PETSC_VERSION=petscversion(); 13 12 if PETSC_VERSION==2, 14 13 options={{'mat_type','aijmumps'},{'ksp_type','preonly'},{'pc_type','lu'},{'mat_mumps_icntl_14',120},{'pc_factor_shift_positive_definite','true'}}; -
issm/trunk/src/m/qmu/postqmu.m
r6088 r6860 1 1 function md=postqmu(md) 2 3 2 %INPUT function md=postqmu(md,qmufile,qmudir) 4 3 %Deal with dakota output results in files. 5 6 global ISSM_TIER;7 4 8 5 % check to see if dakota returned errors in the err file -
issm/trunk/src/m/qmu/preqmu.m
r6615 r6860 18 18 % rundakota: (John?) 19 19 % runmpi: (John?) 20 21 global ISSM_TIER;22 20 23 21 disp('preprocessing dakota inputs'); -
issm/trunk/src/m/utils/DataProcessing/TracksToMatrix.m
r6088 r6860 20 20 % See also: CREATEDATABOUNDARIES, CREATEDATAMATRIX 21 21 22 global ISSM_TIER23 24 22 %some checks 25 23 if nargin~=8 & nargin~=11, … … 28 26 29 27 %Add path to dace 30 addpath([ ISSM_TIER'/externalpackages/dace/install'])28 addpath([issmtier() '/externalpackages/dace/install']) 31 29 32 30 %First create the x_m and y_m fot the matrix … … 84 82 85 83 %remove DACE path 86 rmpath([ ISSM_TIER'/externalpackages/dace/install']);84 rmpath([issmtier() '/externalpackages/dace/install']); -
issm/trunk/src/m/utils/Mesh/BamgCall.m
r6088 r6860 14 14 % Example: 15 15 % md=BamgCall(md,md.vel_obs,1500,10^8,1.3,0.9); 16 17 global ISSM_TIER18 16 19 17 %2d geometric parameter (do not change) -
issm/trunk/src/m/utils/Mesh/BamgCallFromMetric.m
r6088 r6860 10 10 % Example: 11 11 % md=BamgCall(md,metric,1500,10^8,1.3,0.9); 12 13 global ISSM_TIER14 12 15 13 %2d geometric parameter (do not change) -
issm/trunk/src/m/utils/Mesh/YamsCall.m
r6088 r6860 14 14 % Example: 15 15 % md=YamsCall(md,md.vel_obs,1500,10^8,1.3,0.9); 16 17 global ISSM_TIER18 16 19 17 %2d geometric parameter (do not change)
Note:
See TracChangeset
for help on using the changeset viewer.