Why LaTeX is a better choice than MS Word for doing EE?
Microsoft Word
MS Word is primarily adopted by the business world that is suitable for doing proposals, reports or other general-purpose documents. MS Word is not professional in supporting large documents. Therefore, MS Word is predicted to slow down or crash while handling large texts or with large image files.
The other problem with MS Word’s large documents is the difficulty of typesetting. Every figure, table, or equation number must be manually input because MS Word does not provide the automated order references. The final document is messed up when adding or removing one of them.
On the other hand, MS Word’s auto-format function can occasionally be annoyingly rigid. The photos and the figures may be somewhat obstinate and challenging to position correctly, and the bullets and numbering sometimes have a mind of their own.
What is LaTeX?
LaTeX is a typesetting program adopted by academia and research. Learning Latex takes some effort. After you understand how to use Latex, you’ll discover that it makes it easier than Word for you to generate high-quality scientific documents.
On the other hand, the critical factor in LaTeX’s popularity in academia is that LaTeX can easily insert quality mathematical formulae and expressions into the document. Above is why LaTeX is a better choice for doing EE.
The online platform of LaTeX
There are many online platforms to help create a LaTeX document worldwide, and each has its advantages. Overleaf is one of them which is suitable for LaTeX beginners. It gives you a live preview of your content as you type it. Its error detection and notation support enable quick error detection. Additionally, it is Internet-based so that you may access it from anywhere globally, including a friend’s computer, a computer at the library, or your tablet or smartphone in an emergency.
Understanding the logical formatting of LaTeX
Overview
This article will be based on Overleaf to introduce the LaTeX. When you create a new blank project, Overleaf will auto-insert the basic command codes for you. The blue words or phrases which is after the Backslash “\” are the command code (Backslash “\” is under the “Backspace” or “Delete” button on the keyboard). Each command can have one or more arguments, usually enclosed in curly brackets “{ }” and sometimes square “[ ]” ones.
The left-hand column is where you can begin writing and editing the text. You must compile the document in order to see the effects of these modifications in the right-hand column and PDF. Simply click the “Recompile” button in Overleaf to accomplish this.
Writing Section | Output Section |
Because the preset code is not suitable for the format of EE, you can delete all the code first and follow the below guideline to set the format. Moreover, there is an Overleaf Example file to store all the example coding, you can open it while reading this LaTeX guideline.
Basic Structure
\documentclass
Every LaTeX document must begin with the command “\documentclass”, which must only appear once. Curly brackets specifies the class of document. The “\documentclass” may be a “book”, “letter”, “report,” or an “article” etc. Square brackets indicate optional formatting. If no formatting is specified, LaTeX will use the default values which is 10pt. [12pt,a4paper] are typically specified.
\documentclass[12pt,a4paper]{article}
Command | Meaning | Options |
documentclass | The class of document | book, letter, report and article |
12pt | The normal font size | 10pt, 11pt, 12pt(the default is 10pt) |
a4paper | LaTeX will automatically breaking lines into paragraphs, so it needs to know the size of the paper being used. | a4paper, a5paper, b5paper, letterpaper, executivepaper, legalpaper, etc |
\begin{document} & \end{document}
Anything written between “\begin{document}” and “\end{document}” is the actual document. The text written after the “\end{document}” is not part of the document and is ignored by LaTeX.
Preamble
Preamble refers to the area between “\documentclass” and “\begin{document}”. Any command entered on that part will not appear in the final document. It is used to insert the user package.
Below are the useful packages you can use:
Setting the line spacing
\usepackage[doublespacing]{setspace}
Using the {setspace} package, you can adjust the line spacing of the document. You can set [singlespacing], [onehalfspacing], and [doublespacing] will produce single, one-and-half, and double spacings, respectively.
Setting the margins
\usepackage[margin=2cm]{geometry}
Using the {geometry} package, you can precisely define the width and height of each margin. [margin=2cm] will result in a 2 cm margin on each edge of the paper. Moreover, you can also set top, bottom, left and right margins separately, like [top=2cm, bottom=2cm, left=3cm, right=3cm].
Indent at the start of paragraphs
\usepackage{indentfirst}
LaTeX does not indent the first paragraph of each section by default. Using the {indentfirst} package, the first line of every paragraph will be auto-indented.
Font typefaces
\usepackage{helvet}, \usepackage{mathptmx}
LaTeX defaults using the Computer Modern typeface family. However, you can utilize LaTeX packages to use other fonts based on your requirements or preferences. For example, {helvet} is Helvetica which is similar to Arial and {mathptmx} is Times which is similar to Times New Roman.
Inserting Figures or Pictures
\usepackage{graphicx}
Besides text and tables, you might want to insert images, diagrams, or drawings created using other software in documents. \usepackage{graphicx} is dedicated to this.
Math Symbols
\usepackage{amsmath}
It is helpful for adding equations and formulas to LaTeX documents. It has several features that make it easier to write arithmetic formulas and enhance the output’s typographical quality.
Function | Command | Options |
Line spacing | \usepackage[doublespacing]{setspace} | onehalfspacing, doublespacing(single spacing is the default) |
Margins | \usepackage[margin=2cm]{geometry} | [top=2cm, bottom=2cm, left=3cm, right=3cm] |
Indent | \usepackage{indentfirst} | / |
Font | \usepackage{mathptmx} | {helvet} is Helvetica which similar to Arial {mathptmx} is Times which similar to Times New Roman |
Figures or Pictures | \usepackage{graphicx} | / |
Maths | \usepackage{amsmath} | / |
Bibliography(APA) | \usepackage{apacite} | You only can insert either one APA or MLA preamble. |
Bibliography(MLA) | \usepackage[hidelinks]{hyperref}\usepackage[backend=biber,style=mla]{biblatex}\addbibresource{ref.bib} | You only can insert either one APA or MLA preamble. |
Writing Section |
Body
Sections
Typically, an essay is divided into sections, sections into subsections and so on. LATEX provides already the following hierarchy sectioning commands:
Command | Output Section |
\section{Introduction} | 1 Introduction |
\section{Methods} | 2 Methods |
\subsection{Stage 1} | 2.1 Stage 1 |
\subsubsection{Stage 1.1} | 2.1.1 Stage 1.1 |
The \section is the topmost in the hierarchy. Each section will auto-produce a single number for arrangement. The subsections and subsubsections also are the same.
Writing Section | Output Section |
Begin a new paragraph
In LATEX, two or above consecutive spaces are treated as only one space and two or above empty lines are treated as only one empty line. Therefore, if you want to begin a new paragraph, you need to add “\\” two backslashes after the last sentence of the paragraph and create a blank line by “Enter” between the paragraphs. If you
“\\” two backslashes with “Enter”
Writing Section | Output Section |