\documentclass[10pt,a4paper]{article} % Packages \usepackage{fancyhdr} % For header and footer \usepackage{multicol} % Allows multicols in tables \usepackage{tabularx} % Intelligent column widths \usepackage{tabulary} % Used in header and footer \usepackage{hhline} % Border under tables \usepackage{graphicx} % For images \usepackage{xcolor} % For hex colours %\usepackage[utf8x]{inputenc} % For unicode character support \usepackage[T1]{fontenc} % Without this we get weird character replacements \usepackage{colortbl} % For coloured tables \usepackage{setspace} % For line height \usepackage{lastpage} % Needed for total page number \usepackage{seqsplit} % Splits long words. %\usepackage{opensans} % Can't make this work so far. Shame. Would be lovely. \usepackage[normalem]{ulem} % For underlining links % Most of the following are not required for the majority % of cheat sheets but are needed for some symbol support. \usepackage{amsmath} % Symbols \usepackage{MnSymbol} % Symbols \usepackage{wasysym} % Symbols %\usepackage[english,german,french,spanish,italian]{babel} % Languages % Document Info \author{kira} \pdfinfo{ /Title (linear-relationships.pdf) /Creator (Cheatography) /Author (kira) /Subject (Linear Relationships Cheat Sheet) } % Lengths and widths \addtolength{\textwidth}{6cm} \addtolength{\textheight}{-1cm} \addtolength{\hoffset}{-3cm} \addtolength{\voffset}{-2cm} \setlength{\tabcolsep}{0.2cm} % Space between columns \setlength{\headsep}{-12pt} % Reduce space between header and content \setlength{\headheight}{85pt} % If less, LaTeX automatically increases it \renewcommand{\footrulewidth}{0pt} % Remove footer line \renewcommand{\headrulewidth}{0pt} % Remove header line \renewcommand{\seqinsert}{\ifmmode\allowbreak\else\-\fi} % Hyphens in seqsplit % This two commands together give roughly % the right line height in the tables \renewcommand{\arraystretch}{1.3} \onehalfspacing % Commands \newcommand{\SetRowColor}[1]{\noalign{\gdef\RowColorName{#1}}\rowcolor{\RowColorName}} % Shortcut for row colour \newcommand{\mymulticolumn}[3]{\multicolumn{#1}{>{\columncolor{\RowColorName}}#2}{#3}} % For coloured multi-cols \newcolumntype{x}[1]{>{\raggedright}p{#1}} % New column types for ragged-right paragraph columns \newcommand{\tn}{\tabularnewline} % Required as custom column type in use % Font and Colours \definecolor{HeadBackground}{HTML}{333333} \definecolor{FootBackground}{HTML}{666666} \definecolor{TextColor}{HTML}{333333} \definecolor{DarkBackground}{HTML}{9E4ED4} \definecolor{LightBackground}{HTML}{F8F3FC} \renewcommand{\familydefault}{\sfdefault} \color{TextColor} % Header and Footer \pagestyle{fancy} \fancyhead{} % Set header to blank \fancyfoot{} % Set footer to blank \fancyhead[L]{ \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{C} \SetRowColor{DarkBackground} \vspace{-7pt} {\parbox{\dimexpr\textwidth-2\fboxsep\relax}{\noindent \hspace*{-6pt}\includegraphics[width=5.8cm]{/web/www.cheatography.com/public/images/cheatography_logo.pdf}} } \end{tabulary} \columnbreak \begin{tabulary}{11cm}{L} \vspace{-2pt}\large{\bf{\textcolor{DarkBackground}{\textrm{Linear Relationships Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{kira} via \textcolor{DarkBackground}{\uline{cheatography.com/46506/cs/13512/}}} \end{tabulary} \end{multicols}} \fancyfoot[L]{ \footnotesize \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{LL} \SetRowColor{FootBackground} \mymulticolumn{2}{p{5.377cm}}{\bf\textcolor{white}{Cheatographer}} \\ \vspace{-2pt}kira \\ \uline{cheatography.com/kira} \\ \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Published 12th November, 2017.\\ Updated 12th November, 2017.\\ Page {\thepage} of \pageref{LastPage}. \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Sponsor}} \\ \SetRowColor{white} \vspace{-5pt} %\includegraphics[width=48px,height=48px]{dave.jpeg} Measure your website readability!\\ www.readability-score.com \end{tabulary} \end{multicols}} \begin{document} \raggedright \raggedcolumns % Set font size to small. Switch to any value % from this page to resize cheat sheet text: % www.emerson.emory.edu/services/latex/latex_169.html \footnotesize % Small font. \begin{multicols*}{3} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Solving Problems Using Linear Equations}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{Worked Example 6:}} \newline % Row Count 1 (+ 1) Mira is twice Sanjin's age. How old are Mira and Sanjin now if in 10 years the sum of their ages will be 89. Use {\emph{s}} to represent Sanjin's age. \newline % Row Count 4 (+ 3) Sanjin's Age: s Mira's present age: 2s \newline % Row Count 5 (+ 1) In 10 years: \newline % Row Count 6 (+ 1) Sanjin = s + 10 Mira's age = 2s + 10 \newline % Row Count 7 (+ 1) (s+10) + (2s+10) = 89 \newline % Row Count 8 (+ 1) 3s + 20 = 89 \newline % Row Count 9 (+ 1) 3s = 69 \newline % Row Count 10 (+ 1) s = 23 \newline % Row Count 11 (+ 1) 2s = 2 x 23 = 46 \newline % Row Count 12 (+ 1) Sanjin is 23 years old and Mira is 46 years old. In 10 years they will be 33 and 56 old respectively; 33 + 56= 89% Row Count 15 (+ 3) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.4885 cm} x{2.4885 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{Distance and Midpoint}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{ Distance Formula}} & {\bf{Midpoint Formula}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} The distance, {\emph{d}}, between any two Cartesian coordinates (x1, y1) and (x2, y2) is: & The midpoint M(x,y) between 2 points (x1, y1) and (x2, y2) is given by: \tn % Row Count 7 (+ 5) % Row 2 \SetRowColor{LightBackground} d = & M(x,y) = \tn % Row Count 8 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Gradient}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{The gradient of a line can be found by the ratio of the vertical {\bf{rise}} to the horizontal {\bf{run}} between any two points on the line. \newline % Row Count 3 (+ 3) Gradient AB = (vertical rise)/(horizontal run) \newline % Row Count 4 (+ 1) The letter {\emph{m}} is used to represent the gradient. {\bf{y=mx+b}} \newline % Row Count 6 (+ 2) m = (rise)/(run) \newline % Row Count 7 (+ 1) = (change in {\emph{y}}-value)/(change in {\emph{x}}-value) \newline % Row Count 9 (+ 2) = (y2-y1)/(x2-x1)% Row Count 10 (+ 1) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Linear Graphs: Gradient and Y-Intercept}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{The {\bf{gradient-intercept form:}} \newline % Row Count 1 (+ 1) {\emph{y=mx+b}}, where {\emph{m}} is the gradient and {\emph{b}} is the y-intercept. \newline % Row Count 3 (+ 2) The {\bf{general form:}} \newline % Row Count 4 (+ 1) {\emph{ax+by+c=0}}, where {\emph{a}}, {\emph{b}} and {\emph{c}} are constants and {\emph{a}} ≠ 0, b ≠ 0. \newline % Row Count 6 (+ 2) In this equation, the gradient {\emph{m}} = (-a)/(b) and the y-intercept = (-c)/(b)can be found by rearranging the equation to make {\emph{y}} the subject. \newline % Row Count 9 (+ 3) {\bf{Worked Example 15}} \newline % Row Count 10 (+ 1) {\emph{(a)}} y = -3x+2 \newline % Row Count 11 (+ 1) gradient = -3 \newline % Row Count 12 (+ 1) y-intercept: (0,2) \newline % Row Count 13 (+ 1) {\emph{(b)}} y = x-1 \newline % Row Count 14 (+ 1) = 1x+(-1) \newline % Row Count 15 (+ 1) gradient = 1 \newline % Row Count 16 (+ 1) y-intercept: (0,-1) \newline % Row Count 17 (+ 1) {\emph{(c)}} 2y = 5x - 4 \newline % Row Count 18 (+ 1) y = (5)/(2)x - 2 \newline % Row Count 19 (+ 1) gradient = (5)/(2) \newline % Row Count 20 (+ 1) y-intercept: (0,-2) \newline % Row Count 21 (+ 1) {\emph{(d)}} y+2x =6 \newline % Row Count 22 (+ 1) y = 6-2x \newline % Row Count 23 (+ 1) y = -2x+6 \newline % Row Count 24 (+ 1) gradient: -2 \newline % Row Count 25 (+ 1) y-intercept: (0,6)% Row Count 26 (+ 1) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Sketching Linear Graphs}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{Graphing using the y-intercept and gradient}} \newline % Row Count 1 (+ 1) There is no need to plot a number of points to graph linear relationships. Because only 2 points are needed to define a line, use the y-intercept as one point on the graph and the gradient, {\emph{m}} to locate the second point. Once 2 points are known, a straight line can be drawn through them. \newline % Row Count 7 (+ 6) {\bf{Sketching other Linear Graphs, y=mx+b, b ≠ 0}} \newline % Row Count 9 (+ 2) If the y-intercept is not the origin, then first identify the y-intercept from the equation before using the gradient to find the second point. \newline % Row Count 12 (+ 3) Using the equation {\emph{y=mx+b}} and substituting x = 0, you get y = b. \newline % Row Count 14 (+ 2) x = 0 is the x=coordinate of a point on the y-axis, so {\emph{b}} is the y-value at the point at the point at which the graph crosses the y-axis. This is the y-intercept \newline % Row Count 18 (+ 4) {\bf{Worked Example 17}} \newline % Row Count 19 (+ 1) {\emph{Use the y-intercept and the gradient to sketch the graph of y = 2x+1}} \newline % Row Count 21 (+ 2) y-intercept: (0,1) \newline % Row Count 22 (+ 1) Gradient = 2 \newline % Row Count 23 (+ 1) = (2)/(1) = (rise)/(run)% Row Count 24 (+ 1) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Parallel and Perpendicular Lines}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{{\bf{Worked Example 19}} \newline % Row Count 1 (+ 1) {\emph{Find the gradient of the line parallel to each of the following}} \newline % Row Count 3 (+ 2) {\emph{(a)}} y = 2x-5 \newline % Row Count 4 (+ 1) m = 2 \newline % Row Count 5 (+ 1) Any parallel line will have a gradient of 2. \newline % Row Count 6 (+ 1) {\emph{(b)}} 2x + 3y = 6 \newline % Row Count 7 (+ 1) 2x-2x+3y = 6 - 2x \newline % Row Count 8 (+ 1) (3y)/(3) = - (2)/(3)x + (6)/(3) \newline % Row Count 9 (+ 1) y = - (2)/(3)x + 2 \newline % Row Count 10 (+ 1) m1 = - (2)/(3) \newline % Row Count 11 (+ 1) Any parallel line will have a gradient of - (2)/(3). \newline % Row Count 13 (+ 2) {\bf{Worked Example 20}} \newline % Row Count 14 (+ 1) {\emph{Find the gradient of a line perpendicular to each of the following}} \newline % Row Count 16 (+ 2) {\emph{(a)}} y = 4x + 3 \newline % Row Count 17 (+ 1) m1 = 4 \newline % Row Count 18 (+ 1) m2 = - (1)/(m1) \newline % Row Count 19 (+ 1) = - (1)/(4) \newline % Row Count 20 (+ 1) {\emph{(b)}} 3x-5y = 10 \newline % Row Count 21 (+ 1) 3x-3x-5y = 10-3x \newline % Row Count 22 (+ 1) -5y = -3x + 10 \newline % Row Count 23 (+ 1) (-5y)/(-5) = (-3x)/(-5) + (10)/(-5) \newline % Row Count 24 (+ 1) y = (3)/(5)x - 2 m1= (3)/(5) \newline % Row Count 25 (+ 1) m2 = - (1)/(m1) = -(5)/(3)% Row Count 26 (+ 1) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}