
MHB Master
#1
February 11th, 2018,
01:56
Recently I posted the following text on the Analysis forum ...
" ... ... In order to demonstrate that $ \displaystyle K$ is closed, we prove that $ \displaystyle \mathbb{R}^n\K$ is open. Indeed, choose $ \displaystyle y \notin K$ and define $ \displaystyle O_j = \{ x \in \mathbb{R}^n \ \mid \ \mid \mid x  y \mid \mid \gt \frac{1}{j} \}$ for $ \displaystyle j \in \mathbb{N}$. ... ... "
... and (as I did above) got a red \K in \mathbb{R}^n\K presumably because I'm misusing a special character \ in the code ...
What is wrong with what I've done and how do I correct it?
Further, how does one correctly write Latex code for one set minus another as in A\B?
Peter

February 11th, 2018 01:56
# ADS
Circuit advertisement

Pessimist Singularitarian
#2
February 11th, 2018,
02:19
This works, although there might be a better solution...
\mathbb{R}^n\text{\\}K
gives:
$ \displaystyle \mathbb{R}^n\text{\\}K$

MHB Master
#3
February 11th, 2018,
02:26
Thread Author
Originally Posted by
MarkFL
This works, although there might be a better solution...
\mathbb{R}^n\text{\\}K
gives:
$ \displaystyle \mathbb{R}^n\text{\\}K$
Thanks Mark ... but seems strange to me that two \s are required in text{ \\ } ... but then ... hey ... that's the rules of the code
Thanks again ...
Peter

Pessimist Singularitarian
#4
February 11th, 2018,
02:35
Originally Posted by
Peter
Thanks Mark ... but seems strange to me that two \s are required in text{ \\ } ... but then ... hey ... that's the rules of the code
Thanks again ...
Peter
Yeah, you have to escape the escape character to get a literal character.
You can also use:
\mathbb{R}^n\backslash K
or:
\mathbb{R}^n\setminus K (this one has more padding to the left and right of the slash)

Pessimist Singularitarian
#5
February 11th, 2018,
02:39
I also want to point out that in the "MHB Widgets" block to the right of the editor is "Detexify" listed as the second entry in the list, and clicking that will popup a window into which you can draw a character you wish to use, and it will give you in most cases several options to try.

#6
February 11th, 2018,
16:31
Originally Posted by
MarkFL
\mathbb{R}^n\setminus K (this one has more padding to the left and right of the slash)
This is the correct solution.
Originally Posted by
Peter
What is wrong with what I've done and how do I correct it?
The command \K is undefined. TeX commands usually consist of a backslash followed by letters.