Question: Given an $n \times n$ matrix $A$, we can define a linear transformation $T: \mathbb{R}^n \rightarrow \mathbb{R}^n$ by $T(x)=Ax$.

We could also define a bilnear function $T: \mathbb{R}^n \times \mathbb{R}^n \rightarrow \mathbb{R}$ by $T(x,y) = y^TAx$.

Is there a relation between these two uses of the matrix?

Also, we could do the same thing with an $n \times m$ matrix and get a linear function $\mathbb{R}^m \rightarrow \mathbb{R}^n$ and a bilinear function $\mathbb{R}^m \times \mathbb{R}^n \rightarrow \mathbb{R}$. Is the relationship between using $A$ to define a linear function versus a bilinear function the same in this case?

Answer: 
Redefining symbols to avoid ambiguity: $T: \mathbb{R}^n \to \mathbb{R}^n$ is the linear map defined as $T(x) = Ax$ and $S: \mathbb{R}^n \times \mathbb{R}^n \to \mathbb{R}$ is the bilinear map defined as $S(x, y) = y^T A x$.

---

**Constructing bilinear functions from linear functions using inner product**

One way to understand $S$ is as composition of $T$ with the standard inner product $\phi: \mathbb{R}^n \times \mathbb{R}^n \to \mathbb{R}$ defined as $\phi(x, y) = y^T x$, namely

$$
S(x, y) = \phi(T(x), y).
$$

This view allows us to notice some properties of $S$ based on properties of $T$ and known properties of $\phi$. For example, since $\phi$ is known to be non-degenerate, $S$ is non-degenerate if and only if $T$ is an isomorphism.

The construction is readily generalized to the $n \times m$ case by composing $T: \mathbb{R}^m \to \mathbb{R}^n$ with $\phi$.

---

**Change of basis**

For a fixed matrix $A \in \mathbb{R}^{n \times n}$ the construction above yields two functions: a linear function $T\_A: \mathbb{R}^n \to \mathbb{R}^n$ and a bilinear function $S\_A: \mathbb{R}^n \times \mathbb{R}^n \to \mathbb{R}$. The construction takes place in a fixed basis, but the resulting functions $S$ and $T$ are independent of basis, so it is natural to ask how their matrix representation changes under basis transformations.

It easy to see that the matrix representing a linear function transforms differently than the matrix representing a bilinear function. Let $B$ denote an invertible matrix describing a change of basis. Then

$$
T\_A = T\_{A'}
$$

whenever $A' = B^{-1}AB$, i.e. the matrices representing a fixed linear map are [similar](https://en.wikipedia.org/wiki/Matrix_similarity). On the other hand,

$$
S\_A = S\_{A^{''}}
$$

whenever $A^{''} = B^TAB$, i.e. the matrices representing a fixed bilinear map are [congruent](https://en.wikipedia.org/wiki/Matrix_congruence).

This shows that care must be taken when using matrix representations of linear and bilinear functions. Even when a linear function $T$ and a bilinear function $S$ are represented by the same matrix in one basis, it does not imply that they are represented by the same matrix in another basis (unless the basis transformation is orthogonal).
Any bilinear form $b\colon \mathbb R^n\times\mathbb R^n\to\mathbb R$ naturally corresponds to a linear map $\Phi\_b\colon \mathbb R^n\to(\mathbb R^n)^\*$, where $(\mathbb R^n)^\*=\operatorname{Hom}(\mathbb R^n,\mathbb R)$ is the dual space. This correspondence is given by
\begin{align}
b \quad\longmapsto\quad \Phi\_b\colon\mathbb R^n&\to(\mathbb R^n)^\*,\\
x &\mapsto b(x,-).
\end{align}
Here $b(x,-)$ denotes the linear map $\mathbb R^n\to\mathbb R$ sending $y$ to $b(x,y)$.

Considering the elements of $\mathbb R^n$ as column vectors, we can consider the elements of $(\mathbb R^n)^\*$ as row vectors: for $\rho\in(\mathbb R^n)^\*$ and $x=(x\_1,\dots,x\_n)^T$ we have
\begin{align\*}
\rho(x) &= \rho(x\_1 e\_1+\cdots+x\_n e\_n) = x\_1 \rho(e\_1) +\cdots + x\_n \rho(e\_n)
\\&= \begin{pmatrix} \rho(e\_1) & \rho(e\_2) & \dots & \rho(e\_n)\end{pmatrix}
\begin{pmatrix} x\_1 \\ x\_2 \\ \vdots \\ x\_n\end{pmatrix}.
\end{align\*}
Using this identification, there is an isomorphism ${}^T\colon(\mathbb R^n)^\*\to\mathbb R^n$ given by $y\mapsto y^T$.

Now starting with $b(x,y) = y^TAx$ this yields $\Phi\_b(x)=(y\mapsto y^TAx)$ which we identified with the row vector $\Phi\_b(x)=(Ax)^T$. Using the above isomorphism we then obtain a linear map $\mathbb R^n\to\mathbb R^n$:
\begin{align}
\mathbb R^n &\xrightarrow{\Phi\_b}\ (\mathbb R^n)^\*\ \xrightarrow{T} \mathbb R^n,\\
x &\longmapsto (Ax)^T \mapsto Ax.
\end{align}

This is how starting with the bilinear map defined by $A$ we obtain the linear map defined by $A$. You can of course go in the other way as well.

---

More abstractly you can think of this in terms of the [tensor-hom adjunction](https://en.wikipedia.org/wiki/Tensor-hom_adjunction) together with the (basis dependent!) isomorphism $(\mathbb R^n)^\*\cong(\mathbb R^n)$:
\begin{align}
\{\text{bilinear maps $\mathbb R^n\times\mathbb R^n\to\mathbb R$}\}
&\leftrightarrow
\operatorname{Hom}(\mathbb R^n\otimes\mathbb R^n,\mathbb R)
\\&\cong
\operatorname{Hom}(\mathbb R^n,\operatorname{Hom}(\mathbb R^n\to\mathbb R))
\\&=
\operatorname{Hom}(\mathbb R^n,(\mathbb R^n)^\*)
\\&\cong
\operatorname{Hom}(\mathbb R^n,\mathbb R^n).
\end{align}