NAME

AnglePlanetStar

Return the difference in degrees between the zodiac longitude of a planet and the zodiac longitude of a star in the current horoscope.

USAGE

AnglePlanetStar nPlanet idStar

PARAMETERS

nPlanet:

Is the number of the planet

idStar:

Is the id (HR Number) of the star from the Bright Star Catalog

OPTIONS

None

RETURN

Return the difference angle (between 0 and 180°) in decimal degrees

Remark

You can use the FormatAngle function to get an 99°99'99" string from the returned decimal value.

EXAMPLE

set orb 1
PutTxt "***************** Stars conjunction with planets orb $orb° **************"
set n_stars [GetStarsCount]
for {set i 0} {$i < $n_stars} { incr i} {
 for { set p 0 } { $p < 15 } { incr p} {
  set idStar [IdStarConjunctionWithPlanet $p $i $orb]
  if { $idStar != -1 } {
    # NameOfStar and CommentOfStar take the position of the star in the list as argument (the "internal number") not the IdStar (HR Number)
    PutTxt "[NameOfPlanet $p] conjunction with star $idStar [NameOfStar $i] [CommentOfStar $i] "
    set orb_conjunction [AnglePlanetStar $p $idStar]  
    PutTxt "Orb: [FormatAngle $orb_conjunction]"
   }
 }
}

Output

***************** Stars conjunction with planets orb 1° **************
Moon conjunction with star 804 Gamma Cetus Kaffaljidhma 
Orb: 0°09'21"
Moon conjunction with star 874 Eta Eridanus Azha 
Orb: 0°34'59"
Rahu conjunction with star 1409 Epsilon Taurus Ain 
Orb: 0°23'21"
....