I want to plot the heat map of a two-variable function which has two arguments, but the function is continuous on the transition line.
However, the densityplot put no color on the transition line.
Here is an example
r[x_, y_] = If[x^2 + y^2 <= 1, x^2 + y^2, If[x^2 + y^2 >= 1, 1]]
DensityPlot[r[x, y], {x, -2, 2}, {y, -2, 2}, PlotRange -> All]
This gives the following image
I want the white circle to be coloured as 1.
Exclusions -> None
. $\endgroup$