Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some functions relevant for astrological usage #42

Closed
rstub opened this issue Mar 31, 2019 · 18 comments

Comments

@rstub
Copy link
Owner

commented Mar 31, 2019

Feature request from SE's mailing list:

I would love to be able to use Lahiri Ayanamsa as well as play with mean v. true node setting (what is called Rahu/Ketu in the Indian system).

The first part is probably from section 10, which we have not covered so far. Not sure about the second part.

@rstub rstub added the enhancement label Mar 31, 2019

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Mar 31, 2019

A few others things that we need to rectify:
. mention somewhere that the SE C-code is based on version "2.07.01"?
. perhaps we need to say that we have version 2.07.01_R (as it has some changes to 2.07.01)
. a few 'argument' lines in swephR.pdf are truncated (as they are the long). Need to change the layout.
. I have asked what precisely Rahu/Ketu means in SE function.

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Mar 31, 2019

. mention somewhere that the SE C-code is based on version "2.07.01"?

Where would you like to mention this? Currently it can be seen indirectly in the README and in the Section1 help page.

. perhaps we need to say that we have version 2.07.01_R (as it has some changes to 2.07.01)

I don't think that is necessary. The changes do not affect SE's functionality. Actually, I would consider it a serious bug if there is any difference in the calculations using swephR as compared to the official test program.

. a few 'argument' lines in swephR.pdf are truncated (as they are the long). Need to change the layout.

Indeed.

. I have asked what precisely Rahu/Ketu means in SE function.

Good idea. Indian astrology is not my strongest subject ;-)

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Apr 4, 2019

I need to setup my RStudio and vignette software on this new PC (which I am slowly doing, missing the workflow I used when doing that in the past;-). In the meantime I lost my main account on the PC, so need to go back to my work LAN support.
The version number, I think, is missing as a definite number aka from which it was related. Of course one can do swe_version() but that might be a little indirect indeed. We are indeed now directly related to 2.07.01 (of SE) and i think it is worth mentioning somewhere explicitly.

The compiled version 2.07.02 (using minGW) does not work under VBA (Windows Visual Basic), but the compiled version 2.07.01_PFa does work for VBA;-). That is why I was thinking to give the R-compilation another number (as it is not really 2.07.01): that is why I was thinking to give it +"_R": to show it is a derivative of the SE .
So this is not related to different outcome, but just a different compiler method.

I still don't know what Rahu/Ketu means (will prompt the feature requester again)

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jun 6, 2019

From Wikipedia

Astronomically, Rahu and Ketu denote the points of intersection of the paths of the Sun and the Moon as they move on the celestial sphere. Therefore, Rahu and Ketu are respectively called the north and the south lunar nodes. The fact that eclipses occur when the Sun and the Moon are at one of these points gives rise to the understanding of swallowing of the Sun and the Moon by the snake. Rahu is responsible for causing the Eclipse of the Sun.

@vreijs That sounds like something SE should be able to calculate, right?

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 9, 2019

I thin k these Rahyu and Ketu are already part of SE, I just need to code it. The problem is at this moment that we are very busy (at least in our minds0 with selling our house and then buying a new one. The selling might happen next week (after that I will be more at ease...). I also need to install git and link with RStudio (need to see if I have that workflow still somewhere archived).

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jun 10, 2019

Good luck with that! Let me know if you need any assistance.

Concerning Rahyu and Ketu: Do we even have to code anything for that? I have come to the impression that mean and true lunar node can be calculated with swe_calc(_ut) by setting ipl to SE_MEAN_NODE = 10 or SE_TRUE_NODE = 11. I am not sure if this represents the north or south lunar node, though. The other one would be directly opposite.

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 10, 2019

I think no code is needed, I meant to say that the R-wrappers need to be made.

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 27, 2019

Working on the code, but even the simplest is causing me problems. I have this code, but it does not compile:
//' @details
//' //' \item{swe_get_ayanamsa_name()}{Get the mode name for sidereal computations.}
//' }
//' @param sidmode Sidereal mode as integer
//' @return \code{swe_get_ayanamsa_name} returns name of Ayaname method
//' //' @examples
//' swe_get_ayanamsa_name(SE$SIDM_FAGAN_BRADLEY)
//' @rdname Section10
//' @export
// [[Rcpp::export(swe_get_ayanamsa_name)]]
std::string get_ayanamsa_name(int sidmode) {
std::array<char, 256> sidstring{{'\0'}};
sidstring = swe_get_ayanamsa_name(sidmode);
return std::string(&sidstring[0]);
}

I have void set_sid_mode(int sid_mode, double t0, double ayan_t0) done, but that was also simple. Will now start working on the swe_get_ayanamsa_ex_ut(), swe_get_ayanamsa_ex()
With these, the feature request should be covered...

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 27, 2019

I have the above function in the \astrology thread (but one line is not functioning... (so I commented it out, but of course that does not help solving;-) Hope you can help.

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jun 27, 2019

Can you push your changes?

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 27, 2019

I did indeed, so it is in /astrology

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jun 27, 2019

Strange. I see only one commit on https://github.com/rstub/swephR/tree/vreijs/astrology, and that one is three days old.

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 27, 2019

Grrr... it might be because I did the changes on my new computer (i thought it was configured it well, as I saw no errors when committing, etc.) But seems not to work. Lets leave this new computer for now and I will soon copy the changed files to my old computer and see if that then works.

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jun 27, 2019

Just to double check: You did use "Push" after "Commit", right?

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 27, 2019

Is it now better (I indeed forgot the "push"!).

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jun 27, 2019

Ok, I have fixed a few minor things. Do you want to open a PR?

@vreijs

This comment has been minimized.

Copy link
Collaborator

commented Jun 28, 2019

@rstub

This comment has been minimized.

Copy link
Owner Author

commented Jul 4, 2019

Fixed by #48

@rstub rstub closed this Jul 4, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.