Package | Version | Description | Licence |
---|---|---|---|
SharpAstrology.Base | 0.10.0 | Base library | MIT |
SharpAstrology.SwissEph | 0.2.2 | Ephemerides package based on SwissEphNet | AGPL-3.0 |
SharpAstrology.HumanDesign | 1.1.0 | Extensions for the Human Design system | MIT |
SharpAstrology.HumanDesign.BlazorComponents | 0.2.1 | Human Design charts as Blazor components | MIT |
SharpAstrology.Vedic | 0.1.0 | Extensions for Vedic astrology systems | MIT |
SharpAstrology.West | 0.1.0-preview.4 | Extensions for western astrology systems | MIT |
SharpAstrology.West.BlazorComponents | 0.1.0-preview.1 | Western astrology charts as Blazor components | MIT |
In Western astrology, the distances between planets are assigned certain aspects. Each planet is assigned a certain range, an orbit. This package provides an OrbitBuilder to define these orbits freely.
using SharpAstrology.DataModels;
using SharpAstrology.Enums;
using SharpAstrology.Ephemerides;
using SharpAstrology.ExtensionMethods;
using SharpAstrology.Utility;
var date = new DateTime(1988, 9, 4, 1, 15, 0, DateTimeKind.Utc);
using var eph = new SwissEphemeridesService("[PATH_TO_EPHEMERIDES_FILES]").CreateContext();
// create chart
var chart = new AstrologyChart(date, eph);
// Aspects with default western orbits
var aspect = chart.AspectBetween(Planets.Sun, Planets.SouthNode);
Console.WriteLine(aspect);
// Output: Conjunction
// Use default western orbits explicitly
var orbitBuilder = OrbitBuilder.WithWesternDefaultOrbits();
var orbits = orbitBuilder.Build();
aspect = chart.AspectBetween(Planets.Sun, Planets.SouthNode, orbits);
Console.WriteLine(aspect);
// Output: Conjunction
// Change specific orbit definitions
orbitBuilder.SetRule(Aspects.Conjunction, Planets.Sun, 1);
orbitBuilder.SetRule(Aspects.Conjunction, Planets.SouthNode, 1);
orbits = orbitBuilder.Build()
aspect = chart.AspectBetween(Planets.Sun, Planets.SouthNode, orbits);
Console.WriteLine(aspect);
// Output: None
using SharpAstrology.DataModels;
using SharpAstrology.Enums;
using SharpAstrology.Ephemerides;
using SharpAstrology.ExtensionMethods;
using SharpAstrology.Utility;
var date = new DateTime(1988, 9, 4, 1, 15, 0, DateTimeKind.Utc);
using var eph = new SwissEphemeridesService("[PATH_TO_EPHEMERIDES_FILES]")
.CreateContext();
// create chart
var chart = new AstrologyChart(date, eph);
// Define orbits with json string
var orbitBuilder = OrbitBuilder.FromJsonString("""
{
"conjunction": {
"sun": 10,
"southnode": 8,
"moon": 10
}
}
""");
var orbits = orbitBuilder.Build();
Console.WriteLine(chart.AspectBetween(Planets.Sun, Planets.SouthNode, orbits));
//Output: Conjunction
Console.WriteLine(chart.AspectBetween(Planets.Moon, Planets.SouthNode, orbits));
//Moon: None
// Will throw NotSupportedException, because Jupiter is not given in orbit table.
Console.WriteLine(chart.AspectBetween(Planets.Jupiter, Planets.Sun, orbits));
{
"aspect": {
"planet": 123,
"planet": 123,
...
},
"aspect": {
"planet": 123,
"planet": 123,
...
},
...
}
Planets | json | Aspects | json |
---|---|---|---|
Planets.Sun | sun | Aspects.Conjunction | conjunction |
Planets.Moon | moon | Aspects.Opposition | opposition |
Planets.Mercury | mercury | Aspects.Square | square |
Planets.Venus | venus | Aspects.Trine | trine |
Planets.Mars | mars | Aspects.SemiSextile | semisextile |
Planets.Jupiter | jupiter | Aspects.Quincunx | quincunx |
Planets.Saturn | saturn | Aspects.Quintile | quintile |
Planets.Uranus | uranus | ||
Planets.Neptune | neptune | ||
Planets.Pluto | pluto | ||
Planets.NorthNode | northnode | ||
Planets.SouthNode | southnode | ||
Planets.Chiron | chiron | ||
Planets.Earth | earth |
SharpAstrology offers a package that allows you to visualize your AstrologyChart via a Blazor component. See the project SharpAstrology.West.BlazorComponents.