Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 804223
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T23:53:01+00:00 2026-05-14T23:53:01+00:00

I was surprised that the Latex code from a recent question didn’t throw up

  • 0

I was surprised that the Latex code from a recent question didn’t throw up any errors, and even more surprised on further investigation, that Crowley’s explanation seems to be true. My intuition about the \begin{equation} ... \end{equation} code is clearly off, what’s really going on?

Consider this, slightly adapted code:

\begin{equation} 
1: e^{i\pi}+1=0
$$  2: B\"ob $$ 
3: e=mc^2 
\end{equation}

This seems to prove that Crowley’s explanation of such code, namely that “What that code says to LaTeX is begin equation, end it, begin it again, typeset definition of tangens and end the equation” is right: lines 1&3 can only be typeset in maths mode, line 2 only in text mode.

Shouldn’t Latex see that the \end{equation} is ending a display math that wasn’t started by the \begin{equation}?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T23:53:02+00:00Added an answer on May 14, 2026 at 11:53 pm

    Maybe it is because of environments math and displaymath.

    I just tried those codes

    \[\alpha$$ – works properly

    \begin{displaymath}\alpha$$ – error (\begin{displaymath} ended by \end{document}) *

    \displaymath\alpha$$ – works properly

    \displaymath\alpha\displaymath – error (Bad math environment delimiter)

    \displaymath\alpha\enddisplaymath – works properly.

    Symetric options produce same results, so I think there’s in LaTeX command definition

    \newcommand{\[}{\displaymath}
    \newcommand{\]}{\enddisplaymath }
    \newenvironment{displaymath}{\displaymath}{enddisplaymath}
    

    and in TeX something like

    "if(displaymath)
     {$$ := \displaymath}
     else
     {$$ := \displaymath}"
    

    Maybe I’m wrong, but this seems logical to me.


    • Note: That proves that I was wrong. Better words are It says: “Begin equation, switch to text mode, switch back to displaymath, typeset tangens definition and finally end the equation”.
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm always surprised that even after using C# for all this time now, I
I just worked through a book on WCF and was surprised that it didn't
I have to admit that having not even tried to code this myself this
I'm new to ReSharper and am surprised that there isn't a template defined for
I was surprised recently to find that it's possible to have a return statement
It's my understanding that StackOverflow (SO) was built using ASP.NET. What surprised me is
I am surprised that the following calls result in type-cast warning: I have a
I'm writing an iPhone app, and I'm surprised that there seem to be no
I have a common problem in an ASP.NET web form. I'm just surprised that
After writing code that can be boiled down to the following: var size=-1; var

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.