al-azan icon indicating copy to clipboard operation
al-azan copied to clipboard

Add more calculation methods

Open TorCzaf opened this issue 1 year ago • 54 comments

Hi , can you please add more calculation methods like: -Ministry of religious affairs - Tunisia -Ministry of Islamic affairs - Morocco -Ministry of religious affairs and wakfs - Algeria -London unified prayer times -Jabatan kemajuan Islam - Malaysia -Mosquee de Paris - France -Angle 18° France -Angle 15° France

And maybe there is more.

====

And also it would be good to add a button to share the app via Bluetooth in case if the sender and the receiver both have no WiFi/internet. I took this idea from F-droid store itself. This could be useful for people who travel in desert or in unknown places or be in unpopular areas...ETC

TorCzaf avatar Jul 06 '23 16:07 TorCzaf

Hi

-Ministry of religious affairs - Tunisia -Ministry of Islamic affairs - Morocco -Ministry of religious affairs and wakfs - Algeria -London unified prayer times -Jabatan kemajuan Islam - Malaysia -Mosquee de Paris - France -Angle 18° France -Angle 15° France

Can you provide link to the official page of these methods ? so I can take their exact parameters ? We can also add a "Custom" method which will allow users to enter their own angles

And also it would be good to add a button to share the app via Bluetooth in case if the sender and the receiver both have no WiFi/internet.

Some android manufactures already have this feature built-in to the OS some of file managers do as well if you have the file, all new android OS (Android 6+) also have the "Nearby Share" feature which allows you to send files without internet using WiFi or bluetooth to any device near you that also has the feature.

meypod avatar Jul 07 '23 00:07 meypod

Can you provide link to the official page of these methods ? so I can take their exact parameters ? We can also add a "Custom" method which will allow users to enter their own angles

I will see how or where to get these links or parameters.... Yes good idea to provide a custom method for entering angles

Some android manufactures already have this feature built-in to the OS some of file managers do as well if you have the file, all new android OS (Android 6+) also have the "Nearby Share" feature which allows you to send files without internet using WiFi or bluetooth to any device near you that also has the feature.

Yes I just found out that Google play has nearby share but they collect data that is not good for privacy, plus Google play nearby share doesn't share apps from F-droid, I only found the apps that I downloaded from google play.

There is also nearby share in the phone settings that also collects data plus it may not work for all regions https://support.google.com/files/answer/10514188?hl=en#zippy=%2Chow-nearby-share-handles-your-data

I think it is better to make and put a nearby share feature into your app :) (just for sharing your app offline) just like F-droid did, you can have a look at their source code and see how they did it in case you need to.... it would be really good idea.

if you have the file

You mean APK?

I meant sharing the app itself in case the sender doesn't have the APK file

TorCzaf avatar Jul 07 '23 02:07 TorCzaf

You mean APK?

yeah I meant APK

I prefer to let third party apps handle it. I'm pretty sure there's a lot of apps you can use to get the APK file. check this app for example, I just found it: https://f-droid.org/en/packages/be.brunoparmentier.apkshare/ it works just as you want it to, plus you can also share other apps as well :)

meypod avatar Jul 07 '23 03:07 meypod

I prefer to let third party apps handle it

OK :)

check this app for example, I just found it: https://f-droid.org/en/packages/be.brunoparmentier.apkshare/ it works just as you want it to, plus you can also share other apps as well :)

Very good app thank you very much :)

TorCzaf avatar Jul 07 '23 03:07 TorCzaf

Hi @meypod Many Twelver Muslims in various countries of the world, as well as many applications, rely on (Astronomical Research Center) to know the prayer times

I wonder, can you add this method of calculation to this great application?

https://english.nojumi.org/prayertimes

AI-IMED avatar Jul 07 '23 06:07 AI-IMED

Hi @AI-IMED , The link you have given does not mention any angles that is used for calculation of the prayer times since the app calculates everything offline, we need the angles and methods used by them

have you tried the "Shia Ithna Ashari, Leva Institute, Qum" or "Shia, Institute of Geophysics, University of Tehran" method to see how it compares ?

meypod avatar Jul 07 '23 06:07 meypod

The link you have given does not mention any angles that is used for calculation of the prayer times since the app calculates everything offline, we need the angles and methods used by them

It saddened me , I depend on it because it gives very accurate prayer times.

have you tried the "Shia Ithna Ashari, Leva Institute, Qum" or "Shia, Institute of Geophysics, University of Tehran" method to see how it compares ?

Yes, I tested that, it is not accurate, I have to adjust the prayer times, but even with adjusting the times, after two months or more, it makes a difference in the prayer times again

AI-IMED avatar Jul 07 '23 07:07 AI-IMED

I'm sorry but without knowing the exact details of their calculation there's not much I can do

Yes, I tested that, it is not accurate, I have to adjust the prayer times, but even with adjusting the times, after two months or more, it makes a difference in the prayer times again

Make sure to try changing the advanced settings in the calculation settings, if the calculated time is close, one of those may help adjust your time correctly

meypod avatar Jul 07 '23 07:07 meypod

I forgot to mention, It is necessary to add midnight to the calculation adjustment options, because there is a difference of opinion among the jurists of the Twelver doctrine, some of whom believe that the time of midnight is between sunset and dawn, and some of them believe that it is between sunset and sunrise

AI-IMED avatar Jul 07 '23 07:07 AI-IMED

I use https://github.com/batoulapps/adhan-js library, I wanted to add adjustments for the midnight time, but it is provided by the library, and it doesn't provide a way to adjust it

please create an issue there, if it gets added there, I can add it as well

meypod avatar Jul 07 '23 08:07 meypod

Yes, I tested that, it is not accurate, I have to adjust the prayer times, but even with adjusting the times, after two months or more, it makes a difference in the prayer times again

"Shia, Institute of Geophysics, University of Tehran" method seems to match the times provided by the website you mentioned with only around 1 minute of difference which is usually due to rounding

meypod avatar Jul 07 '23 09:07 meypod

Yes, indeed, the difference is 1 minute, this calculation method seems better.

AI-IMED avatar Jul 07 '23 12:07 AI-IMED

Hi @meypod I got these links by myself, some by searching in Google and some from Wikipedia

https://www.londonprayertimes.com/ London - From google

https://www.e-solat.gov.my/ Malaysia  - From google

https://www.grandemosqueedeparis.fr/horaire-des-prieres-paris Grand Mosque de Paris - From google As for France Angle 15° and Angle 18°, I don't know From where to get those


Now these 3 websites below are in Arabic if you don't understand arabic, please tell me and I will help you in-shaa-Allah

http://www.affaires-religieuses.tn/public/ar Tunisia - From Wikipedia

https://www.marw.dz/%D9%85%D9%82%D8%A7%D9%84%D8%A7%D8%AA-%D9%88%D8%AF%D8%B1%D8%A7%D8%B3%D8%A7%D8%AA/%D9%85%D9%88%D8%A7%D9%82%D9%8A%D8%AA-%D8%A7%D9%84%D8%B5%D9%84%D8%A7%D8%A9 Algeria - From Wikipedia

https://www.habous.gov.ma/prieres/index.php Morocoo  - From Wikipedia

Or you can have a look at the source code of the app which I got calculation methods names from and search for links and parameters used in it https://github.com/Five-Prayers/five-prayers-android I have also created issue in there and waiting for the reply.

TorCzaf avatar Jul 08 '23 21:07 TorCzaf

Well that would make it a lot easier, they got all the parameters it seems the only issue is how credible they are (have you tried comparing times ?)

for example https://www.londonprayertimes.com/ takes time from https://www.eastlondonmosque.org.uk/prayer-times-and-calendar-explained which are based on time from http://astro.ukho.gov.uk/psp/index_beta.html which I can't find the calculation parameters from

meypod avatar Jul 09 '23 00:07 meypod

the only issue is how credible they are (have you tried comparing times ?)

You mean comparing times in the app I mentioned with those in the links?

No, I haven't.

OK I will do it.

TorCzaf avatar Jul 09 '23 03:07 TorCzaf

Also Speaking of calculations, can you also make the app to do online calculation and not only offline calculation if possible?

TorCzaf avatar Jul 09 '23 03:07 TorCzaf

OK I will do it.

Ah yes I forgot...I will have to change phone timezone for that..

Do you want me to compare times in the links with those in Google search? Or what? :)

TorCzaf avatar Jul 09 '23 03:07 TorCzaf

Also Speaking of calculations, can you also make the app to do online calculation and not only offline calculation if possible?

Not really, I try to keep app offline as much as possible (making things online make app more complex and prone to errors)

compare times with the official links with the times of the same method in five prayers app

meypod avatar Jul 09 '23 05:07 meypod

Not really, I try to keep app offline as much as possible (making things online make app more complex and prone to errors)

At least not that kind of errors that may affect app installation am I right? Or you mean errors that may affect offline mode and everything in the app?

I agree with you to make most of the app in offline mode I mean it seems that your idea is to make a small sized offline adhan app .. right? So what about making a section in the app and name it for example "online mode" and in this section you put everything related to online mode plus you can put a warning message to notify users that online mode may cause or have errors.

If you think online mode will increase the app's size then how about you clone this app and that new clone should have extra features like online mode ?

I mean at the end you should have 2 apps one small sized and offline and one with extra features and it may become big in size and you can name it for example "Al-Azan-Extra features" Or instead of cloning the app you can make extension/add-on for it and that add-on should have these extra features like online mode, local masjid pray times or maybe other features you like...

compare times with the official links with the times of the same method in five prayers app

As you command :)

TorCzaf avatar Jul 09 '23 14:07 TorCzaf

As you command :)

sorry, I didn't mean it like that

At least not that kind of errors that may affect app installation am I right? Or you mean errors that may affect offline mode and everything in the app?

online, means it requires a network connection, and a backend many things can go wrong, handling states between disconnections adds some complexity and unreliability, API may go down, it may become paid, etc

though one of the reasons is that in future if I manage to do something about Qibla map feature, I may remove internet permission from app to make it completely offline, which is better for privacy

There are other apps with mosques time like https://github.com/mawaqit/android-tv-app , And online apps like https://github.com/metinkale38/prayer-times-android

meypod avatar Jul 09 '23 16:07 meypod

sorry, I didn't mean it like that

No brother :) .. when I said that, I meant like "I will do it with pleasure" .. Or "Just tell me anything you want and In-sha-Allah I may do it". I know you didn't mean anything. There is no need to apologize. :)

online, means it requires a network connection, and a backend many things can go wrong, handling states between disconnections adds some complexity and unreliability, API may go down, it may become paid, etc

Aha I see now the big picture. Thanks for clarifying. I wish if I could provide you any help but I am a normal person....Thank You again.

though one of the reasons is that in future if I manage to do something about Qibla map feature, I may remove internet permission from app to make it completely offline, which is better for privacy

Hmm..indeed..yes

There are other apps with mosques time like https://github.com/mawaqit/android-tv-app , And online apps like https://github.com/metinkale38/prayer-times-android

Thank you for your great suggestions.

TorCzaf avatar Jul 09 '23 19:07 TorCzaf

We can also add a "Custom" method which will allow users to enter their own angles

The feature of entering custom angles looks interesting, I'm eagerly awaiting the feature to try it, because I do not know my angle accurately, and to see if it will contribute to adjusting the accuracy of the calculations that I need.

AI-IMED avatar Jul 11 '23 08:07 AI-IMED

methods other than Algeria and Unified London don't match exactly with their official websites when checked inside the five prayers app

meypod avatar Jul 14 '23 15:07 meypod

I was planning to do it for you soon but it is just I am busy these days ... militry-related things and others... but I I am glad you did it, you are now certain what is reliable and what isn't reliable.

TorCzaf avatar Jul 14 '23 16:07 TorCzaf

And what is the solution now? Will you put your own parameters based on the official links I sent you? Or what? I mean will you make parameters?

Also the app you mentioned https://github.com/metinkale38/prayer-times-android has other calculation methods like IGMG.org ... this one has German prayer times I don't know the other two NamazVakti.com Semerkandtakvimi.com

TorCzaf avatar Jul 14 '23 17:07 TorCzaf

Will add Algeria method as that's the only matching one

Unified London is for East London mosque and they use moonsighting committee method adjusted to their location so probably not going to add that For morocco, tunisia and malaysiya will later research and try to find what parameters they use exactly

meypod avatar Jul 14 '23 23:07 meypod

Will add Algeria method as that's the only matching one

That is great news. By the way I thought Algeria is hard to be added because I didn't see any automatic timer/hour I mean it is just a PDF file on their religious ministry website.

Good luck with the rest of the countries.

TorCzaf avatar Jul 15 '23 00:07 TorCzaf

Muslim Pro also has other calculation methods

https://www.muslimpro.com/Prayer-times-Germany-DE#

-Federation of Islamic Associations in Basque Country -Fixed Isha Angle Interval -UAE General Authority of Islamic Affairs And Endowments -Islamic Centre Aachen this is probably for germany -Egyptian General Authority (Bis) I don't know what does "Bis" mean -MUIS (Majlis Ugama Islam Singapura) or maybe that is the one in your app As "Singapore"

And this one below has some angles for some calculation methods like Fixed Isha and EgyptBis https://support.muslimpro.com/hc/en-us/articles/202886274

### but be careful when using Muslim Pro, it is accused of selling users data to US militry

Also I found this I don't know how to explain it but it seems it has lots of functions so I will just leave it here in case you find it useful https://pkg.go.dev/github.com/RadhiFadlillah/go-prayer By the way it has angles for Malaysia

TorCzaf avatar Jul 15 '23 01:07 TorCzaf

Hi Here are some official links

UAE General Authority of Islamic Affairs And Endowments https://www.awqaf.gov.ae/en Maybe you already have this one as "The Gulf Region (Dubai)"

Islamic Centre Aachen https://app.izaachen.de/

Federation of Islamic Associations of New Zealand https://fianz.com/prayer-times/

Religious administration of Muslims of ukraine https://umma.in.ua/en/node/1692

Kementrian Hal Ehwal Ugama (Brunei Darussalam) https://www.mora.gov.bn/Theme/Home.aspx

Union de comunidades Islamicas de Valencia http://www.ucidvalencia.org/tiempos_de_oracion.html I don't know whether it is for all cities in Spain or only Valencia city

Islamske zajednice u Bosni i Hercegovini. (Bosnia and Herzegovina) https://www.islamskazajednica.ba/ I think they use prayer times from https://vaktija.ba/ And here is the source code https://github.com/vaktija

Islamske skupnostti v Republiki sloveniji (Slovenia) https://www.islamska-skupnost.si/ They use https://www.vaktija.si/

These 3 below I can't find prayer times on their websites, but I may send them emails and see if I can get prayer times

Muslim league in poland https://www.islam.info.pl/

All Ceylon Jamiyyathul Ulama (sri lanka) https://acju.lk/en

central islamic council of thailand https://www.cicot.or.th/en

TorCzaf avatar Jul 19 '23 00:07 TorCzaf

Here is official response from https://acju.lk/en regarding prayer timetable for sri lanka Screenshot_20230720-121308_Tutanota

And here is Prayer Timetable with Angles in the PDF file that they sent

Salah Time Table.pdf

TorCzaf avatar Jul 20 '23 09:07 TorCzaf