I've got a real-valued function of several vectors $f(u,v,w)$ formed by taking scalar products of linear combinations of the vectors,
I want to Taylor expand around small $v$ by writing
$$f(u,\delta v, w) = A + B\delta + O(\delta^2)$$
for small real $\delta$. When I do this in Mathematica, the output gives me terms like $v(1.u)$ rather than simplifying this to $v.u$.
Note that I have put into my assumptions that $u,v,w$ are all vectors. My Mathematica code is below.
$Assumptions = (p|q|r|P|m|n) ∈ Vectors[4]
(p|q|r|P|m|n) ∈ Vectors[4, Complexes]
FullSimplify[
TensorExpand[
Series[((n + q).(n + q)(p + q + δ r).(p + q + δ r))/
(P.P(p + δ r).(p + δ r) -
(p + n + δ r).(p + n + δ r)(p + q + δ r).(p + q + δ r)),
{δ,0,1}]],
{p.p == 0, q.q == 0, r.r == 0, n.n == 0, m.m == 0, δ ∈ Reals}]
-(n.q/n.p) + (r n.q (2 (1.n + 1.p + n.1 + p.1) p.q - (1.p + p.1) P.P) δ)/(4 (n.p)^2 p.q) + O[δ]^2
TensorExpand
inside theSeries
asSeries[TensorExpand[<tensor expression>]]
. $\endgroup$