shmodot/scripts/orbits/math/IEllipseExtensions.cs

8 lines
204 B
C#

using Vim.Math3d;
using System;
public static class IEllipseExtensions
{
public static DVector2 GetPosition(this IEllipse e, double t) =>
new DVector2(Math.Cos(t) * e.a, Math.Sin(t) * e.b);
}