MATLAB: Maclaurin series for ln(x) and ln(x+1)

classmaclaurinnumerical analysis

Greetings,
I am trying to find maclaurin series for ln(x) and ln(1+x),
Can anyone help me how to do them on matlab?
Thanks,

Best Answer

Maclaurin series is just a Taylor series expanded at x = 0. For ln(x) the series does not exist. For ln(1+x), try the following
syms x
y = log(x + 1);
y_series = taylor(y, x, 0, 'Order', 10)