BETHPAGE, N.Y. (AP) _ Twenty-five years after a Grumman Corp.-built lunar module landed on the moon and eight years after Tom Cruise flew a Grumman F-14 in the movie ''Top Gun,'' the company has fallen to earth.

The defense contractor was at its peak, with more than 33,000 employees in facilities across the country, when ''Top Gun'' glamorized its premier fighter.

With the end of the Cold War and drastic cutbacks in defense spending, Grumman, based in the New York City suburbs of Long Island, has struggled.

As a result, analysts and Grumman employees were unsurprised by Monday's announcement of a buyout by Martin Marietta Corp.

''We knew that in order for it to survive there had to be some kind of merger,'' said Richard Gran, who heads a Grumman project to develop a high- speed train.

The experimental ''Maglev'' project, which involves using powerful magnets to propel a train on a cushion of air at 200 miles-per-hour, is an example of the new directions Grumman has taken to cope with the changing economy. Several cities are considering Maglev test projects.

Grumman started in 1929, building military aircraft. It grew into one of the country's top aerospace companies, and for 60 years was a leading supplier of planes for the Navy. It made the Hellcats that helped the U.S. in the Pacific in World War II.

The company's image was perhaps at its highest during the 1960s when it played a major role in the Mercury, Gemini and Apollo manned space missions. In 1969 when Neil Armstrong became the first person to step onto the surface of the moon, he was stepping off a lunar module manufactured by Grumman.

In 1990, the Pentagon canceled production of the F-14, nearly taking the company out of the airplane-building business.

Over the last few years, Grumman has focused more on its aircraft parts business, and still is involved in upgrading the F-14 and other warplanes with more sophisticated computers and electronics.

''It is now basically a large subcontractor,'' said Martin Cantor, an economist who follows Grumman. ''Grumman today would be incapable of winning a prime government aircraft contract.''

Grumman continues to produce for the Air Force a high-tech radar plane known as Joint STARS, or joint surveillance target attack radar system, which was used in the Persian Gulf War.

Grumman's E-2C Hawkeye, an early warning aircraft, is still important to the Navy and armed forces in other countries.