The complement to `free_symbols` is `is_number`; the fastest way to see if there is a free symbols is to use

```
if expr.is_number:  # instead of `if not expr.free_symbols`
    raise ValueError...
```

`is_number` quits when it hits a symbol; `free_symbols` searches the entire expression tree for symbols