0 evaluări0% au considerat acest document util (0 voturi)
27 vizualizări33 pagini
This document provides an overview of using LaTeX with Miktex 2.9. It discusses LaTeX document structure including document classes, packages, and basic formatting. It also covers topics like formatting text, sections, lists, math expressions, tables, matrices, and images. Examples are provided throughout to demonstrate different LaTeX commands.
This document provides an overview of using LaTeX with Miktex 2.9. It discusses LaTeX document structure including document classes, packages, and basic formatting. It also covers topics like formatting text, sections, lists, math expressions, tables, matrices, and images. Examples are provided throughout to demonstrate different LaTeX commands.
This document provides an overview of using LaTeX with Miktex 2.9. It discusses LaTeX document structure including document classes, packages, and basic formatting. It also covers topics like formatting text, sections, lists, math expressions, tables, matrices, and images. Examples are provided throughout to demonstrate different LaTeX commands.
By -Vijay Yadav Basics Document Class \documentclass[options]{class} options = a4paper, 11pt, 12pt, 10pt, twocolumn, landscape,... class = article, report, book,... Packages \usepackage{package name} epsfig = insert PS pictures into the document fancyhdr = easy definition of footer and header Basic Format Article \documentclass[12pt]{article} Basic Format Report \documentclass[a4paper,twoside,10pt]{report}
Basic Format Book \documentclass{book}
Body of Text Start with \begin{document} End with \end{document} Typesetting Text \\ or \newline and \newpage Bold \textbf{} or \bf Emphasise \emph{} Italic \textit{} or \it{..} Underline \underline{} or \ul
Body of Text contd..(examples) Example output:
Following are examples of \textbf{Bold} \emph{Emphsise} \textit{Italic} \underline{Underline} Output Try these:- Format Sections \chapter{} - To be used with book and report document classes Eg \chapter{Latex} \section{} 1.1,1.2 ,.. Eg \section{Introduction} \subsection{} 1.1.1,1.1.2,.. Eg \subsection{Latex is good} \subsubsection{} 1.1.1.1,. Eg \subsubsection{Its a way of representing document} \appendix - changes numbering scheme
output Titles, Authors and others \title{} \author{}
Eg:- \title{These is TITLE} \author{Here is the Author's name}
Format Contd. Output Paragraph and footnote \paragraph{} \footnote{} Eg:- \paragraph{These is paragraph1} \par{These is paragraph2} \footnote{These is FOOTER}
Output Format Contd. Labels \label{marker} - Marker in document. \pageref{marker} - Displays page no. of marker. \ref{marker} - Displays section location of marker. Itemize Use either enumerate, itemize or description.
Lists Itemize Source \begin{itemize} \item Apple \item Orange \end{itemize} Result Apple Orange
Output Lists contd.. Enumerate Source \begin{enumerate} \item Apple \item Orange \end{enumerate} Result 1. Apple 2. Orange Output Lists contd..(example) Try these: Alignment Environments center, flushleft, flushright Example \begin{flushright} Right aligned \end{flushright} Result Right aligned
Maths in LaTeX Use of \(\) Example: I=\(\int_{0}^{1}\(\int_{0}^{x^{2}} e^{y/x} \,dy \,dx \)
Output Maths in LaTeX Use of \[\] Example: I=\[\int_{0}^{1}\(\int_{0}^{x^{2}} e^{y/x} \,dy \,dx \]
Output Symbols There are a great deal of examples such as Greek letters, set and relations symbols, arrows, binary operators, etc. Example:
\forall x \in X, \quad \exists y \leq \epsilon Greek Symbol Greek letters are commonly used in mathematics Example:
\alpha, A, \beta, B, \gamma, \Gamma, \pi, \Pi, \phi, \varphi, \Phi Subscript and Superscript Subscript Underscore(_) is used for Subscript. For Example
Superscript caret (^) is used for Superscript. For Example
Code: x_{1} \\ a_{x} \\ Code: x^{2} \\ a^{x} \\ Operators An operator is a function that is written as a word: e.g. trigonometric functions (sin, cos, tan), logarithms and exponentials (log, exp). LaTeX has many of these defined as commands: For Example: 1. \cos (2\theta) = \cos^2 \theta - \sin^2 \theta
2. \[\lim_{x \to \infty} \exp(-x) = 0 \]
Try these Fraction \frac{1}{2} \frac{x}{y} \frac{\,dy}{\,dx} o/p:
Try these: Output
Integration Integral without limits
\int x \,dx Integral with limits
\int_{a}^{b} x \,dx Double Integration
\iint \limits_{R} x \,dx Triple Integration
\iiint \limits_{V} x \,dx Try these:
Equations in LaTeX \begin{equation} \label{eq:someequation} 5^2 - 5 = 20 \end{equation} this references the equation \ref{eq:someequation} Tables in LaTeX Columns \begin{tabular}{|||} \end{tabular} Rows & - Split text into columns \\ - End a row \hline - Draw line under row e.g. 123123 & 34.00\\ \hline
Two Columns l = automatically adjust size, left justify r = automatically adjust size, right justify p = set size e.g. p{4.7cm} c = Centre text Example of Table Name Roll No. Branch Student1 1 Comps Student2 2 I.T \begin{tabular}{|l|r|c|} \hline Name & Roll No. & Branch \\ \hline Student1 & 1 & Comps \\ \hline Student2 & 2 & I.T \\ \hline \end{tabular}
Tables Example \begin{tabular}{|c|c|} \hline \(x\) & p \\ \hline \(x_{0}\) & 0 \\ \hline \(x_{n}\) & n \\ \hline \end{tabular} Matrix \[ \begin{pmatrix} a & b \\ c & d \end{pmatrix} \quad \begin{bmatrix} a & b \\ c & d \end{bmatrix} \quad \begin{vmatrix} a & b \\ c & d \end{vmatrix} \] Matrix Example \[ \begin{bmatrix} \(x_{1}\) & \(x_{2}\) \\ \(y_{1}\) & \(y_{2}\) \end{bmatrix} =\quad \begin{bmatrix} \(a\sin \theta\) & \(a\cos \theta\) \\ \(b\cos\theta\) & \(b\sin \theta\) \end{bmatrix} \] Images in LaTeX \begin{figure} \begin{center}\includegraphics [scale=1]{block.pdf} \end{center} \caption{block dig} \end{figure}