Do unital algebras induce (unique) bilinear forms? Let's say we are given a unital algebra structure $\ast: M \times M \to M$ with unit $1_\ast$ on the module $M$ over the commutative ring $R$.
The answers to the following questions are probably well-known and standard, so if anyone knows a reference that would suffice for an answer. I am not familiar with the relevant terminology.

Questions:

*

*Under what conditions does there exists a bilinear form $B: M \times M \to R$ such that, for all $m_1, m_2 \in M$:
$$B(m_1, m_2) = B(m_1 \ast m_2 , 1_*) ? $$
E.g. should the algebra also be associative? How (if at all) does (lack of) commutativity of $\ast$ relate to (lack of) symmetry of $B$?


*Under what conditions is such a bilinear form $B$ unique? Is it ever unique?


*Under what conditions (on $\ast$) is the bilinear form guaranteed to be non-degenerate?

Equivalent reformulation in special case:
If/when we can assume that $B$ is non-degenerate, then (at least when $R$ is a field and $M$ is finite-dimensional) that means we have an isomorphism between $M$ and $Hom(M,R)$, so that we can essentially treat the spaces $Hom(M,M) \cong Hom(M,R) \otimes M$ and $M \otimes M$ as "the same". To be more explicit, let $\iota: M \otimes M \to Hom(M,M)$ denote the induced isomorphism. Doing so, by the universal property of the tensor product, we can essentially identify the bilinear form $M\times M \to R$ with a linear functional (the "trace") $Hom(M,M) \to R$.
Meanwhile, the algebra $*$ implicitly defines two homomorphisms $M \to Hom(M,M)$ via left- and right- multiplication (which I guess are monomorphisms if and only if $\ast$ is "cancellable"), let's say we choose left-multiplication (they're the same homomorphism of course when $\ast$ is commutative), so $m \mapsto (H_m : n \mapsto m \ast n)$, thus $H_m \in Hom(M,M)$ for all $m \in M$.
So anyway, under all those nice circumstances, the above question is equivalent to asking:

For a unital algebra $\ast$, when does there exist a linear functional $\phi: Hom(M,M) \to R$ (with related isomorphism $\iota: M \otimes M \to Hom(M,M)$) such that
$$\phi(\iota(m_1 \otimes m_2)) = \phi(H_{m_1 \ast m_2}) ?$$

(Note that using left- or right-multiplication, $H_{1_\ast}$ always equals the identity $Id \in Hom(M,M)$.)
Example:
Let $M = \mathbb{R}^N$, $R = \mathbb{R}$, $\ast$ be entrywise/Hadamard multiplication, so that $1_{\ast}$ is the all-ones vector.
One can observe that, letting $B$ denote the "standard inner product" or "dot product", that, for any $v, w \in \mathbb{R}^n$,
$$B(v,w) = \sum_{n} v_n w_n = \sum_{n} (v_n w_n) 1 = \sum_{n} (v \ast w)_n 1 = B(v \ast w, 1_{\ast}) \,.$$
Correspondingly, if we identify both $Hom(\mathbb{R}^N, \mathbb{R}^N)$ and $\mathbb{R}^N \otimes \mathbb{R}^N$ as $\mathbb{R}^{N \times N}$, i.e. the space of $N \times N$ real-valued matrices, then $v \otimes w$ is the "outer product", i.e. the rank-one matrix whose $(n_1, n_2)$th entry is $v_{n_1} w_{n_2}$, and the linear functional $\mathbb{R}^{N \times N} \to \mathbb{R}$ induced by $B$ is just the "standard trace", i.e. the sum of the diagonal entries of the matrix.
On the other hand, the map $\mathbb{R}^N \to \mathbb{R}^{N \times N}$ induced by $\ast$ is just the diagonalization operator $\operatorname{Diag}$, so basically the reformulation amounts to the obvious identity that for all $v, w \in \mathbb{R}^n$:
$$\operatorname{trace} (v \otimes w)  = \operatorname{trace}(\operatorname{Diag}(v \ast w)) \,. $$
So basically what I want to know is: are the Hadamard product and the standard inner product two structures that both just happen to exist and coincidentally "play nice" with each other? Or is there really no coincidence, i.e. things are "rigged", and one of the two structures is actually secretly "inducing" or "determining" the other "behind the scenes"? My guess is the former.
Trying to answer the question in this special case, i.e. $M = \mathbb{R}^N$, $R = \mathbb{R}$ seems to lead to a matrix equation for which it's not clear whether there are solutions in general, much less unique ones, because it involves the rank-one matrix all of whose columns are $1_{\ast}$ (for whatever $\ast$ is chosen to be). Any progress towards solving seems to require assuming that $B$ is non-degenerate so that the corresponding matrix is invertible, but I'm not confident that isn't too strong of an assumption.
 A: Let $f:M\to R$ be any module-homomorphism.  Then $B(x,y)=f(xy)$ is a bilinear map $M\times M\to R$ satisfying $B(xy,1)=B(x,y)$.  Conversely, every such $B$ comes from a unique such $f$, by just defining $f(x)=B(x,1)$.  So the bilinear forms you are asking about are essentially the same thing as homomorphisms $M\to R$.  This makes most of your questions trivial to answer--in particular, such a bilinear form always exists (take $f=0$), but is typically not unique, or nondegenerate.  There are nontrivial examples where no nonzero choice of $f$ exists, for instance if $R=\mathbb{Z}$ and $M=\mathbb{Q}$.
A unital associative algebra over a field equipped with such a bilinear form that is nondegenerate is known as a Frobenius algebra.  This seems to be the notion that you are probably trying to come up with, and you can find much more information about them by searching for this term.
A: One context in which Frobenius algebras arise is in topological quantum field theory.  Suppose we have some space (smooth manifold) and some circles floating around in it (smooth embeddings of $S^1$).  Suppose further that the  circles are allowed over time to move (smoothly) and join together to form bigger circles, or pinch off and split into smaller circles.  Suppose further that circles can emerge out of nowhere from a point, or shrink to a point and vanish.
Suppose that there are states $e_1,\cdots,e_n$ for the circles, but rather than being any one state, they exist in some linear combination of states, over a field $k$. Then we can represent the state of a circle by a vector $v\in V=k\{e_1,\cdots,e_n\}$.  If we have $r$ circles then they can exist in any linear combination of $r$-tuples of states, so their state is represented by a vector in $V^{\otimes r}$.  By extension, the state of no circles is represented by an element of $k=V^{\otimes 0}$
Now suppose that we have fixed rules for how states get mapped when circles  emerge, vanish, join or split, and suppose further that these rules are all linear.  So we have an element $1\in V$ which $1\in k$ maps to, when a circle emerges.  We have linear maps $$\Delta\colon V\otimes V \to V, \qquad\nabla\colon V\to V\otimes V,$$ for when circles join or split, respectively, and a map tr$\colon V\to k$ for when a circle vanishes.
We are going to make two final assumptions:

*

*Suppose $r$ circles do a combination of joining, splitting, vanishing, and new circles emerging to leave $s$ circles.  Then the induced linear map $V^{\otimes r}\to V^{\otimes s}$ depends only on the topology of the surface traced out by the circles.


*The bilinear map $V\times V\to V$ given by $(a,b)\mapsto {\rm tr}(ab)$ is non-degenerate.
Then it is easy to see that $(V,\Delta,1,{\rm tr})$ is a finite dimensional, commutative, associative, unital Frobenius algebra.
Conversely any such finite dimensional, commutative, associative, unital Frobenius algebra $(V,\Delta,1,{\rm tr})$ uniquely determines the rules for how states are mapped as circles split join, emerge, vanish.
The non-obvious part of this is that $\nabla$ is determined by the Frobenius algebra.

The above homeomorphism of surfaces tells us that $$({\rm tr}\otimes {\rm tr})(a\otimes b)\nabla x= {\rm tr}(axb),$$
for all $a,b\in V$.
As you noted: $a\mapsto {\rm tr}(a\_\_)$ is an isomorphism $V\to {\rm Hom}_k(V,k)$, so we have $e^1,\cdots,e^n\in V$ that satisfy $${\rm tr}(e^ie_j)=\delta_{ij}.$$
If $\nabla x=x_{kl}e_k\otimes e_l$ (summation convention used throughout) then:$$x_{ij}=({\rm tr}\otimes {\rm tr})(e^i\otimes e^j)\nabla x= {\rm tr}(e^ixe^j).$$
Thus $$\nabla x= x_{ij}e_i\otimes e_j={\rm tr}(e^ixe^j)e_i\otimes e_j= xe^j\otimes e_j,$$
as ${\rm tr}(e^ia)e_i=a$ for all $a\in V$, by construction of the $e^i$.
I said "suppose" about $8$ times in the early part of this answer.  However this way of analysing how circles move and interact can be a powerful tool for studying the ambient space.  For example Khovanov's and Lee's topological quantum field theories were used by Rasmussen as a new way to detect exotic differential structures on spaces homeomorphic to $\mathbb{R}^2\times D^2$.
Here Khovanov's topological quantum field theory comes from the Frobenius algebra $k[t]/\langle t^2\rangle$, with tr$(1)=0$ and tr$(t)=1$.  Similarly, Lee's topological quantum field theory comes from the Frobenius algebra $k[t]/\langle t^2-1\rangle$, with tr$(1)=0$ and tr$(t)=1$.
