Changeset 21942


Ignore:
Timestamp:
08/11/17 16:15:14 (8 years ago)
Author:
adhikari
Message:

CHG: further renaming of the txt files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/m/coordsystems/gmtmask.m

    r21941 r21942  
    3131        %First, write our lat,long file for gmt:
    3232        nv=length(lat);
    33         filename = ['all_vertices-' num2str(feature('GetPid')) '.txt']
    34         dlmwrite(filename,[long lat (1:nv)'],'delimiter','\t','precision',10);
    35 
     33        filename_all = ['all_vertices-' num2str(feature('GetPid')) '.txt'];
     34        filename_oce = ['oce_vertices-' num2str(feature('GetPid')) '.txt'];
     35        dlmwrite(filename_all,[long lat (1:nv)'],'delimiter','\t','precision',10);
    3636
    3737        %Avoid bypassing of the ld library path by Matlab (:()
     
    4242
    4343        %figure out which vertices are on the ocean, which one on the continent:
    44         [status,result] = system(['gmt gmtselect ./' filename ' -h0 -Df -R0/360/-90/90  -A0 -JQ180/200 -Nk/s/s/k/s > ./oce_vertices.txt']);
     44        [status,result] = system(['gmt gmtselect ./' filename_all ' -h0 -Df -R0/360/-90/90  -A0 -JQ180/200 -Nk/s/s/k/s > ./' filename_oce]);
    4545        if status~=0,
    4646                error(result);
     
    5252        end
    5353        %read the con_vertices.txt file and flag our mesh vertices on the continent
    54         fid=fopen('./oce_vertices.txt','r');
     54        fid=fopen(['./' filename_oce],'r');
    5555        line=fgets(fid);
    5656        line=fgets(fid);
     
    6666        mask(oce_vertices)=1;
    6767       
    68         system(['rm -rf ./' filename ' ./oce_vertices.txt ./gmt.history']);
     68        system(['rm -rf ./' filename_all ' ./' filename_oce ' ./gmt.history']);
    6969        if ~recursive, disp(sprintf('gmtmask: done')); end;
Note: See TracChangeset for help on using the changeset viewer.