If we get the Maclaurin expansion for $f(x)$, but we have an infinite number of terms, this would actually be the function $f(x)$(?) My thinking is that at $0$, the expansion would be the same as $f(x)$, and every other derivative would be equal so surely it would match $f(x)$ exactly?

Say $f(x)=\frac{1}{1-x}$, then the Maclaurin series is clearly a geometric progression, $1+x+x^2+x^3+...$, and for large $x$ we can see it obviously isn't remotely close to $f(x)$. So is this just a weird bit of maths, or is there something I'm missing, ie is my first paragraph wrong? Sorry if this is a bit confusing, I just can't get my head around why Maclaurin only works for certain $x$ values.