How to write multiple equations [duplicate]

marked as duplicate by Mico math-mode StackExchange.ready(function() { if (StackExchange.options.isMobile) return; $('.dupe-hammer-message-hover:not(.hover-bound)').each(function() { var$hover = $(this).addClass('hover-bound'),$msg = $hover.siblings('.dupe-hammer-message');$hover.hover( function() { $hover.showInfoMessage('', { messageElement:$msg.clone().show(), transient: false, position: { my: 'bottom left', at: 'top center', offsetTop: -7 }, dismissable: false, relativeToBody: true }); }, function() { StackExchange.helpers.removeMessages(); } ); }); }); Mar 11 '18 at 18:06
• Thank you, but it didn't give me what I need $u_i=$ $$\left\{ \begin{array}{ll} 1 & if OR_i \leq r \\ 0 & if if not\\ \end{array} \right.$ – azdoud Mar 11 '18 at 18:36 • Sir @Mico, you mark my question as had an answer, but it did not give me my need – azdoud Mar 11 '18 at 18:39 • $..$ starts math mode, don't put it inside $ ... \$, which also starts math mode. It would likely be better to use the cases environment though. And you'll want to use \text{if } and \text{if not}. For example \documentclass{article} \usepackage{amsmath} \begin{document} $u_i= \begin{cases} 1 & \text{if } OR_i \leq r \\ 0 & \text{if not} \end{cases}$ \end{document} – Torbjørn T. Mar 11 '18 at 18:42