I have a scalar value function, f, defined in a Euclidean space of 2N dimensions. I want Taylor to expand this function on a point $ P $. I need to be able to explicitly write all the terms in the expansion of at least 2nd order.

If I were working on Cartesian coordinates, I would define a base such that $ P = (x_1 ^ prime, y_1 ^ prime, x_2 ^ prime, y_2 ^ prime, …, x_N ^ prime, y_N ^ prime) $, and Taylor's expansion would be given by

$$ f (x_1, y_1, …) = f (x_1 ^ prime, y_1 ^ prime, …) + sum_ {i = 1} ^ N Big ((x_i-x_i ^ prime) frac { partial f} { partial x_i} | _ {x_1 ^ prime, y_1 ^ prime, …} + (y_i-y_i ^ prime) frac { partial f} { partial y_i} | _ {x_1 ^ prime, y_1 ^ prime, …} Big) + \

frac {1} {2!} sum_ {i = 1} ^ N sum_ {j = 1} ^ N Big ((x_i-x_i ^ prime) (x_j-x_j ^ prime) frac { partial ^ 2 f} { partial x_i partial x_j} | _ {x_1 ^ prime, y_1 ^ prime, …} + (x_i-x_i ^ prime) (y_j-y_j ^ prime) frac { partial ^ 2 f} { partial x_i partial y_j} | _ {x_1 ^ prime, y_1 ^ prime, …} + (y_i-y_i ^ prime) (x_j-x_j ^ prime) frac { partial ^ 2 f} { partial y_i partial x_j} | _ {x_1 ^ prime, y_1 ^ prime, …} + (y_i-y_i ^ prime) (y_j-y_j ^ prime) frac { partial ^ 2 f} { partial y_i partial y_j} | _ {x_1 ^ prime, y_1 ^ prime, …} Big) + … $$

However, I want to work on polar coordinates, $ (r_1, theta_1, r_2, theta_2, …) $. So, I should define $ P = (r_1 ^ prime, theta_1 ^ prime, …) $, and Taylor's expansion, written explicitly in the first order, resembles the following (if I have this correct).

$$ f (r_1, theta_1, r_2, theta_2, …) = f (r_1 ^ prime, theta_1 ^ prime, …) + sum_ {i = 1} ^ N Big (( r_i-r_i ^ prime) frac { partial f} { partial r} | _ {r_1 ^ prime, theta_1 ^ prime, …} + r_i ( theta_i- theta_i ^ prime) frac { partial f} { partial theta_i} | _ {r_1 ^ prime, theta_1 ^ prime, …} Big) + … $$

I feel that this formula should be written somewhere, but I can't find it. I know that the second order terms can be written as a tensor product $ x ^ i H_ {ij} x ^ j $, where $ H_ {ij} $ it is the matrix of Hesse (tensor), which would be useful if I could find an explicit formula for the Hesse in a polar coordinate base.

Can anyone write the second order terms in Taylor's expansion, or equivalently, provide the elements of the Hessian on a polar basis? Keep in mind that I am an engineer, so ideally I am looking for a written response explicitly using polar coordinates, rather than covariant gradients, Levi-Civita symbols, etc. Although any help to make progress towards the explicit formula is greatly appreciated.