0
Clear["Global`*"];
f[x_, y_] := Log[1 + x + y]; Series[f[x, y], {x, 0, 3}, {y, 0, 3}]

How to get this form: x+y - 1/2 (x+y)^2+1/3 (x+y)^3+...

lotus2019
  • 2,091
  • 5
  • 10

2 Answers2

4

Perhaps, knowing x,y to be small of equal order:

Normal[Series[Log[1 + eps (x + y)], {eps, 0, 3}]] /. eps -> 1
(*x + y - 1/2 (x + y)^2 + 1/3 (x + y)^3*)
Ulrich Neumann
  • 53,729
  • 2
  • 23
  • 55
3

Use the definition of Taylor series for multiple variables function.

n = 3;
{x0, y0} = {0, 0};
taylor=Sum[1/i! Dot[D[f[x, y], {{x, y}, i}] /. Thread[{x, y} -> {x0,y0}], 
   Sequence @@ ConstantArray[{x, y} - {x0, y0}, i]], {i, 0, n}]//Expand
taylor==x+y - 1/2 (x+y)^2+1/3 (x+y)^3//Simplify

x - x^2/2 + x^3/3 + y - x y + x^2 y - y^2/2 + x y^2 + y^3/3

True

cvgmt
  • 72,231
  • 4
  • 75
  • 133