I asked a similar question yesterday but I realized it was worded very poorly so I deleted it and I am going to try and rephrase my question. I want to find the taylor approximation (taylor polynomial) at the point $(1,0,0)$ of the following transformation:
$$f(r, \phi,\theta)=\begin{pmatrix}br \sin{\phi}\cos{\theta}\\ar\sin{\phi} \sin{\theta}\\cr \cos{\phi}\end{pmatrix}$$
where $a,b,c \in \mathbb R$.
Since the taylor approximation that I linked and want to use can only be used for scalar valued functions, I have to approximate every component seperately. The formula for the expansion is:
$$T_{2,f}=f(\vec{x}_0)+\nabla^Tf(\vec{x}_0)(\vec{x}-\vec{x}_0)+\frac{1}{2}(\vec{x}-\vec{x}_0)^TH_f(\vec{x}_0)(\vec{x}-\vec{x}_0)$$
where $H_f$ is the Hessian matrix and $\vec{x}_0=(1,0,0)^T$. Now I am facing the following problem:
- What does $\vec{x}$ in this formula refer to?
Up until this point I had only used this formula with cartesian coordinates where $\vec{x}=(x,y,z)^T$ but in this case I am not sure what this is referring to. Do I use $\vec{x}=(r,\phi,\theta)$ or do I use the spherical basis coordinates?
- In case I have to use spherical coordinates for my $\vec{x}$, vector, do I also have to somehow transform my $\vec{x}_0$ vector or is this vector already in spherical coordinates?
EDIT 1: based on the suggestion from Duca_Conte I tried to do it by converting to cartesian coordinates $f(r,\phi, \theta)=f(x,y,z)=(bx,ay,cz)^T$ but the problem becomes "too easy" (almost trivial) and the answer doesn't make much sense so I am not sure that change of coordinates works. If anyone as any idea how to do this I would be very grateful.
EDIT 2: This is the solution I have so far.
- Write the transformation in cartesian coordinates:
$$f(r,\phi, \theta)=f(x,y,z)=\begin{pmatrix}bx \\ay \\cz\end{pmatrix}$$
- Calculate the second-order taylor approximation for each component:
$$T_{2,f_1}=b+b(\frac{\partial f_1}{\partial x},\frac{\partial f_1}{\partial y},\frac{\partial f_1}{\partial z})\begin{pmatrix}x-1\\y\\z\end{pmatrix}+0=2b$$
$$T_{2,f_2}=0 \\ T_{2,f_1}=0$$
$$\implies T_{2,f}= \begin{pmatrix}2b \\ 0\\0\end{pmatrix}$$
This doesn't look right and I am wondering if I am making a big mistake somewhere.
Can anyone tell me if this is the correct way to do this and if not, suggest a solution?
Your problem is mainly a problem of notation; e.g., the names of the variables in your source about the Taylor expansion conflict with the names of the variables in your concrete problem.
You are given a vector-valued map $${\bf f}:\quad {\mathbb R}^3\to{\mathbb R}^3,\qquad(r,\phi,\theta)\mapsto (x,y,z)\ .$$ This map is of a certain practical use, and has a geometric interpretation in terms of affinely scaled spherical coordinates. But this should not disturb us from mechanically applying the rules for finding the Taylor coefficients of ${\bf f}$. In a figure you maybe won't draw the $(r,\phi,\theta)$-space ${\mathbb R}^3$ on the left; but it is there, and has three ordinary axes. You will only draw the $(x,y,z)$-space, and if $a=b=c=1$ you will show the geometric meaning of $r$, $\phi$, $\theta$.
Now $${\bf f}(r,\phi,\theta)=\bigl(x(r,\phi,\theta),y(r,\phi,\theta),z(r,\phi,\theta)\bigr)\ .$$ You have decided to treat the three functions $x(\cdot)$, $y(\cdot)$, $z(\cdot)$ separately. This seems reasonable. Let's consider the function$$x(\cdot):\quad(r,\phi,\theta)\mapsto x(r,\phi,\theta)=b\,r\,\sin\phi\,\cos\theta\ .$$ At this point we need your formula for the Taylor expansion. In terms of the variables at stake it comes as follows: Write $(r,\phi,\theta)=:{\bf r}$ and $(1,0,0)=:{\bf r}_0$.$\ {}^*)\ $ Then $$T_{2,{\bf r}_0} x({\bf r})=x({\bf r}_0)+\nabla x({\bf r}_0)\cdot({\bf r}-{\bf r}_0)+{1\over2}({\bf r}-{\bf r}_0)H_x({\bf r}_0)({\bf r}-{\bf r}_0)\ .\tag{1}$$ Here $T_{2,{\bf r}_0} x$ means "second order Taylor polynomial of the function $x(\cdot)$, centered at ${\bf r}_0$", and I have omitted the ${}^T$ symbols. Now we have to evaluate the things appearing on the RHS of $(1)$: $$\eqalign{x({\bf r}_0)&=x(1,0,0)=0,\cr {\bf r}-{\bf r}_0&=(r-1,\phi,\theta),\cr \nabla x(r,\phi,\theta)&=\bigl(b\sin\phi\cos\theta,b\,r\cos\phi\cos\theta,-b\,r\sin\phi\sin\theta\bigr),\cr \nabla x({\bf r}_0)&=(0,b\,r,0)\ .\cr}$$ I leave it to you to compute the Hessian $H_x({\bf r}_0)$. This will in the end be a $3\times3$-matrix of real numbers.
${}^*)\ $ If $(1,0,0)$ means the point with $(x,y,z)$-coordinates $(1,0,0)$ then ${\bf r}_0=(r_0,\phi_0,\theta_0)$ has to be determined numerically from the equations.