I need to graph a function that have multiple given parameters:

EDIT
The code is almost done but I have a little and tricky problem, the solid line is supposed to start at y=3 (just as the dashed one), and now is just a little bit above of 3.
This is my figure:

And this is the expected one:
I have reviewed the code for many hours but I cannot find the error that generates that difference that for me is too important, can any one help me please? This is my code:
\documentclass{article}
\usepackage{tikz}
\usepackage{pgfplots}
\pgfplotsset{compat=1.17}
\pgfplotsset{every non boxed x axis/.append style={x axis line style=-},
every non boxed y axis/.append style={y axis line style=-}}
\begin{document}
\begin{figure}
\centering
\begin{tikzpicture}
\begin{axis}[xlabel={signal},
ylabel={equilibrium bid},
axis lines=left,
declare function={H(\x,\n,\a,\b,\R)=
pow(\R,(\b*(\n-1)+1))*%0
pow(((\n*\b)+\a-1),(\b*(\n-1)))*%0
pow(((\n*\b)+\a),(-\b*(\n-1)))*%0
pow((\x),(-\b*(\n-1)))+(((\n*\b)+\a)/((\n*\b)+\a-1))*\x*%1
((\n-1)*\b)/((((\n-1)*\b)+1))*%0
(1-pow(\R,((\b*(\n-1))+1))*%1
pow(((\n*\b)+\a-1),(\b*(\n-1)+1))*%0
pow(((\n*\b)+\a),((-\b*(\n-1))-1))*%0
pow((\x),((-\b*(\n-1))-1)));},%-1
domain=2.1:2.7,no marks,samples=11
,smooth, ytick distance=0.01, ymin=2.995, ymax=3.055, xmin=2.1, xmax=2.7]
\addplot[color=black, domain=2.1429:2.7]{H(x,2,2.5,0.5,3)};
\addplot[color=black, dashed, domain=2.25:2.7]{H(x,3,2.5,0.5,3)};
\end{axis}
\end{tikzpicture}
\end{figure}
\end{document}
I have checked parentheses and multiplication signs many times and really can't find my mistake.
I appreciate any advice or modification because I really need to come up with that result. The function formula is at the beginning of the post and maybe there is an error there but I am not able to find it.



