* * * *的目的我的问题:我创建程序计算太阳辐射和我需要计算太阳和地球之间的半径。这本书基于“指南HTML、JavaScript和PHP”科学家和工程师,由大卫·r·布鲁克斯。代码来自这个[链接][1]这是一个计算器。我编辑的代码c * *半径计算* *在我的代码半径计算被定义为“o - > R = 1.000001018 * (1.0 - e * e) / (1.0 + e * cos (f));“* e *——地球轨道的偏心率:* f * -太阳真异常:空白getSolarPosition(输入*我,SOLPOS * o){如果(!我- > JulianDate) - > JulianDate = getJulianDate(我);/ /日期必须设置计算朱利安日期双degRad = 0.017453292519943295769236907684886;/ /π/ 180.0 / / 2451545.0 - 1月1日,2000年,在12:00:00 UT双T =(我- > juliandate - 2451545.0) / 36525.0;/ / L0——太阳的几何平均数经度:双L0 T + 0.0003032 = 280.46645 + 36000.76983 * * T * T;/ / M -意味着太阳异常:双M = 357.52910 + 35999.05030 * 0.0001559 * T * T - 0.00000048 T - T * T * T *;双M_rad = M * degRad;/ / e -地球轨道的偏心率:双e = 0.016708617 - -0.000042037 * 0.0000001236 T - * T * T; // C - sun's center double C=(1.914600-0.004817*T-0.000014*T*T) * sin(M_rad) +(0.019993-0.000101*T)*sin(2.*M_rad)+0.000290*sin(3.*M_rad); double L_save=(L0+C)/360.; // L_true - True longitude of the sun double L_true; if (L_save < 0.) L_true = (L0+C) - ceil(L_save)*360.; else L_true = (L0+C) - floor(L_save)*360.; if (L_true < 0.) L_true+=360.; // f - true anomaly of the sun: double f = M_rad + C * degRad; // Earth-sun distance: o->R =1.000001018*(1.0-e*e)/(1.0+e*cos(f)); // Sidereal time (Theta0) double Sidereal_time=280.46061837+ 360.98564736629*( i->JulianDate-2451545.) + 0.000387933*T*T - T*T*T/38710000.; // Replacement code for Sidereal=fmod(Sidereal,360.) double S_save=Sidereal_time/360.; if (S_save < 0.) Sidereal_time=Sidereal_time-ceil(S_save)*360.; else Sidereal_time=Sidereal_time-floor(S_save)*360.; if (Sidereal_time < 0.) Sidereal_time+=360.; // Obliquity - Axial tilt - is an astronomical term describing the angle of tilt of the Earth's axis of rotation. o->obliquity=23.0+26./60.+21.448/3600.-46.8150/3600.*T-0.00059/3600.*T*T + 0.001813/3600.*T*T*T; // right_ascension: tan(alpha) o->right_ascension = atan2(sin(L_true*degRad)*cos( o->obliquity*degRad ), cos(L_true*degRad)); // declination: sin(delta) o->declination = asin(sin( o->obliquity*degRad )*sin(L_true*degRad)); // hour angle H of the sun with respect to the observer's longitude Lobs o->hour_angle=Sidereal_time + i->lon - o->right_ascension / degRad; o->elevation = (asin(sin( i->lat*degRad )*sin( o->declination)+cos(i->lat*degRad)*cos( o->declination )*cos( o->hour_angle*degRad )))/degRad; // Solar Zenit Angle o->Z = 90.-o->elevation; } This is function to calculate solar position. It works exactly the same as Bird and Hulstrom's Solar Irradiance Model refered the calculator (see link above). Here I use *i* input object where input data are are saved and *o* ouput object where the calculated data regarding solar position are saved after they are calculated. atan2 - Returns the principal value of the arc tangent of y/x, expressed in radians (whatever it means, this is taken from C/C++ manual - - I am not mathematician ). The problem is that if I set old date like **1849**/06/31 11:15 The Solar constant corrected to Radius does not fit the [historical records][2]. In the case the result would 1322.3 be for SolConst 1367. Which is crazy. According historical data it should be 1361.035. So I expect the radius is wrong calculated. I would like to ask you: 1) where can I get historical records of the sun-earth radius 2) what is wrong with this formula or this calculation? Can you suggest better formula? [1]: http://www.instesre.org/Solar/BirdModelNew.htm [2]: http://lasp.colorado.edu/lisird/tsi/historical_tsi.html