I have the code

```
\documentclass{amsart}
\begin{document}
\begin{equation}
]-\pi,0[ \qquad -\pi \qquad \int_{-\pi}^0 \qquad [-\pi,0]
\end{equation}
\end{document}
```

which produces

Why is the minus sign on the left so far away from pi and how can this be avoided?

## Best Answer

In the TeXbook, Knuth refers to people using “]a,b[” notation for open intervals as “perverse mathematicians” (page 171, exercise 18.14). I don't fully agree with the adjective, but I find the notation very awkward nonetheless.

There is already a package for this, which avoids reinventing the wheel:

The middle

`-\pi`

needs braces, but it's a very different problem.See the documentation for

`interval`

to learn about other options.## Note about Werner's solution

Consider the following code and compile it to see what results:

(properly embed it in a standard document).

It should be clear that simply bracing

`-\pi`

is not sufficient.