How to write mathematical expressions?

Click For Summary

Discussion Overview

The discussion revolves around how to correctly write mathematical expressions using LaTeX in the forum. Participants are sharing their experiences and troubleshooting issues related to formatting.

Discussion Character

  • Technical explanation

Main Points Raised

  • Gamma inquires about the correct way to write a mathematical expression in LaTeX, presenting an example that does not parse correctly.
  • Nylex suggests that the issue may be due to an unnecessary space between the LaTeX command and the expression.
  • Daniel challenges Nylex's assertion, arguing that LaTeX does not have issues with spaces and points out a different error related to the use of brackets in the closing command.
  • Gamma acknowledges the feedback and identifies the problem as being related to the backslash in the closing command.

Areas of Agreement / Disagreement

The discussion contains disagreement regarding the role of spaces in LaTeX parsing, with some participants supporting the idea that spaces are problematic while others argue they are not. The resolution of the original issue remains somewhat unclear.

Contextual Notes

Participants reference specific formatting issues and LaTeX syntax without fully resolving the underlying confusion about the rules governing LaTeX commands.

Gamma
Messages
355
Reaction score
11
Can anyone tell me how I can write mathematical expressions here. I read the 'LateX crash course'. See what happens.

[tex]a^2 + b = sqrt {c}[\tex]<br /> <br /> What am I doing wrong?<br /> <br /> regards,<br /> Gamma.[/tex]
 
Physics news on Phys.org
You've got a space between [tex]and a^2, methinks that's why it isn't being parsed.[/tex]
 
Nylex said:
You've got a space between (tex) and a^2, methinks that's why it isn't being parsed.

You're wrong,Nylex.LaTex doesn't mind about spaces.He wrote "a^2 + b = sqrt {c}(\tex)",instead of "a^2 + b =\sqrt{c}(/tex).Which should give:
[tex]a^2 + b = \sqrt {c}[/tex]

Daniel.

PS.I used "(" instead of "[" so that the compiler wouldn't give error.Click on the fromula to see the code and compare it with yours.
 
Last edited:
Thank You.

Got it. I think the error is in the back slash in [/tex]

[tex]a^2 + b = \sqrt{c}[/tex]


Gamma
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 6 ·
Replies
6
Views
4K
  • · Replies 9 ·
Replies
9
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 7 ·
Replies
7
Views
3K
  • · Replies 9 ·
Replies
9
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K