function res=planck(x)
k=1.3806*1.e-23;
c=3.e8;
h0=6.6262*1.e-34;
T=290;
%T=5785;
x=x*1.e-9;
res0=2*pi*c^2*h0.*x.^-5./(exp(h0*c./(k*T.*x))-1);

r=6.96*1.e8/(149.6*1.e9);
res=r.^2*res0;