If we want to integrate a quotient of two high degree polynomials like $$ \int\frac{x^a}{1+x^b}dx ~~~\text{with $a$, $b$ }\in\mathbb{N} $$ then I came to the conclusion in an exercise that if $0 < a = b - 1$, we get that $$\int\frac{x^a}{1+x^b}dx = \frac{\ln(1+x^b)}{b} + C$$ from integrating.
I wonder how to solve this if we don't have this specific relationship between $a$ and $b$. I'm not completely certain about this, but I imagine you can do integration by parts, integrating the $1+x^b$ part and the resulting $\ln$-terms until $x^a$ becomes $1$ (probably after $a$ times?). That method, however, seems very tedious and prone to making mistakes.
Is there good way of solving this when $a$ and $b$ are big but don't have that specific relationship?