# HG changeset patch # User Puneeth Chaganti # Date 1257408886 -19800 # Node ID ef9337f7048c2d39421691c67e0cdcc56ca0b7ee # Parent c378d1ffb1d14c09cdf4c6eed0b13ee8a41d23aa Added example for ones_like in session4. diff -r c378d1ffb1d1 -r ef9337f7048c day1/session4.tex --- a/day1/session4.tex Thu Nov 05 13:13:58 2009 +0530 +++ b/day1/session4.tex Thu Nov 05 13:44:46 2009 +0530 @@ -440,6 +440,22 @@ In []: A = array([L, ones_like(L)]) In []: A = A.T \end{lstlisting} +\begin{small} +\begin{block}{} + \begin{lstlisting} +In []: ones((3,5)) +Out[]: +array([[ 1., 1., 1., 1., 1.], + [ 1., 1., 1., 1., 1.], + [ 1., 1., 1., 1., 1.]]) + +In []: ones_like([1, 2, 3, 4, 5]) +Out[]: array([1, 1, 1, 1, 1]) + \end{lstlisting} +Also available \alert{\typ{zeros, zeros_like, empty, empty_like}} +\end{block} +\end{small} + %% \begin{itemize} %% \item A is also called a Van der Monde matrix %% \item It can also be generated using \typ{vander} @@ -489,11 +505,10 @@ \item Inverse of a matrix \item Determinant \item Eigenvalues and Eigen vector - \item Norms - \item Singular Value Decomposition + %% \item Norms + %% \item Singular Value Decomposition \end{itemize} \item Least Square Curve fitting - \item Solving linear equations \end{itemize} \end{frame}