Hello!
Does anybody know of a cleaner, more beautiful way of calculating prayer
times than this https://gist.github.com/1ce3aecf39eef59e9223?
It’s a rewrite of prayertime.rb, although I don’t think it looks any
better.
People tell me that calculating prayer times is crazy confusing and
irrational and therefore simply ugly by nature, but I refuse to believe
this. There’s gotta be a better way?
I don’t mind the code consisting of more lines if that means it’s more
structured and easier to read by beginners, as opposed to shorter but
more
cryptic and dense looking.
–Dwayne
Hey Dwayne,
I have not studied your code but the concept is interesting. I am going
to give it a run here soon.
Cheers
On Tue, Oct 4, 2011 at 8:12 PM, Lake D. [email protected] wrote:
Hey Dwayne,
I have not studied your code but the concept is interesting. I am going to
give it a run here soon.
Cheers
Sounds great man, I really appreciate it.
I just found some really decent sample code at
Code - Pray Times -
but unfortunately no Ruby version.
The goal would be to make something as gorgeous as the Jewish version:
https://gist.github.com/e8bab23af5346bc2c830
–Dwayne
On Tue, Oct 4, 2011 at 1:02 PM, Dwayne H.
<[email protected]
wrote:
I don’t mind the code consisting of more lines if that means it’s more
structured and easier to read by beginners, as opposed to shorter but more
cryptic and dense looking.
–Dwayne
You’d probably get more help if your question was more general. As is,
I’m
not a Muslim, so I have no idea what the actual problem even is. I
glanced
at the code, but there were foreign words in it, so I figure it’d take a
lot
of effort to figure it out.
A preliminary guess would be that it has something to do with time
zones,
but then looking at the code I see it has something to do with seasons,
so
who knows.
If you can express it in a general enough sense that everyone can
understand
it, then the chances of finding help will increase significantly.
The calculations in my script are incorrect. They don’t support higher
latitudes and give wrong isha and fajr times in some cases.
–Dwayne
On Wed, Oct 5, 2011 at 2:00 AM, Josh C. [email protected] wrote:
If you can express it in a general enough sense that everyone can
understand
it, then the chances of finding help will increase significantly.
Good point Josh, my bad.
So to rephrase: Does anybody know a better way of calculating prayer
times
in Ruby than https://gist.github.com/1ce3aecf39eef59e9223? A full
explanation of the process can be found here:
http://praytimes.org/calculation
Much obliged!
–Dwayne
On Wed, Oct 5, 2011 at 2:00 AM, Josh C. [email protected] wrote:
If you can express it in a general enough sense that everyone can
understand
it, then the chances of finding help will increase significantly.
Did you actually want to help?
–Dwayne
On Thu, Oct 6, 2011 at 2:28 PM, Dwayne H.
<[email protected]
wrote:
Did you actually want to help?
–Dwayne
I like to look at problems people post. I’ll help if they are easy to
grasp
and obvious (ie it is easy to help them), or if they are interesting
problems (ie I’m personally compelled to solve the problem). This isn’t
obvious enough for me to want to take a stab at it, and I don’t
understand
it enough to know whether it’s interesting.
Generally, answering questions or making suggestions (ie about how you
could
make it easier for people to help you) doesn’t constitute obligation
from
me. If I wanted to obligate myself to something, it would probably be
Shoes
or Sinatra, something that I’ve benefited from and that gives back to
the
community.