I am trying to find black hole shadow contour with respect to temperature. with metricf[r_] := -((2*M*r^2)/(g^3 + r^3)) + (8/3)*Pi*P*r^2 + 1. So here is my code,
f[r_] := 1 - (2*M*r^2)/(r^3 + g^3) + (8/3)*Pi*P*r^2;
M = ((g^3 + r^3)*(8*Pi*P*r^2 + 3))/(6*r^2);
T = (-(2*g^3) + 8*Pi*P*r^5 + r^3)/(4*Pi*r*(g^3 + r^3));
\[Xi] = ((3 + 8*Pi*r^2)^3*(g^3 + r^3)^3)/(216*r^6) + Sqrt[g^6 -
(g^3*(3 + 8*Pi*r^2)^3*(g^3 + r^3)^3)/(108*r^6)] - g^3;
rp = g^3/(2*r^2) + r/2 + (4/3)*(g^3 + r^3)*P*Pi + ((3 +
8*Pi*r^2)^2*(g^3 + r^3)^2)/(36*r^4*\[Xi]^(1/3)) + \[Xi]^(1/3);
rs = rp/Sqrt[f[rp]];
shadowcontour[met_, g_, p_, T1_, T2_] := Module[{T, r, \[Theta],
shadowrad, photonrad, xi, rh},
rh = r /. Last[NSolve[T - (-2*g^3 + r^3 + 8*p*Pi*r^5)/(4*Pi*r*(g^3 + r^3)) == 0, r]];
xi = ((3 + 8*Pi*r^2)^3*(g^3 + r^3)^3)/(216*r^6) + Sqrt[g^6 - (g^3*(3 + 8*Pi*r^2)^3*(g^3 + r^3)^3)/(108*r^6)] - g^3;
photonrad = g^3/(2*r^2) + r/2 + (4/3)*(g^3 + r^3)*p*Pi + ((3 + 8*Pi*r^2)^2*(g^3 + r^3)^2)/(36*r^4*xi^(1/3)) + xi^(1/3);
shadowrad = photonrad/Sqrt[met[photonrad]] /. r -> rh;
plot = Region[ParametricRegion[{shadowrad*Cos[\[Theta]],
shadowrad*Sin[\[Theta]]}, {{\[Theta], 0, 2*Pi}, {T, T1, T2}}]];
plot]
shadowcontour[f, 0.3, 0.002418/0.09, 0, 0.21]
now perfomrfing shadowcontour[f, 0.3, 0.002418/0.09, 0, 0.21] gives no answer. Can anyone help me with it.
fsomewhere, and parametersgandPare defined yet in another place. I think you will get better answers if you prepare a single copy-paste-able code. $\endgroup$