15

I'm trying to use symbols such as \lambda and \delta but for some reason it's not compiling. I've reproduced the problem in the following code:

\documentclass[12pt,a4paper,oneside]{article}

\begin{document}

\begin{center}

M = < X,Y,S,ta, \delta int, \delta ext, \lambda >

\end{center}

\end{document}

I'm getting the following errors:

Missing $ inserted M = < X,Y,S,ta, \delta

Missing $ inserted I've inserted a begin-math/end-math symbol since I think

Missing } inserted I've inserted something that you may have forgotten.
Extra }, or forgotten \endgroup

Despite these errors, I can still view it in a PDF and it looks like the following:

The output of above code

So, just to clarify what I actually want:

  1. To compile without the errors i.e. how do you make use of symbols like \delta etc?

  2. How do I actually make it display like the following :

    enter image description here

  3. As depicted above, I want int and ext to be subscripts to the \delta symbols

8
  • 1
    First, you need to surround the relevant line with $ symbols. Second, use underscores to create subscripts (and, for multiple-character subscripts, use curly braces as well). Thus, $M = < X,Y,S,ta, \delta_{int}, \delta_{ext}, \lambda >$ Commented Nov 5, 2012 at 11:18
  • 2
    @AndrewUzzell < and > in this case are definitely wrong.
    – egreg
    Commented Nov 5, 2012 at 11:25
  • @egreg You're absolutely right. Also, when I posted my comment, I hadn't realized that the question was asking for how to typeset a displayed equation. In sum, egreg's answer is much more useful than my comment. Commented Nov 5, 2012 at 11:29
  • 9
    This question shouldn't be downvoted. It may be a basic problem, but the question itself is very clear. Please don't downvote without explaining your reason to do so.
    – Jake
    Commented Nov 5, 2012 at 11:31
  • 3
    In addition to Jake's comment, unlike SO in general, beginner questions are more than welcome in TeX.SE so please don't downvote if the question seems trivial to you. The question has a valid MWE and a good formulation.
    – percusse
    Commented Nov 5, 2012 at 11:34

1 Answer 1

18

You want a centered formula; so the correct way to do it is

\documentclass[12pt,a4paper,oneside]{article}

\begin{document}

\[
M = \langle X, Y, S, ta, \delta_{\mathrm{int}}, \delta_{\mathrm{ext}}, \lambda \rangle
\]

\end{document}

enter image description here

This is covered in any basic LaTeX manual, for example The not so short introduction to LaTeX

5
  • Thanks. But what is the reason behind not using \begin{center}? and why was my question down voted, so I know what I did wrong?
    – Force444
    Commented Nov 5, 2012 at 11:19
  • 1
    center is for centering text, not math. I don't know why the question was downvoted; however, it's very basic and reading an introduction to LaTeX would really help to understand its principles, which are rather different from common word processors.
    – egreg
    Commented Nov 5, 2012 at 11:22
  • Oh okay. Thanks for the reference as well, will use it for any further issues before I ask on here again..
    – Force444
    Commented Nov 5, 2012 at 11:23
  • 7
    @Jatt My comment was not meant for restraining you from asking here even basic level questions. Everybody is welcome, in my opinion. The fact is that LaTeX needs a different attitude than word processors; its main principle is separation of structure from visual appearance, so math is different from text and this reflects in how they're input.
    – egreg
    Commented Nov 5, 2012 at 11:43
  • Thanks for that. I will look further into it. Ps. Your comment did not at all restrain me from asking questions in the future. I agree with you, I should've researched more before asking for help.
    – Force444
    Commented Nov 5, 2012 at 11:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .