Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

This question already has an answer here:

Im writing a paper using Latex and I get repeatedly this "! Missing $ inserted. $ l.92 ?" error. Its only in two passages and I don't see any obvious mistake I made. The code is:

    \documentclass[a4paper,11pt]{scrartcl}
    \usepackage{amsmath}
    \usepackage[utf8]{inputenc}
    ...
    \begin{document}
    ...
    :<math>\text{rank}\;[E\bigl(\textbf{X'_i}\Omega^{-1}\textbf{X_i}\bigr)]=K\qquad\text{mit}\;\textbf{X_i}=x_{i1},\ldots,x_{iT}</math>
    ...
    \begin{displaymath}
    \hat{\beta}_{RE}=(\sum_{i=1}^{N}\textbf{X'_{i}}\hat{\Omega}^{-1}\textbf{X_{i}})^{-1}(\sum_{i=1}^{N}\textbf{X'_{i}}\hat{\Omega}^{-1}\textbf{X_{i}})
    \end{displaymath}
    ...
    \end{document}

I get the error message for both of these blocks. I only started a week ago with latex and had no bigger problems up to now. Thanks for your help in advance. I use Miktex 2.9,texworks with pdflatex+makeindex+bibtex.

share|improve this question
    
What allows you to use the tags <math>...</math> inside your document? Strip out all the unnecessary stuff and compose a minimal working example (MWE) so that one can compile it with the given lines. The problem in the second component is obvious, but I'm not sure how to deal with the first line... –  Werner May 17 '13 at 1:39
3  
You can't use '\textbf' inside math mode. See tex.stackexchange.com/questions/1328/… and tex.stackexchange.com/questions/595/… –  Nasser May 17 '13 at 8:26
    
If you look error message carefully, you will see where LaTeX added $-sign. There is linefeed after \textbf{...}. In future this will help you spotting errors. –  Jori Mäntysalo May 17 '13 at 10:28
add comment

migrated from stackoverflow.com May 17 '13 at 8:00

This question came from our site for professional and enthusiast programmers.

marked as duplicate by mafp, T. Verron, Kurt, Stefan Kottwitz May 17 '13 at 10:48

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.