We use cookies on this site. By browsing our site you agree to our use of cookies. Close this message Find out more

More in this section LateX

Basic Equations

Entering equations in LateX is very similar to other programming languages, with a few distinct differences which will become obvious shortly.

Let's begin with the code for a very simple equation x = y/z

x = \frac{y}{z}



This code is very simple, the only thing to bear in mind is to make sure you have the appropriate begin and end tags. Let's move onto something a bit more complicated:

\overline{x} = \frac{\sum_0^M x_i p_i}{\sum_0^M p_i}


The notation here is different to what you are probably used to. To set the limits on a sum or integral you must use the "^" character as shown above. However, when using subscripts or superscripts the normal conditions apply... use "_" for subscripts and "^" for superscripts.

More useful equations and code to go with them:

\cos (2\theta) = \cos^2 \theta - \sin^2 \theta

\int \cos (2\theta) = \int \cos^2 \theta - \int \sin^2 \theta
\int_0^\infty \cos x = \int_0^\infty \cos y - \int_0^\infty \sin y


Comment on this page

Did you find the information you were looking for? Is there a broken link or content that needs updating? Let us know so we can improve the page.

Note: If you need further information or have a question that cannot be satisfied by this page, please call our switchboard on +44 (0)1784 434455.

This window will close when you submit your comment.

Add Your Feedback