Beispiel #1
0
        public static void calcHouses(ref float[] houses, AstroDefs.planet_positions positions, int houseSystem, float latitude, float longitude)
        {
            float localSideral = (float)calculateLocalSideral(positions.gmt0sideralTime, positions.gmtTime, longitude);

            switch (houseSystem)
            {
            case HOUSES_NULL:
                calcHousesNULL(ref houses);
                break;

            case HOUSES_EQUAL_ASC:
                calcHousesEqualASC(ref houses, positions.ascendant);
                break;

            case HOUSES_WHOLE_VEDIC:
                calcHousesWholeVedic(ref houses, positions.ascendant);
                break;

            case HOUSES_PORPHYRY:
                calcHousesPorphyry(ref houses, positions.ascendant, positions.mediumCoeli);
                break;

            case HOUSES_PLACIDUS:
                calcHousesPlacidus(ref houses, positions.ascendant, positions.mediumCoeli, localSideral, latitude);
                break;

            case HOUSES_KOCH:
                calcHousesKoch(ref houses, positions.ascendant, positions.mediumCoeli, localSideral, latitude);
                break;

            default:
                calcHousesNULL(ref houses);
                break;
            }
        }
Beispiel #2
0
        public static void calcAscAndMc(ref AstroDefs.planet_positions pos, float latitude, float longitude)
        {
            float localSideral = (float)calculateLocalSideral(pos.gmt0sideralTime, pos.gmtTime, longitude);
            float asc          = ascendantFromSideralLatitude(localSideral, latitude);
            float mc           = mediumCoeliFromSideral(localSideral);

            if (!mcAboveAsc(mc, asc))
            {
                if ((latitude > 66) || (latitude < -66))
                {
                    // We assume this is due to the weird behaviour of the
                    // ascendant in the far north (/south ?):
                    // We turn the ascendant around 180 degrees,
                    // some say we should also turn medium coeli
                    asc = AstroDefs.filter360(asc + 180);
                }
                else
                {
                    //throw new AstroException("Something wrong with ascendant calculation!");
                    // -----------------
                    // Hmmm for Hillary Clinton, turning the MC around seems to fix the deal...
                    mc = AstroDefs.filter360(mc + 180);
                    //return; // do nothing
                }
            }
            pos.ascendant   = asc;
            pos.mediumCoeli = mc;
        }