diff%28f%28x%29/g%28x%29%29
Want to compute something more complicated? Try a full Python/SymPy console at SymPy Live.