Why does the determinant of the metric tensor depend on the coordinates?

It is my understanding that the matric tensor field $$g$$ of a diff. manifold $$M$$ is a section of the tensor bundle $$T^*M\otimes T^*M$$. So that $$g:p\mapsto g_p\in T_p^*M\otimes T_p^*M$$ is the assignment of an inner product on the tangent space at $$p\in M$$ and it induces an isomophism $$\hat{g}_p:T_pM\to T_p^*M$$ given by $$X\mapsto \bigr(Y\mapsto g_p(X,Y)\bigr)$$ However, this assignment is defined independent on the charts, and thus it would seem like $$\text{det } g_p$$ is well defined independent on any coordinate choice. However, when dealing with, for example 'spherical coordinates' on $$\mathbb R^3$$, we can write the metric tensor field $$g$$ as \begin{align} g=dr\otimes dr+r^2d\theta\otimes d\theta+r^2\sin(\theta)d\varphi\otimes d\varphi. \end{align} Now, in the basis $$\{\partial_r,\partial_\theta,\partial_\varphi\}$$ and $$\{dr,d\theta,d\varphi\}$$ for $$T_pM$$ and $$T_p^*M$$, the linear map $$\hat{g}_p$$ takes the matrix form \begin{align} \hat{g}_p= \begin{pmatrix} 1 & 0 & 0 \\ 0 & r^2 & 0 \\ 0 & 0 & r^2\sin(\theta) \end{pmatrix}. \end{align} This matrix has determinant $$r^4\sin^2(\theta)$$, where as in cartesian coordinates $$\det \hat g_p=1$$. I do not know how to reconcile this with the fact that the determinant is well defined without any choice of basis. What is it that I am not understanding?

• This is already visible in the setting of linear algebra, since the determinant of the matrix representation of a bilinear form is not independent of the choice of basis! (math.stackexchange.com/questions/2038086/…) Apr 14, 2021 at 18:57
• @Jake28 does that mean that the isomorphism $\hat g_p$ depends on a choice of basis? For if not, then it’s determinant would not depend on the choice of basis, given that it is a linear transformation from a vector space to its dual Apr 14, 2021 at 19:12
• To emphasize Jake's point, the determinant of a linear transformation is basis-independent because $\det(P^{-1}AP)=\det A$. However, the determinant of a bilinear form is not, because $\det(P^\top AP)\ne \det A$ unless $P$ is orthogonal. Apr 14, 2021 at 19:21
• Also, for comparison - you might be interested in math.stackexchange.com/questions/806012/… Apr 15, 2021 at 0:48

In order to be more specific, let $$V$$ be a vector space and $$\varphi:V\to V$$ be a linear map. In this case you can define the determinant of $$\varphi$$ by taking the determinant of some particular matrix representation. This definition is independent of the choice of basis, since the matrix representation of $$\varphi$$ with respect to another basis and the original matrix representation are related by conjugation. (and the determinant is invariant under conjugation)
However, if you have two different vector spaces $$V,W$$ and a linear map $$\psi:V\to W$$, then there is no way to define the determinant of this map (in an invariant way). Therefore it doesn't really make sense to talk about the determinant of the map that you called $$\hat{g}_p$$ since it's not a map from $$T_pM$$ to itself.