%Gradients
%If you modify this file, please indicate here and in the footnote
%Math263D
\documentclass[12pt]{article}
\usepackage{times}
\pagestyle{empty}
\addtolength{\textwidth}{1.2in}
\addtolength{\textheight}{1.2in}
\addtolength{\oddsidemargin}{-.58in}
\addtolength{\evensidemargin}{-.58in}
\renewcommand{\baselinestretch}{1.0}
\parindent = 0cm
\parskip = .1cm
\begin{document}
\begin{center}
{\Large
Gradients
\footnote{Copyright \copyright 2002 Steve Chapin, and Todd Young.
All rights reserved. Please address comments to young@math.ohiou.edu.}}
\end{center}
\begin{enumerate}
\item Enter the following commands:\\
\verb& [X, Y] = meshgrid(-2:.2:2); & \\
\verb& Z = X.*exp(-X.^2 - Y.^2);&\\
\verb& mesh(X, Y, Z)&\\
Rotate this plot into various positions until you fully understand the shape.
\item Next enter the following:\\
\verb& [DX, DY] = gradient(Z);&\\
\verb& contour(X,Y,Z) &\\
\verb& hold on&\\
\verb& quiver(X,Y,DX,DY)&\\
\verb& hold off&
\item Repeat the above steps for the functions:
$f(x, y) = exp(-x^2 - y^2)$ and $f(x, y) = x + y$.
\item What is the relationship between contour (level) curves and gradient vectors?
\item Write a brief report, using complete sentences and standard mathematical notation.
\end{enumerate}
\vfill
\noindent
\textsf{ The goal of this project is to familiarize the user
with the vector field plot capabilities of
the program and aid in the understanding of the meaning of the
gradient.}
\end{document}