Find the functions and their domains. (Enter the domains in interval notation.)
f(x) = x + 1/x, g(x) = (x + 17)/(x + 2)
(a) f ∘ g
(f ∘ g)(x) = (2x^2 + 38x + 293) / ((x + 2)(x + 17))
domain (-∐, -17) ∪ (-17, -2) ∪ (-2, ∐)
(b) g ∘ f
(g ∘ f)(x) = (x^2 + 17x + 1) / (x^2 + 2x + 1)
domain (-∐, -1) ∪ (-1, ∐)
(c) f ∘ f
(f ∘ f)(x) = (x^4 + 3x^2 + 1) / (x(x^2 + 1))
domain (-∐, 0) ∪ (0, ∐)
(d) g ∘ g
(g ∘ g)(x) = (18x + 51) / (3x + 21)
domain (-∐, -7) ∪ (-7, ∐)