Like what does this function do? const RAD = Math.PI / 180; const dayMs = 86400000; const J1970 = 2440588; const J2000 = 2451545; function q0(v) { return (v.getTime() / dayMs - 0.5 + J1970) - J2000; } function q1(t) { const a = RAD * (357.5291 + 0.98560028 * t); const b = RAD * ( 1.9148 * Math.sin(a) + 0.02 * Math.sin(2 * a) + 0.0003 * Math.sin(3 * a) ); const c = RAD * 102.9372; return a + b + c + Math.PI; } function q2(t) { const a = RAD * (218.316 + 13.176396 * t); const b = RAD * (134.963 + 13.064993 * t); return a + RAD * 6.289 * Math.sin(b); } export function x7(v = new Date()) { const a = q0(v); const b = q2(a) - q1(a); const c = ((b % (2 * Math.PI)) + 2 * Math.PI) % (2 * Math.PI); return c / (2 * Math.PI); } export function x8(v = new Date()) { const a = x7(v); return (1 - Math.cos(a * 2 * Math.PI)) / 2; } submitted by /u/Low-Sign9973
Originally posted by u/Low-Sign9973 on r/ArtificialInteligence
