Avoid superfluous CSEs from Idx and IndexedBase instances

Continuing my work on codegeneration of finite differences using Sympy I've come across
a possiblity for a minor enhancement of the cse routine:

consider:

```python
from sympy import *
len_y=5
i = Idx('i', len_y-1)
y = IndexedBase('y', shape=(len_y,))
x = IndexedBase('x', shape=(len_y,))

# Forward difference
print(cse((y[i+1]-y[i])/(x[i+1]-x[i])))
```
which outputs

```
([(x0, y), (x1, i), (x2, x1 + 1), (x3, x)], [(-x0[x1] + x0[x2])*(-x3[x1] + x3[x2])**(-1)])
```
here, the Idx and IndexedBase instances have been taken to be cses which makes e.g. code generation
much more verbose (in reality I have more indices and more IndexedBase).

This PR fixes the issue and only "i+1" is correctly identified as a true CSE.
Because `Idx` is now subclassed from `AtomicExpr`, this will happen:

```
>>> i = Idx('i', n)
>>> isinstance(i, Atom)
True
```

Are all things that subclass from `AtomicExpr` (and thus from `Atom` as well) considered to be "atomic"? Even if they have args? Should they set `is_Atom = True`? If so, you could just use `isinstance(*, Atom) instead of special casing `Idx`.

I ask because there are plenty of things in sympy that could be considered "atomic" for cse, but aren't because they aren't actual atoms. 'MatrixSymbols' are one. As you've shown, 'Idx' is another.