The lobster lunges, the claws snap, and the startled sculpin fish darts to safety among the rocks.

It is a drama shaped by evolution and reenacted continually along the rocky coast of Maine. But this episode took place in a remarkable new permanent exhibit at the Smithsonian's National Museum of Natural History.

There, in a 2,500-gallon tank, is a piece of a wild coastal ecosystem, complete with predators and prey in the same tank. Pieces of the habitat were captured on the Maine coast and assembled in a 12-foot-long, 6-foot-deep tank with electronically controlled high and low tides, where mechanically induced waves splash on the barnacle-clad rocks at one end. Connected to the big tank is a smaller one of 500 gallons containing a piece of a salt marsh and mud flat that experiences the same tides but no waves.

The new aquariums complement a microcosm of a tropical coral reef that has been on display for the past five years. The new tanks are adjacent to the coral reef in the museum's first floor Sea Life Hall.

"There must be hundreds of public aquariums around the country, and plenty of them a lot bigger than ours," says Walter Adey, director of the museum's Marine Systems Laboratory and creator of the exhibit. "What makes this different is that we aren't just showing you fish. We're showing you a more complete picture of the natural world, full of interactions."

Other aquariums, except for two similar coral reef exhibits Adey has built elsewhere, offer mostly artificial settings for their animals -- usually only a few of the more spectacular sea creatures placed in a lifeless display tank.

Isolated, few animals can carry out more than the most rudimentary acts of swimming or walking or, at scheduled times, feeding. In the Smithsonian's two marine ecosystems, however, most of the animals behave naturally. They search for food, chasing down prey or chomping seaweed, not some Fish Chow. They try to evade predators. They court mates.

Adey says the Maine coast tanks probably have 80 to 100 species of plants and animals. The exact amount isn't known because most of the rocks and bottom muds were collected complete with seaweed. He says there hasn't been time to make a census.

Many of the larger species are obvious. In addition to the lobsters -- one weighing nearly four pounds and two smaller ones -- there are several species of crabs, shrimps, sea urchins, scallops, clams, mussels, barnacles, kelp, anemones, snails, limpets and such fish as sculpin, tomcod, flounder and hake.

Environmental conditions in the tanks simulate those of the Maine coast. Artificial sunlight comes from 3,200 watts of special lamps just above the water. Timers vary day length to change with the seasons. Water temperature also varies seasonally: from about 55 degrees now it will warm to 60 later in the summer and then cool to 32 for the winter.

The trickiest simulation involves the tides, which rise and fall about a foot twice a day. As the tide goes out, the excess water is pumped into a holding tank behind the scenes. Electronic controls advance the tidal schedule by 40 minutes every day, just as real tides advance, and even vary their range to simulate the monthly cycle of full spring tides and slack neap tides.

The water is kept clean by a system that Adey invented to simulate the cleansing effect of algae far out at sea. In the ocean, algae remove animal wastes, including carbon dioxide, and restore oxygen. In the museum, water is piped to special tanks above the exhibit and poured over thick algal mats.

The system is working too well, Adey says, making the tanks unnaturally clear, so he may cut back the number of algae tanks. Still, it's easy enough to see the lobsters, which Adey says are currently the top predators in the aquarium. He adds that they may grow too voracious. Then, he allows, it may be necessary to introduce another species common to the Maine coast, one which favors lobster, usually with drawn butter.