I earlier did a tutorial on how to write mathematical equations using Latex which covered the "equation" environment in LaTeX. Math environment is equally important and in this tutorial I am going to talk about how to use basic math environment in LaTeX.

Specifically, I am going to discuss how to do the following in LaTeX:

- How to initiate Math environment
- Writing inline math equations and writing equations in a separate line
- How to use frac for equations
- How to use paranthesis and brackets to enclose mathematical symbols and equations
- How to type powers and indices
- How to write matrices

\documentclass{article}

\usepackage{amsmath}

\usepackage{amssymb}

\begin{document}

\title{Basic Mathematics with Latex by http://QuickLatex.blogspot.com}

\maketitle

This is inline \[n\] math symbol.

For inline $n$ or \(n\) is used and for displayed math we can use $$n$$ or \[n\].

We start with $n$ elements and we continue to divide them in half leaving $\frac{n}{2}$ elements.

The power can be written using caret symbol, for instance $n^n$ results in n to the power n written nicely.

The indices could be written using underscore, for instance $n_i$ makes i an index of n.

$(\frac{n}{2})$

$\left( \frac{n}{2} \right)$\\

$[\frac{n}{2}]$

$\left[ \frac{n}{2} \right]$\\

$

\left(

\begin{array} {c c c}

1 & 2 & 3\\

4 & 5 & 6\\

7 & 8 & 9

\end{array}

\right)

$

\end{document}

Hi. I was wondering that is it possible to integrate LaTex with HTML? I mean I intend to write some complex mathematical equations on my blog so what will you suggest? Is HTML enough for that or shall I use some other equations producing software?

ReplyDeleteSuch kind of errors are generated. :(

ReplyDelete"C:/Users/user/Desktop/latex files/art.tex"

LaTeX2e <2009/09/24>

Babel and hyphenation patterns for english, dumylang, nohyphenation, ge

rman, ngerman, german-x-2009-06-19, ngerman-x-2009-06-19, french, loaded.

("C:\Program Files\MiKTeX 2.8\tex\latex\base\article.cls"

Document Class: article 2007/10/19 v1.4h Standard LaTeX document class

("C:\Program Files\MiKTeX 2.8\tex\latex\base\size10.clo"))

LaTeX Warning: Unused global option(s):

[12].

No file art.aux.

! Undefined control sequence.

l.4 \make

title