How do I solve for lim h->0 (((a+h)^2 + 1)/(3(a+h)+7) - ((a^2 + 1)/3a + 7)) and then all divided by h?

The question was use the limit definition to find the derivative of f(x)= (x^2 + 1)/(3x + 7).

I tried solving what I did above, but had no luck. I used wolfram alpha to get my answer of (3(a^2) + 14a - 3)/((3a + 7)^2). Could someone please show me the steps to arrive at this answer?

First of all, why did you switch from x to a ?

My first line ...
lim [ ((x+h)^2+1)/(3(x+h)+7) - (x^2 + 1)/(3x + 7) ] /h as h ---> 0
= lim [((3x+7)((x+h)^2 + 1) - (3x+3h+7)((x^2+1))/(((3x+3h+7)(3x+7))] / h

carefully expand the numerator, leave the bottom alone
Each term in the numerator WILL have a common factor of h, cancel it with the h at the bottom.
You will get the answer that your Wolfram link gave you.

To find the derivative of the function f(x) = (x^2 + 1)/(3x + 7) using the limit definition, we need to follow the steps below:

Step 1: Write down the given function:
f(x) = (x^2 + 1)/(3x + 7)

Step 2: Determine the slope of the secant line between two points on the graph of the function. To do this, we need to find the difference quotient, which is the slope of the secant line between two points (x, f(x)) and (x + h, f(x + h)).

Step 3: Apply the difference quotient formula. The difference quotient formula is given by:
f'(x) = lim h->0 (f(x + h) - f(x))/h

Step 4: Substitute f(x) into the formula:
f'(x) = lim h->0 (((x + h)^2 + 1)/(3(x + h) + 7) - ((x^2 + 1)/(3x + 7)))/h

Step 5: Simplify the expression inside the limit:
f'(x) = lim h->0 ((((x^2 + 2hx + h^2) + 1)/(3x + 3h + 7)) - ((x^2 + 1)/(3x + 7)))/h

Step 6: Simplify further by finding a common denominator for both fractions in the numerator:
f'(x) = lim h->0 (((x^2 + 2hx + h^2 + 3x + 7 - (x^2 + 1)(3x + 3h + 7))/(3x + 3h + 7)(3x + 7)))/h

Step 7: Expand and cancel out the like terms:
f'(x) = lim h->0 ((3x^2 + 6hx + 3h^2 + 3x + 7 - (3x^3 + 6x^2 + 3hx + 3x + 3x^2 + 6x + h + 7))/(3x + 3h + 7)(3x + 7))/h

Step 8: Simplify the expression further by combining like terms:
f'(x) = lim h->0 ((-3x^3 + 3x^2 - h^2 - h)/(3x + 3h + 7)(3x + 7))/h

Step 9: Cancel out the common factor of h in both the numerator and denominator:
f'(x) = lim h->0 ((-3x^3 + 3x^2 - h(h + 1))/(3x + 3h + 7)(3x + 7))/h

Step 10: Take the limit as h approaches 0:
f'(x) = (-3x^3 + 3x^2)/((3x + 7)(3x + 7))

Step 11: Simplify the expression:
f'(x) = (-3x^3 + 3x^2)/(9x^2 + 42x + 49)

So, the derivative of f(x) = (x^2 + 1)/(3x + 7) is f'(x) = (-3x^3 + 3x^2)/(9x^2 + 42x + 49).

If you obtained a different answer using Wolfram Alpha, it is possible that there was a mistake in your calculations or in the formatting of the equation. Double-check your steps to see if you made any errors.