Primary Directions - the perspective of a software developer

1
Hi there,

I'm currently rewriting the Primary Directions module of my software (skyPlux), which had some errors. Unfortunatelly, it seems that other software that I'm trying to compare my calculations to, also have their share of errors.

So, I've decided to be more carefull about testing all the formulas and try to simplify some of the equations. Since there is not much information about the calculation of Primary Directions ("modern" sources, that is) besides Martin Gansten's book, I've decided to make some blog posts on how I'm implementing the calculations of Primary Directions on skyPlux.

The first blog post is at http://skyplux.wordpress.com/2013/04/20 ... rnal-arcs/ where I talk about diurnal and nocturnal arcs which I consider the basis for calculating PDs.

I hope this information helps people understand better the Primary Directions calculation..


Regards,
Jo?o Ventura

(I hope this is the right section for posting this information, if not, can a moderator move it?)

2
From the perspective of a software developer, it is possible to calculate all primary directions in all house systems (Placidus, Topocentric, Koch, Alchabitius, Campanus, Regiomontanus, etc.) correctly and accurately by means of a simple, single algorithm valid for all of them, based on the well-known but not well-understood concept of "mundoscope".

With this universal and simplified approach, all the different and complicated formulas corresponding to each domification system are not necessary; it is only necessary to calculate the "in mundo" (or "mundoscope") position correctly, and the algorithm will find through successive approximations the arc of direction on the equator that satisfies the mundane relationship that corresponds to every single direction.

A lot of the mathematical complication and the frequent errors involved in the calculation of primary directions are avoided this way.

With the help of Roberto Luporini from Italy I have implemented this approach in my freeware program "Riyal". This program now calculates correctly primary directions in the systems of Placidus (semiarc), Campanus, Regiomontanus, or Topocentric, without the need of a separate set of formulas for each system, using a simple iterative algorithm based on the mundoscope positions.

All the other house systems are also implemented (Koch, Morinus, Alchabitius...), including the simple ones like Porphyry and EqualHouse. The problem is that it is very difficult to find sources with which to compare the results because these additional or alternative systems of primary directions are practically neglected, or have never been explored. So the results of these additional systems are still in an "experimental" phase.

A "mundoscope" double-wheel with correctly calculated mundo positions is all that is needed to calculate primary directions, as has been explained in this forum before by Roberto Luporini:

http://skyscript.co.uk/forums/viewtopic.php?t=6500
http://skyscript.co.uk/forums/viewtopic ... c&start=15

One wheel shows the radix mundo positions, while the second wheel shows the "rotated" (converse or/and direct) positions corresponding to any desired date. This method valid for a single date is complemented by the universal successive approximations method that finds all the possible directions in a lifetime.

http://www.expreso.co.cr/centaurs/riyal.html

Juan

5
While a single algorithm to fit most calculations might be possible, it is almost certainly going to be a process killer on the PC's clock when repeated for many cycles causing calculations to be slow. To fix this, one would need to shorten the span of time for which the users want calculations. The alternative would be to optimize each algorithm for speed which means that you are going to end up with more than one. Primary directions are calculation intensive which means that any serious software ought to have a progress bar and a cancel button for selections that exceed the users patience.

The best way to make sure there are no errors is to test the algorithms and include debug info with the application. However I would say many errors come about from those not well schooled in primary directions trying to get a certain result with incorrect options. For this reason, PD's just are not for beginners. Study and practice is essential if you hope to know what you are looking at.
Curtis Manwaring
Zoidiasoft Technologies, LLC

6
carriere.francois wrote:Hi,

Is this commercial or freeware astrology software?
Juan wrote:With the help of Roberto Luporini from Italy I have implemented this approach in my freeware program "Riyal". This program now calculates correctly primary directions in the systems of Placidus (semiarc), Campanus, Regiomontanus, or Topocentric, without the need of a separate set of formulas for each system, using a simple iterative algorithm based on the mundoscope positions.
let's hope that "freeware" IS free!

Johannes

7
While a single algorithm to fit most calculations might be possible, it is almost certainly going to be a process killer on the PC's clock when repeated for many cycles causing calculations to be slow. To fix this, one would need to shorten the span of time for which the users want calculations. The alternative would be to optimize each algorithm for speed which means that you are going to end up with more than one. Primary directions are calculation intensive which means that any serious software ought to have a progress bar and a cancel button for selections that exceed the users patience.
I believe the wiser manner to judge something is to watch it, first of all. On my PC, Riyal V3.9.8.2 (the last) shows me all the chosen mundane PDs within 3 seconds after I pressed the Enter key. Of course with a friendly progress bar that covers in the same time its path.
However I would say many errors come about from those not well schooled in primary directions trying to get a certain result with incorrect options.
And as I see, all the arcs of directions are perfect.
For this reason, PD's just are not for beginners. Study and practice is essential if you hope to know what you are looking at.
Better to say: for these reasons beneath the Juan's algorithm there is something that till now no one believed possible, and for these reasons the current knowledge of the PDs is not enough to understand it. Unless further study and practice, of course.

Roberto

8
zoidsoft wrote:While a single algorithm to fit most calculations might be possible, it is almost certainly going to be a process killer on the PC's clock when repeated for many cycles causing calculations to be slow.
It is actually very fast. Speed is not an issue. Since it is an iterative algorithm, the main issue that must be solved is that of convergence.
However I would say many errors come about from those not well schooled in primary directions trying to get a certain result with incorrect options. For this reason, PD's just are not for beginners. Study and practice is essential if you hope to know what you are looking at.
It is not possible to write original code unless you know what you are doing, there is nobody to copy from. But only a basic understanding of primary directions is recquired, what is crucial is a good understanding of the astronomical basis of a mundoscope. This then provides the basis for writing the universal algorithm.

As it is now, the same algorithm calculates correctly all the directions for latitudes below 66.5 in the Placidus semiarc, Regiomontanus, and Campanus systems. This result demonstrates or proves that a mundoscope in one of the 3 systems mentioned provides an accurate representation or modelling of "classical" Primary Directions, without the need of specific or complicated formulations for each system, except what is needed to calculate the mundo position.

Work with other house systems as well as directions under the pole and in zodiaco is in progress. These variations affect the choices or options that are fed (or that --possibly-- cannot be fed) to the algorithm, but not the algorithm itself, which has already shown its efficiency and accuracy, as well as demonstrating a practical value of the mundoscope not sufficiently explored by the practitioners of primary directions.

Juan

9
robhywolf wrote: I believe the wiser manner to judge something is to watch it, first of all. On my PC, Riyal V3.9.8.2 (the last) shows me all the chosen mundane PDs within 3 seconds after I pressed the Enter key. Of course with a friendly progress bar that covers in the same time its path.
Roberto
With what selections? I can get PD's within 0.1 sec on some programs, but this is meaningless without knowing what options and for how many years you are calculating. Accurate benchmarking will require these to be spelled out.
Curtis Manwaring
Zoidiasoft Technologies, LLC

10
johannes susato wrote:let's hope that "freeware" IS free!
Johannes
Riyal has always (since first issued in 1999) and will always be free.

As it is now it can be used safely for Placidus semiarc, Campanus, and Regiomontanus directions.

The directions are calculated according to the house system and using an universal agorithm as explained.

Nevertheless, nothing is perfect, so I hope users will report any errors found.

The other systems of direction are also included but the results must be considered --for the moment-- experimental (I'm currently working on Topocentric).

Juan

11
zoidsoft wrote:With what selections? I can get PD's within 0.1 sec on some programs, but this is meaningless without knowing what options and for how many years you are calculating. Accurate benchmarking will require these to be spelled out.
All arcs of direction direct and converse of 10 planets with the classical aspects plus the quincunx to an accuracy of 0.001 degrees from zero to 180 degrees are calculated, but only arcs smaller than 100 degrees are shown. At very high latitudes and in the Campanus case it takes a little longer, but never more than about 5 seconds (in my desktop computer with 2.2 Gz clock speed).

Progress in calculation is shown by cumulative number of directions<100 degrees. The delay represented in the progress bar is caused by the Windows OS creating the texted windows where the results are displayed. The process is always fast so there is no need to abort.

Juan

12
Juan wrote: Windows OS creating the texted windows where the results are displayed. The process is always fast so there is no need to abort.

Juan
There will be a need for a progress bar / cancel once you start doing calculation spans beyond one full circle or have the array of direction types that you see with Janus, include fixed stars, etc...
Curtis Manwaring
Zoidiasoft Technologies, LLC