Both bodies are assumed to be steel (Poisson's ratio nu = 0.3). For convex-concave contact, enter a large radius for R2.
Left: cross-section of the two cylinders with the contact strip of width 2a / Right: Hertz pressure p(x)=pmax·√(1-(x/a)²), peak at the centerline.
Hertz line contact formulas for two parallel cylinders of radii $R_1$ and $R_2$ pressed together by a line load $P'$ per unit length.
Equivalent radius and equivalent modulus:
$$\frac{1}{R_e} = \frac{1}{R_1} + \frac{1}{R_2}, \quad \frac{1}{E^*} = \frac{1-\nu_1^2}{E_1} + \frac{1-\nu_2^2}{E_2}$$Contact half-width $a$ and maximum contact pressure $p_\text{max}$:
$$a = \sqrt{\frac{4\,P'\,R_e}{\pi\,E^*}}, \quad p_\text{max} = \sqrt{\frac{P'\,E^*}{\pi\,R_e}} = \frac{2\,P'}{\pi\,a}$$Pressure distribution across the strip and average pressure:
$$p(x) = p_\text{max}\sqrt{1-\left(\frac{x}{a}\right)^2}, \quad p_\text{avg} = \frac{\pi}{4}\,p_\text{max} = \frac{P'}{2a}$$For convex-concave contact (e.g. ball in an outer-race groove), substitute a negative radius for the concave side into $1/R_e$. Point contact (sphere) uses a different formula where $a$ scales with the cube root of the load.