First try a smaller example.
s[t_] := Integrate[Sin[t], t];
t[s_] := s + 1;
{s[x], t[3]}
(*{-Cos[x], 4}*)
It yields your expected result. On the other hand,
w = 1; Integrate[Sin[w], w]
(*Integrate::ilim: Invalid integration variable or limit(s) in 1.*)
does produce an error. So we have two seemingly contradictory pieces of information. The second example does show that Mathematica does not create dummy variables for integration as it does for for sums:
i = 1; Sum[i, {i, 4}]
(*10*)
Why did the small example work? Because t[s_] := …
does not assign values to t
but values to t[s_]
:
OwnValues[t]
DownValues[t]
(*
{}
{HoldPattern[t[s_]] :> s + 1}
*)
Compare to
OwnValues[w]
DownValues[w]
(*
{HoldPattern[w] :> 1}
{}
*)
Reading the documentation of Integrate, the only hint at Integrate
not creating dummy variables is the sentence
The integration variable can be a construct such as x[i], or any expression whose head is not a mathematical function.
Compare that to the documentation of Sum where it is explicitly stated that
The iteration variable i is treated as local, effectively using Block.
Finally, notice that you can always "test" whether dummies were created by assigning a value to the would-be dummy (the way w
and i
were assigned above). In that sense, the u
in the pattern u_
below is a dummy:
u = 1;
f[u_] := u;
f[3]
(*3*)
Sinh
in you code are distracting from the actual content of your question. $\endgroup$