Public
Edited
Jan 17, 2024
1 fork
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
ellipse_path_svg = (coords) => {
const svg = d3.create("svg")
.attr("viewBox", [0, 0, width, height]);

var xRange = margin.left + (height - margin.right - margin.left)/2;
var yRange = margin.top + (height - margin.bottom - margin.top)/2;

var yOffset = `translate(${xRange}, 0)`;
var xOffset = `translate(0, ${yRange})`;
var xyOffset = `translate(${xRange},${yRange})`;
var yAxis = svg.append("g").attr("transform", yOffset)
.call(d3.axisLeft(y).tickValues([]).tickSizeOuter(0));
var xAxis = svg.append("g").attr("transform", xOffset)
.call(d3.axisBottom(x).ticks(3));
var orbit = svg.append("g").append("path")
.attr("fill", "none")
.attr("stroke", "black")
.attr("stroke-width", 2)
.attr("d", ellipse_path_string(coords));

return svg.node();
} // A 30 50 -45 0 1 215.1 109.9
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
E_plutoish = E_f(0.2488, l(1.303e22, 1.425e11,theta_dot(90560*24*60*60)), 1.303e22, mu)
Insert cell
E_earth = E_f(0.0167086, l(5.972e24, 150000000,theta_dot(365*24*60*60)), 5.972e24, mu)
Insert cell
l_earth = l(5.972e24, 150000000, theta_dot(365*24*60*60))
Insert cell
E_f = (e, l, m, mu) => {
return (e**2 - 1) * (m**3 * mu**2)/(2 * l**2) + (2*(l**2)) ;
}
Insert cell
l = (m, r, theta_dot) => {
return m * (r**2) * theta_dot;
}
Insert cell
theta_dot = (sid_period) => {
return 360/sid_period;
}
Insert cell
Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more