var('x, scale')
cauchy_cdf(x, scale) = arctan(x/scale)/pi + 1/2
sum_sf(x) = 1 - cauchy_cdf(x, 2)
max_sf(x) = 1 - (cauchy_cdf(x, 1))**2
sumplot = plot(sum_sf, (x, 0, 6), color='red', legend_label='P(sum > x)')
maxplot = plot(max_sf, (x, 0, 6), color='blue', legend_label='P(max > x)')
sumplot + maxplot