# Writing the dimension of a variable in latex

I am trying to write the information about the dimension of a vector like this

$M \epsilon R^N$


In the paper, they write it nicely, it looks nice. However, I am not sure what I am doing wrong, but it doesn't look good. Suggestions?

## migrated from stackoverflow.comApr 18 '14 at 18:02

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

• This is not very clear. Why "doesn't [this] look good"? – Werner Apr 17 '14 at 17:39

I think you want to edit the style of fonts and symbols, but unless you give graphical details of what you want to achieve it is difficult to do it. The symbol for "belongs to" is obtained with \in. Then you can play with \mathcal if you want stylized R:
$M \in \mathcal{R}^N$

• Or \mathbb{R}, which requires \usepackage{amsfonts} or, perhaps better, \usepackage{amssymb}. – egreg Apr 18 '14 at 18:19