Some years ago, when my father was based in Varanasi, I had the chance to visit the Kashi Vishwanath temple for the first time in my life. I was only 9 then, and had only witnessed the slightly newer and more "blazing" temples like those of Birla's and J.K.'s, which are mostly built of white marbles, and shine brightly during the evenings and nights.
For the first time I witnessed a temple built in slightly older times. The kid in me was disgusted by the water and pieces of flowers and leaves lying all around the temple premises and me being forced to remove slippers and walk barefoot. All of a sudden I blurted out "This temple is so dirty!". My father snapped back "You shall never call a temple dirty!". I wanted to ask why, but sensing the mood my father was in, a better sense prevailed inside me, and I decided to postpone the question in the wake of my own health benefits.. Never knew I would eventually find the answers to my questions.

The knowledge of Ancient Vedic Men was of such high degree, the customs they popularized and inbred among the people in their daily lives was of highly scientific and logical nature. A highly scientific marvel like Aum is remodeled to be an important religious symbol, while the Gods are attributed with Vahanas akin to their individual divinities. It is but very obvious then, that the places where the Gods reside, the temples are deemed to be resplendent of similar scientific and symbolic imagery, which not only appeals to the devotee's sub-conscious, but also helps him meditate peacefully.

The Architecture-The location and The Garbhagraha:
It is a mighty known fact that most of the ancient temples were designed to be more than mere places of worship and meditation. The Vedic temples were built strategically at places where the positive cosmic energy is in abundance because of the magnetic and electric fields.

The main idol is always located in the core center of the temple, known as the Garbha-Griha. As a matter of fact, first the idol is placed at its position and then the temple is built around it. The Garbha-griha is chosen to be the place where magnetic waves are the strongest. As a practice, some copper plates, inscribed with Vedic Shlokas are kept beneath the main idol. Copper absorbs the magnetic energy and radiates positive energy to the surroundings. This specific attribute of copper makes it useful in curing arthritis by wearing copper bracelets.

As a person revolves around the main idol in a clockwise direction, he receives the positive energy radiated from the copper, and this, gradually helps him, in meditation and maintain a good health on a regular visit. In a way, the temples were designed as "Public charging sites".

The pyramidal shape:
The particular pyramid shape of these temples serve manifold purposes. However hot or humid the entire surroundings may be, one could never feel hot inside a temple. A tall, gradually narrowing structure, along with water being poured all across the floors keeps the inside of the temple premises cool, and the magnetic fields stronger(heat reduces magnetic energy).
In the year 2005, an article was published in the Indian Journal of Traditional Knowledge. A group of scientists in Bangalore took containers of various shapes and placed various food items in it. As days passed, it was observed that the container which was pyramidal in shape demonstrated the slowest decay out of all the containers.
Various temples use flowers to further keep the atmosphere inside light and comfortable, to negate the effects of moistness. These flowers and fruits get decomposed as slowly as possible because of the pyramidal structure.

The Bells:
As per legends, the bell sound is to ward evil forces away. A well designed bell, if struck, produces long strains of AUM.
Symbolically, the body of the bell represents time. the tongue of the bell represents Saraswati. Striking the bell would mean the message of Saraswati, which is knowledge and wisdom itself, being spread all over.
Scientifically, a temple bell is made up of a variety of metals, just in the correct proportion. When struck properly, a bell sound lasts for at least seven seconds, and touches the seven healing centers, or the Chakras in the body. It also unites the left and the right part of the brain. As soon as one hears the bell, all pre-thoughts are emptied, or in a way, it wakes one up before entering the temple itself.
The bells also dont allow any insect to remain inside the temple. The reason, why even the oldest of temples wont have any insects or pests inside them.

The ingredients of worship: Lets take a step back from here, ie. the temple premises, and have a look at whats all happening inside the temple. Even under scorching sun and intense heat, the insides of the temple are still pretty cool. Water is being sprayed continuously and devotees are lighting up incense sticks, striking bells, and offering flowers to the deity. Lamps are lighted all over, which emit talismanic low light. Add to that the positive vibes which are already present all around.
All these ingredients of a 'perfect' worship create a state of trance, where from the point a devotee enters the premise, he enters into a state of trance and is almost hypnotized in the entire settings of the temple. His mind is now singularly focussed on devotion, and the body is absorbing positive energy. According to the very scientific Vedas, this is the state of trance when a man himself becomes God. Its only then, it is said, that one could build a temple inside his heart and can meditate without even needing one temple.

I wont say that each and every older temple of India has been built keeping the same concepts and ideologies in mind as stated above, but every temple that's based on Vedic notions, follows the same architecture and model as stated by the Vedic principles
Neither did I try to comprehend nor find any logical reasoning to why certain temples allow animal sacrifice. I personally feel that's an incorrect practice and should not be encouraged in the name of religion.

Its nothing lesser than a colossal tragedy with what happened in Uttarakhand a few days back. Thousands of innocent souls lost their lives and we all must pray for their souls to rest peacefully.
However, once cannot take away the fact that only Kedarnath temple kept standing along with the central sanctum, primarily because they were based on Vedic foundations and the calamity couldn't shake it's very foundations.
Hoping that our governments take some lesson out of this tragedy and embrace the state with better disaster management facilities

People go to temples to wish for money, success, luck, and what not. But, this was not the primary reason for which these temples were built. The temples can help you attain a better health and peace of mind, and guide you towards spirituality. Sadly, modern day pundits have made temples an easy way to earn money, promising people of their wishes being fulfilled, but a temple visit would not serve such a purpose. Go there for your betterment, not to trade your time for your wish.