Sheikh Muszaphar Shukor of Malaysia, a crew member on the 16th mission for the International Space Station, gives thumbs-up near the Soyuz-TMA capsule before the final test outside Moscow on Tuesday, Sept. 18, 2007. *

Photo: Associated Press / Mikhail Metzel * Sheikh Muszaphar Shukor has a problem. Two problems. The first is that Mecca keeps moving.

Well, not really. It's Shukor who'll be moving. As Malaysia's first astronaut, he's scheduled to lift off October 10 in a Russian Soyuz spacecraft for a nine-day visit during the holy month of Ramadan to the International Space Station.

He's a devout Muslim and when he says his daily prayers he wants to face Mecca, specifically the Ka'aba, the holiest place in Islam ("Turn then thy face towards the Sacred Mosque: wherever ye are, turn your faces towards it .... " The Quran, Al-Baqarah, 2:149).

That's where the trouble comes in. From ISS, orbiting 220 miles above the surface of the Earth, the qibla (an Arabic word meaning the direction a Muslim should pray toward Mecca) changes from second to second. During some parts of the space station's orbit, the qibla can move nearly 180 degrees during the course of a single prayer. What's a devout Muslim to do?

"As a Muslim, I do hope to do my responsibilities," Shukor says. "I do hope to fast in space."

Malaysia's space agency, Angkasa, convened a conference of 150 Islamic scientists and scholars last year to wrestle with these and other questions. The resulting document (.doc), "A Guideline of Performing Ibadah (worship) at the International Space Station (ISS)", was approved by Malaysia's National Fatwa Council earlier this year. According to the report, determining the qibla should be "based on what is possible" for the astronaut, and can be prioritized this way: 1) the Ka'aba, 2) the projection of Ka'aba, 3) the Earth, 4) wherever.

This leads to Shukor's second problem. There are two distinct schools of thought for determining the qibla: the commonly used Great Circle method, and the less common rhumb-line method. Looking at a flat map using any standard projection shows that a rhumb line (a line that cuts equal angles across all lines of longitude) drawn from, say, the Johnson Space Center in Houston to Mecca runs east-southeast. The numbers also bear this out – the space center is to the north and west of the Ka'aba, so any travel to the holy city should naturally be to the southeast.

Lay a string across a globe, however, and everything changes. A great circle – the shortest distance between two points on a sphere – between Houston and Mecca initially arcs to the northeast, then curves southward to the Saudi peninsula. Islamic scientists knew as early as the ninth century CE that the great circle route provided the shortest path to Mecca from anywhere in the world, even though it may in some places seem counterintuitive (Muslims in Alaska, for example, pray facing almost due north). Great circle formulae are at the root of nearly every online qibla compass.

Dr. Kamal Abdali, a cartographer who is also Muslim and who has written (.pdf) extensively on determining the qibla, favors the great circle route, but adds, "Prayer is not supposed to be a gymnastic exercise. One is supposed to concentrate on the prayer rather the exact orientation." He points out that in a train or plane, it's customary to start in the qibla direction but then continue the prayer without worrying about possible changes in position.

But how does that work in space? Mathematically, Shukor would need to place both ISS and Mecca on the same imaginary sphere – by either comparing the place on Earth directly beneath ISS with the real Ka'aba, or by projecting the Ka'aba into space (the option recommended by the Fatwa Council).

Yet the option to pray while facing a point in space brings up another problem. Muslims face the ground to pray, in part to avoid any hint of pagan sun or moon worship ("Prostrate yourselves not to the sun nor to the moon, but prostrate yourselves to Allah Who created them, if you (really) worship Him" (The Quran, Fussilat 41:37). If the Ka'aba projection happens to line up with the sun or moon, purists might believe the prayer invalid.

For now, Shukor is keeping the details of his plans fluid until he is actually on board ISS, a point with which Dr. Khaleel Mohammed, assistant professor of religion at San Diego State University, concurs. "In space," Mohammed points out, "the ritual prayer might be offset for more of a prayer that is allowed when on jihad ... for the lack of gravity and directional accuracy makes it legitimate to do as one sees fit. God does not take a person to task for that which is beyond his/her ability to work with."

Questions like these will continue as more and more religious astronauts travel into space. When is sunset in low Earth orbit if you're experiencing a dozen sunrises and sunsets in every 24-hour period? When does Sabbath begin on the moon, where the sun sets once a month? When is the first sighting of the crescent moon if you're on Mars? Religious councils of all faiths will have plenty to keep them busy for years.

- - -

The Associated Press contributed to this report.

Forty Strangers in a Room Talking About Religion

Mars Needs You: Space Tourist Spreads the Word

Ride Space Rocket, Don't Invest

New Telescopes to Scan Earth-Like Planet for Life