Module: AstroChart::Draconic
- Defined in:
- lib/astro_chart/draconic.rb
Overview
Draconic chart (龍盤): the tropical zodiac rotated so the natal True North Node sits at 0° 牡羊. Every ecliptic longitude is shifted by the node's longitude, which re-signs the whole chart around the lunar nodal axis. Widely read as the "soul level" overlay of the ordinary tropical chart.
draconic_longitude = (L − 北交點) mod 360
Pure composition: this only transforms longitudes. Feed it the raw
positions hash from Planets.calculate_positions (or any { name => L }
hash) together with the natal True North Node longitude.
Class Method Summary collapse
-
.chart(positions, north_node) ⇒ Object
Full draconic view: draconic longitude, zodiac sign and in-sign degree for every body, plus the aspects among them (major aspects only, via Aspects.calculate — draconic-to-draconic contacts are identical to the tropical ones, but the signs and houses they fall in differ).
-
.positions(positions, north_node) ⇒ Object
positions: { "太陽" => 123.45, ... } tropical ecliptic longitudes north_node: True North Node longitude (degrees, 0-360).
Class Method Details
.chart(positions, north_node) ⇒ Object
Full draconic view: draconic longitude, zodiac sign and in-sign degree for every body, plus the aspects among them (major aspects only, via Aspects.calculate — draconic-to-draconic contacts are identical to the tropical ones, but the signs and houses they fall in differ).
Returns:
{ "planets" => [ { "planet" =>, "zodiac" =>, "degree" =>,
"total_degree" => }, ... ],
"aspects" => [ { "a_planet" =>, "b_planet" =>,
"aspect_type" =>, "orb" => }, ... ] } # sorted by orb
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# File 'lib/astro_chart/draconic.rb', line 34 def self.chart(positions, north_node) draconic = self.positions(positions, north_node) planets = draconic.map do |name, lon| { "planet" => name, "zodiac" => Zodiac.sign_name(lon), "degree" => (lon % 30).round(4), "total_degree" => lon.round(4), } end names = draconic.keys aspects = [] names.combination(2) do |a, b| type, orb = Aspects.calculate(draconic[a], draconic[b]) next if type.nil? aspects << { "a_planet" => a, "b_planet" => b, "aspect_type" => type, "orb" => orb, } end aspects.sort_by! { |asp| asp["orb"] } { "planets" => planets, "aspects" => aspects } end |
.positions(positions, north_node) ⇒ Object
positions: { "太陽" => 123.45, ... } tropical ecliptic longitudes north_node: True North Node longitude (degrees, 0-360)
Returns { name => draconic_longitude } with 北交點 mapped to 0.0.
20 21 22 |
# File 'lib/astro_chart/draconic.rb', line 20 def self.positions(positions, north_node) positions.transform_values { |lon| (lon - north_node) % 360.0 } end |