This question already has an answer here:

How to write following inline formula in LaTeX: r~[0,1]

marked as duplicate by Werner math-mode Aug 28 '14 at 20:05

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.

$r\sim[0,1]$ or $r\thicksim[0,1]$

Not the answer you're looking for? Browse other questions tagged or ask your own question.