Well... lets put it this way, in the current market we are seeing a lot of stock lever action. I'll explain in a moment. By no means is this a concise answer, just one to help understand some things that occur with the markets. For the ease of an explanation, (your)money tends to be in one of three places...under your bed(checking,savings etc), invested into the equity markets(stocks), or in the fixed income market(bonds) or a combination of the three. If one perceives little risk in the stock market and a good return(imagine if you knew about Apple before anyone else!!), one will pull money out of the other two(use some savings, or sell some bonds) to invest and take advantage. When this happens money flows directionally. With this said, if money is coming out of bonds and moving into stocks because the rate of return is higher and the risk is worthwhile, then the price of bonds will decrease and the yields(interest rates) will increase to offset the lack of demand(price and yield are inverse of one another), whereas the price of the stock will likely increase because of the new demand(unless you are the only one who thinks its a good buy).....think supply and demand, when everyone wants it you can charge more, whereas how much is a VCR worth today?
Back to the original question...If you're referring to the Fixed income products(bonds) as the market, then sure, rates do go down when the market is up. Demand drives price up and yield down. Rates are tied directly to yield on MBS notes. If on the other hand you are referring to the Dow or any of the equity markets, then no would be a simple answer based on the assumption of the stock lever action mentioned above.
Take all this with a grain of salt, in an era of uncertainty surrounding the world markets,this is a very simple answer. There are many things that affect mortgage rates and barring a 2000 page explanation, i will say this.......anytime there is bad news about the equity markets, investors tend to put their monies somewhere safer(bonds). So when you hear the Dow is falling or the DJIA is having a rough day, money is most certainly heading towards the fixed income markets driving yields down(interest rates...). ....when the going is good we tend to risk it more in the equity markets, when the going is bad we would rather ride it out in the fixed income market.