1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" |
---|
2 | "http://www.w3.org/TR/REC-html40/loose.dtd"> |
---|
3 | <html> |
---|
4 | <head> |
---|
5 | <title>Description of read_scalar</title> |
---|
6 | <meta name="keywords" content="read_scalar"> |
---|
7 | <meta name="description" content="'read_scalar': reads and calculates the vort div or any scalar from a file"> |
---|
8 | <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> |
---|
9 | <meta name="generator" content="m2html © 2003 Guillaume Flandin"> |
---|
10 | <meta name="robots" content="index, follow"> |
---|
11 | <link type="text/css" rel="stylesheet" href="../../../../m2html.css"> |
---|
12 | </head> |
---|
13 | <body> |
---|
14 | <a name="_top"></a> |
---|
15 | <div><a href="../../../../index.html">Home</a> > <a href="#">coriolis</a> > <a href="#">bigone</a> > <a href="#">PROJETS</a> > <a href="#">UVMAT.new</a> > read_scalar.m</div> |
---|
16 | |
---|
17 | <!--<table width="100%"><tr><td align="left"><a href="../../../../index.html"><img alt="<" border="0" src="../../../../left.png"> Master index</a></td> |
---|
18 | <td align="right"><a href="index.html">Index for /coriolis/bigone/PROJETS/UVMAT.new <img alt=">" border="0" src="../../../../right.png"></a></td></tr></table>--> |
---|
19 | |
---|
20 | <h1>read_scalar |
---|
21 | </h1> |
---|
22 | |
---|
23 | <h2><a name="_name"></a>PURPOSE <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
24 | <div class="box"><strong>'read_scalar': reads and calculates the vort div or any scalar from a file</strong></div> |
---|
25 | |
---|
26 | <h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
27 | <div class="box"><strong>function [A,time,dt,rangx,rangy,vel_type_out,error,pixcmx,pixcmy]=read_scalar(filename,vel_type,scal_type,rgx_in,rgy_in,npxy_in,maskname,transform); </strong></div> |
---|
28 | |
---|
29 | <h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
30 | <div class="fragment"><pre class="comment">'read_scalar': reads and calculates the vort div or any scalar from a file |
---|
31 | % OBSOLETE: REPLACED BY read_ncfield |
---|
32 | ------------------------------------------------------------------ |
---|
33 | [A,time,dt,rangx,rangy,vel_type_out,error,pixcmx,pixcmy]=... |
---|
34 | read_scalar(filename,vel_type,scal_type,rgx_in,rgy_in,npxy_in,maskname,usrtransform); |
---|
35 | |
---|
36 | OUTPUT: |
---|
37 | A=double m x n matrix representing the scalar field on a regular mesh |
---|
38 | time: absolute time read in the file |
---|
39 | dt: time interval of the image pair (read in the file) |
---|
40 | rangx,rangy: length 2 vectors representing in each direction the coordinates of the first and |
---|
41 | last point of the field, thus describes the whole grid of scalar positions |
---|
42 | vel_type_out: string representing the type of velocity selected (filter2,filter1...) |
---|
43 | error: error flag = 0 when OK |
---|
44 | error=1: no spatial derivative in the filename;'run patch first'}) |
---|
45 | error=2: no field vel_type in filename |
---|
46 | error=3: scalar cannot be obtained |
---|
47 | error=4: all points aligned |
---|
48 | pixcmx,pixcmy: pixels per cm in the images (useful when using a mask) |
---|
49 | |
---|
50 | INPUT: |
---|
51 | filename: string representing the name of the input file |
---|
52 | vel_type: character string or cell (only vel_type{1} is used presently), indicates the types of velocity fields to read ('civ1','civ2'...) |
---|
53 | if vel_type{1}=[], the types are automaticaly set depending on scal_type |
---|
54 | scal_type: character string, indicates the types of scalar to get ('vort','div'...) |
---|
55 | rgx_in,rgy_in: like rangx, rangy but set as input: |
---|
56 | if 'rgx_in' not defined or rgx_in=[], it is set to min max of 'vec_X' in the field |
---|
57 | npxy_in: in general vector with two elements setting the number of grid points in each direction, |
---|
58 | in association with rgx_in,rgy_in, it sets the whole grid |
---|
59 | on which the scalar is linearly interpolated |
---|
60 | if rgx_in=[] and npxy_in='np>256' we interpolate the field to get a resolution > 256 pts |
---|
61 | maskname: name of a mask image file, the scalar is set to 'NaN' at masked points |
---|
62 | transform: names of a user defined transforms |
---|
63 | transform.scal: for the scalar |
---|
64 | transform.ima: for a geometric transform on mask images if a mask is used</pre></div> |
---|
65 | |
---|
66 | <!-- crossreference --> |
---|
67 | <h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
68 | This function calls: |
---|
69 | <ul style="list-style-image:url(../../../../matlabicon.gif)"> |
---|
70 | <li><a href="calc_scal.html" class="code" title="function [Scal]=calc_scal(ScalName,DataIn)">calc_scal</a> 'calc_scal': defines scalars and calculate them from stored fields. OBSOLETE to replace by calc_field</li><li><a href="griddata_uvmat.html" class="code" title="function ZI = griddata_uvmat(X,Y,Z,XI,YI)">griddata_uvmat</a> 'griddata_uvmat': function griddata_uvmat(vec2_X,vec2_Y,vec2_U,vec_X,vec_Y,'linear')</li><li><a href="read_netcdf.html" class="code" title="function [cte_detect,var_detect,cte_read,var_read,choice,cte2_detect,var2_detect,cte2_read,var2_read]=read_netcdf(filename,cte1,nb1,var1,cte2,nb2,var2,option)">read_netcdf</a> 'read_netcdf': reads a list of fields and constants in a netcdf file</li><li><a href="varname_generator.html" class="code" title="function [cte,nb,var,vel_type_out]=varname_generator(vel_type,display,scal_name,scal_2,scal_3)">varname_generator</a> 'varname_generator': defines the names of constants and variable fields to read in the netcdf files</li></ul> |
---|
71 | This function is called by: |
---|
72 | <ul style="list-style-image:url(../../../../matlabicon.gif)"> |
---|
73 | </ul> |
---|
74 | <!-- crossreference --> |
---|
75 | |
---|
76 | |
---|
77 | |
---|
78 | <hr><address>Generated on Tue 14-Apr-2009 22:21:41 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/">m2html</a></strong> © 2003</address> |
---|
79 | </body> |
---|
80 | </html> |
---|