1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<!--Converted with LaTeX2HTML 99.2beta8 (1.46)
original version by: Nikos Drakos, CBLU, University of Leeds
* revised and updated by: Marcus Hennecke, Ross Moore, Herb Swan
* with significant contributions from:
Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
<HTML>
<HEAD>
<TITLE>B.2.3 Boundary Conditions for operations on grids</TITLE>
<META NAME="description" CONTENT="B.2.3 Boundary Conditions for operations on grids">
<META NAME="keywords" CONTENT="GMT_Docs">
<META NAME="resource-type" CONTENT="document">
<META NAME="distribution" CONTENT="global">
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="LaTeX2HTML v99.2beta8">
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
<LINK REL="STYLESHEET" HREF="GMT_Docs.css">
<LINK REL="previous" HREF="node115.html">
<LINK REL="up" HREF="node113.html">
<LINK REL="next" HREF="node119.html">
</HEAD>
<BODY bgcolor="#ffffff">
<!--Navigation Panel-->
<A NAME="tex2html2704"
HREF="node119.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.gif"></A>
<A NAME="tex2html2698"
HREF="node113.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.gif"></A>
<A NAME="tex2html2694"
HREF="node117.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.gif"></A>
<A NAME="tex2html2700"
HREF="node1.html">
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.gif"></A>
<A NAME="tex2html2702"
HREF="node149.html">
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" SRC="index.gif"></A>
<BR>
<B> Next:</B> <A NAME="tex2html2705"
HREF="node119.html">B.3 Sun raster files</A>
<B> Up:</B> <A NAME="tex2html2699"
HREF="node113.html">B.2 2-D grdfiles</A>
<B> Previous:</B> <A NAME="tex2html2695"
HREF="node117.html">B.2.2.2 Pixel registration</A>
  <B> <A NAME="tex2html2701"
HREF="node1.html">Contents</A></B>
  <B> <A NAME="tex2html2703"
HREF="node149.html">Index</A></B>
<BR>
<BR>
<!--End of Navigation Panel-->
<H2><A NAME="SECTION001723000000000000000"></A>
<A NAME="13297"></A>
<BR>
B.2.3 Boundary Conditions for operations on grids
</H2>
<P>
<A NAME="tex2html588"
HREF="http://www.soest.hawaii.edu/gmt"><B>GMT</B></A> has the option to specify boundary conditions in some programs
that operate on grids (<A NAME="tex2html589"
HREF="../grdsample.html"><I><B>grdsample</B></I></A><A NAME="13537"></A> <B>-L</B>; <A NAME="tex2html590"
HREF="../grdgradient.html"><I><B>grdgradient</B></I></A><A NAME="13547"></A>
<B>-L</B>; <A NAME="tex2html591"
HREF="../grdtrack.html"><I><B>grdtrack</B></I></A><A NAME="13557"></A> <B>-L</B>; <A NAME="tex2html592"
HREF="../nearneighbor.html"><I><B>nearneighbor</B></I></A><A NAME="13567"></A> <B>-L</B>;
<A NAME="tex2html593"
HREF="../grdview.html"><I><B>grdview</B></I></A><A NAME="13577"></A> <B>-L</B>). The boundary conditions come into play
when interpolating or computing derivatives near the limits of the
region covered by the grid. The <I>default</I> boundary
conditions used are those which are ``natural'' for the boundary
of a minimum curvature interpolating surface.
If the user knows that the data are periodic in <I>x</I> (and/or
<I>y</I>), or that the data cover a sphere with <I>x</I>,<I>y</I>
representing <I>longitude</I>,<I>latitude</I>, then there are better
choices for the boundary conditions.
Periodic conditions on <I>x</I> (and/or <I>y</I>) are chosen by
specifying <I>x</I> (and/or <I>y</I>) as the boundary condition flags;
global spherical cases are specified using the <I>g</I> (geographical)
flag. Behavior of these conditions is as follows:
<P>
<DL>
<DD><A NAME="13321"></A>
<P>
</DD>
<DT><STRONG>Periodic</STRONG></DT>
<DD>conditions on <I>x</I> indicate that the data are
periodic in the distance (<!-- MATH
$x_{max} - x_{min}$
-->
<IMG
WIDTH="74" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img149.gif"
ALT="$x_{max} - x_{min}$">) and thus repeat
values after every <!-- MATH
$N = (x_{max} - x_{min})/x_{inc}$
-->
<IMG
WIDTH="147" HEIGHT="31" ALIGN="MIDDLE" BORDER="0"
SRC="img150.gif"
ALT="$N = (x_{max} - x_{min})/x_{inc}$">. Note that
this implies that in a grid-registered file the values in the first
and last columns are equal, since these are located at <IMG
WIDTH="56" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img138.gif"
ALT="$x = x_{min}$">
and <IMG
WIDTH="58" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img139.gif"
ALT="$x = x_{max}$">, and there are <I>N</I> + 1 columns in the file.
This is not the case in a pixel-registered file, where there are only
<I>N</I> and the first and last columns are located at
<!-- MATH
$x_{min} + x_{inc}/2$
-->
<IMG
WIDTH="85" HEIGHT="31" ALIGN="MIDDLE" BORDER="0"
SRC="img151.gif"
ALT="$x_{min} + x_{inc}/2$"> and <!-- MATH
$x_{max} - x_{inc}/2$
-->
<IMG
WIDTH="87" HEIGHT="31" ALIGN="MIDDLE" BORDER="0"
SRC="img152.gif"
ALT="$x_{max} - x_{inc}/2$">. If <I>y</I> is
periodic all the same holds for <I>y</I>.
<P>
</DD>
<DT><STRONG>Geographical</STRONG></DT>
<DD>conditions indicate the following:
<A NAME="13338"></A>
<P>
<OL>
<LI>If <!-- MATH
$(x_{max} - x_{min}) \geq 360$
-->
<IMG
WIDTH="130" HEIGHT="31" ALIGN="MIDDLE" BORDER="0"
SRC="img153.gif"
ALT="$(x_{max} - x_{min}) \geq 360$"> and also 180 modulo <IMG
WIDTH="54" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img154.gif"
ALT="$x_{inc} = 0$">
then a periodic condition is used on <I>x</I> with a period of 360;
else a default condition is used on the <I>x</I> boundaries.
<P>
</LI>
<LI>If condition 1 is true and also <IMG
WIDTH="67" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img155.gif"
ALT="$y_{max} = 90$"> then a
``north pole condition'' is used at <IMG
WIDTH="32" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img156.gif"
ALT="$y_{max}$">, else a default
condition is used there.
<P>
</LI>
<LI>If condition 1 is true and also <IMG
WIDTH="77" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img157.gif"
ALT="$y_{min} = -90$"> then a
``south pole condition'' is used at <IMG
WIDTH="30" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img158.gif"
ALT="$y_{min}$">, else a default
condition is used there.
<P>
</LI>
</OL>
<P>
``Pole conditions'' use a 180<IMG
WIDTH="11" HEIGHT="15" ALIGN="BOTTOM" BORDER="0"
SRC="img61.gif"
ALT="$^{o}$"> phase-shift of the data,
requiring 180 modulo <IMG
WIDTH="54" HEIGHT="29" ALIGN="MIDDLE" BORDER="0"
SRC="img154.gif"
ALT="$x_{inc} = 0$">.
<P>
</DD>
<DT><STRONG>Default</STRONG></DT>
<DD>boundary conditions are
<A NAME="13351"></A>
<P>
<BR><P></P>
<DIV ALIGN="CENTER">
<!-- MATH
\begin{displaymath}
\nabla^2 f = \frac{\partial}{\partial n} \nabla^2 f = 0
\end{displaymath}
-->
<IMG
WIDTH="120" HEIGHT="40" BORDER="0"
SRC="img159.gif"
ALT="\begin{displaymath}\nabla^2 f = \frac{\partial}{\partial n} \nabla^2 f = 0 \end{displaymath}">
</DIV>
<BR CLEAR="ALL">
<P></P>
<P>
on the boundary, where <IMG
WIDTH="46" HEIGHT="31" ALIGN="MIDDLE" BORDER="0"
SRC="img160.gif"
ALT="$f(x, y)$"> is represented by the values in
the grid file, and <!-- MATH
$\partial/\partial n$
-->
<IMG
WIDTH="36" HEIGHT="31" ALIGN="MIDDLE" BORDER="0"
SRC="img161.gif"
ALT="$\partial/\partial n$"> is the derivative in the direction normal to a
boundary, and
<P>
<BR><P></P>
<DIV ALIGN="CENTER">
<!-- MATH
\begin{displaymath}
\nabla^2 = \left(\frac{\partial^2}{\partial x^2} + \frac{\partial^2}{\partial y^2}\right)
\end{displaymath}
-->
<IMG
WIDTH="125" HEIGHT="46" BORDER="0"
SRC="img162.gif"
ALT="\begin{displaymath}\nabla^2 = \left(\frac{\partial^2}{\partial x^2} + \frac{\partial^2}{\partial y^2}\right) \end{displaymath}">
</DIV>
<BR CLEAR="ALL">
<P></P>
<P>
is the two-dimensional Laplacian operator.
<P>
</DD>
</DL>
<A NAME="13359"></A>
<P>
<HR>
<!--Navigation Panel-->
<A NAME="tex2html2704"
HREF="node119.html">
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.gif"></A>
<A NAME="tex2html2698"
HREF="node113.html">
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.gif"></A>
<A NAME="tex2html2694"
HREF="node117.html">
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.gif"></A>
<A NAME="tex2html2700"
HREF="node1.html">
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.gif"></A>
<A NAME="tex2html2702"
HREF="node149.html">
<IMG WIDTH="43" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="index" SRC="index.gif"></A>
<BR>
<B> Next:</B> <A NAME="tex2html2705"
HREF="node119.html">B.3 Sun raster files</A>
<B> Up:</B> <A NAME="tex2html2699"
HREF="node113.html">B.2 2-D grdfiles</A>
<B> Previous:</B> <A NAME="tex2html2695"
HREF="node117.html">B.2.2.2 Pixel registration</A>
  <B> <A NAME="tex2html2701"
HREF="node1.html">Contents</A></B>
  <B> <A NAME="tex2html2703"
HREF="node149.html">Index</A></B>
<!--End of Navigation Panel-->
<ADDRESS>
Paul Wessel
2001-04-18
</ADDRESS>
</BODY>
</HTML>
|