From b172da95caf9f39829d69b2c45ac17bb8e9aa0de Mon Sep 17 00:00:00 2001 From: Gerardo Marx Date: Mon, 15 Feb 2021 11:43:05 -0600 Subject: [PATCH] day 3 --- 3_equ-tab-figs/1_equations/main.tex | 38 +++++++++++++++++++++++++++++ 3_equ-tab-figs/2_figures/main.tex | 15 ++++++++++++ 2 files changed, 53 insertions(+) create mode 100644 3_equ-tab-figs/1_equations/main.tex create mode 100644 3_equ-tab-figs/2_figures/main.tex diff --git a/3_equ-tab-figs/1_equations/main.tex b/3_equ-tab-figs/1_equations/main.tex new file mode 100644 index 0000000..50b8799 --- /dev/null +++ b/3_equ-tab-figs/1_equations/main.tex @@ -0,0 +1,38 @@ +\documentclass{article} +\usepackage[utf8]{inputenc} +\usepackage[english]{babel} +\usepackage{amssymb,amsmath} + +\begin{document} +\section{Simple equations on text} +\label{sec:eq-text} + +Here you can see simple equations along with text $x$, $y$ and \(z\) are in math mode. This mode is known as \textbf{inline} mode and it is recommended to write short equations like: $-10 \leq x \leq 10$. Thus, if complex and long equations are required, it is recommended to use the equation environment.\par + +\section{Equation environment} +\label{sec:environment} + +Here we can find a way to write long equations like \eqref{eq:fraction}: +\begin{equation} + \label{eq:fraction} + f(t)=\sqrt{\frac{t-a}{t+a}} +\end{equation} +\noindent here $t$ is time in seconds. + +More complex equations can be written using symbols and commands from math-mode. An example is the Fourier coefficients equations \eqref{eq:a0},\eqref{eq:an} and \eqref{eq:bn}: +\begin{eqnarray} + a_0=\frac{1}{T}\int_0^T f(t)dt \label{eq:a0}\\ + a_n=\frac{2}{T}\int_0^T f(t)\cdot \cos{\left(\frac{2\pi nt}{T}\right)}dt \label{eq:an}\\ + b_n=\frac{2}{T}\int_0^T f(t)\cdot \sin{\left(\frac{2\pi nt}{T}\right)}dt \label{eq:bn} +\end{eqnarray} + +Previous equations are used to define the Fourier series as: +\begin{equation} + \label{eq:fourier} + g(t)=a_0+\sum_{m=1}^{\infty}a_m \cos{\left(\frac{2\pi mt}{T}\right)}++\sum_{m=1}^{\infty}b_n \sin{\left(\frac{2\pi nt}{T}\right)} +\end{equation} +\end{document} + + + + diff --git a/3_equ-tab-figs/2_figures/main.tex b/3_equ-tab-figs/2_figures/main.tex new file mode 100644 index 0000000..51a2f4e --- /dev/null +++ b/3_equ-tab-figs/2_figures/main.tex @@ -0,0 +1,15 @@ +\documentclass{article} +\usepackage{amsmath} +\usepackage{graphicx} +\begin{document} +\section{Simple figures} +\label{sec:simple} + +This is a simple figure; see \figurename{} \ref{fig:fig-example}. +\begin{figure}[!htb] + \centering + \includegraphics[width=3.5in]{example-image-a} + \caption{Figure's caption.} + \label{fig:fig-example} +\end{figure} +\end{document} \ No newline at end of file