Changeset 123


Ignore:
Timestamp:
Nov 18, 2010, 10:52:50 PM (13 years ago)
Author:
gostiaux
Message:

Code reading and cleaning
Check that the help is OK especially for the output, there must be some update to do; see this with Joel

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/calc_field.m

    r89 r123  
    11%'calc_field': defines fields (velocity, vort, div...) from civx data and calculate them 
    22%---------------------------------------------------------------------
     3% [DataOut,errormsg]=calc_field(FieldName,DataIn)
    34%
    45% OUTPUT:
    56% Scal: matlab vector representing the scalar values (length nbvec defined by var_read) 
    6 %      if no input , Scal=list of programmed scalar names (to put in menus)
    7 %      if only the sclar name is put as input, vec_A=type of scalar, which can be:
     7%      if no input, Scal=list of programmed scalar names (to put in menus)
     8%      if only the field name is put as input, vec_A=type of scalar, which can be:
     9%                   'discrete': related to the individual velocity vectors, not interpolated by patch
    810%                   'vel': scalar calculated solely from velocity components
    911%                   'der': needs spatial derivatives     
     
    1416%
    1517% INPUT:
    16 % ScalName: string representing the name of the scalar
     18% FieldName: string representing the name of the field
    1719% DataIn: structure representing the field, as defined in check_field_srtructure.m
    1820%
     
    2931%              'var': the scalar name corresponds to a field name in the netcdf files
    3032% a specific variable name for civ1 and civ2 fields are also associated, if
    31 % '' the scalar is calculated from other fields, as explicited below
     33% the scalar is calculated from other fields, as explicited below
     34
    3235%list_scal={title, type, civ1 var name,civ2 var name}
    3336list_field={'velocity';...%image correlation corresponding to a vel vector
    34             'ima_cor';...%image correlation corresponding to a vel vector
     37           'ima_cor';...%image correlation corresponding to a vel vector
    3538           'norm_vel';...%norm of the velocity
    3639           'vort';...%vorticity
     
    5760        nbcoord=2;
    5861    end   
    59     DataOut=DataIn; %reporduce global attribute
     62    DataOut=DataIn; %reproduce global attribute
    6063    ListVarName={};
    6164    ValueList={};
     
    6871        RoleList=[RoleList Role];
    6972        units_cell=[units_cell units];
    70     end   
     73   end   
    7174       %erase previous data (except coordinates)
    7275    for ivar=nbcoord+1:length(DataOut.ListVarName)
Note: See TracChangeset for help on using the changeset viewer.