NEW YORK — Medicine behind bars begins with the fundamental paradox of caring for misfits banished from a society that couldn't care less about their well-being.

This and a heap of more specific problems add up to a constant struggle.

Doctors and nurses, in great demand in the outside world, must be recruited to work for civil service wages in steel-barred surroundings. The National Health Service Corps, a federal program that allowed doctors to pay off education loans by working in prisons, was dismantled by the Ronald Reagan Administration.

Convicts bring a hodgepodge of untreated ailments into prison. Overcrowded cellblocks sizzle with fear of AIDS, tuberculosis and other contagious diseases, and prisons are being forced to open costly geriatric wards for graying inmates with heart or lung disease and other chronic conditions.

One source of relief from many other societal ills, the state legislator, has been more likely to dole out condemnation than compassion for criminals--who cannot vote.

"There's a general contradiction in providing health services and locking people up in steel cages. Prisons deform everybody," said Robert Cohen, former medical director at New York City's Rikers Island Prison and an expert medical witness.

Armond Start, medical director of the Wisconsin prison system, added: "Prisons are the most anti-therapeutic places there are."

Most Americans seem indifferent to what happens inside prisons.

"Prisoners are a pariah kind of constituency," said Edward Koren of the American Civil Liberties Union. "We treat them like garbage. You leave it outside in the trash can and don't want to see it again. Nobody cares--unless it comes back again."

The Supreme Court ruled in 1976 that "deliberate indifference to serious medical problems of inmates constitutes cruel and unusual punishment." The decision made prisoners the only U.S. citizens who are guaranteed medical care at government expense.

Having the right to care does not guarantee Mayo Clinic-style treatment, however. No federal or state authority has spelled out what constitutes adequate medical attention, so it remains a matter of court interpretation. Since 1982, only 10% of the nation's 600 prisons have complied with guidelines offered by medical professionals.

The following court cases illustrate some of the problems in prisons since the guidelines were issued:

* Six inmates in a Pittsburgh prison died within the last two years under "appalling, shocking and dangerously inadequate" conditions, according to Cohen, who testified in May in a federal lawsuit brought by several inmates. Cohen said that one AIDS-afflicted prisoner died of pneumonia, a diabetic died from lack of insulin and the other deaths resulted from improper diagnoses and treatments of heart attacks and cancer.

* In Minnesota's Stillwater Prison, a third of the 1,200 inmates and at least five guards contracted tuberculosis between 1982 and 1986. The first case was not diagnosed until six months after the inmate sought treatment, and corrections officials waited until two years after inmates filed suit to test for the airborne bacterium in the prison.

* A 25-year-old convict died in May, 1987, after suffering an asthma attack at Deer Island House of Corrections, a pre-Civil War lockup near Boston. According to a pending wrongful-death suit, the man was turned away from the infirmary at the 8 p.m. lockup, and the guards who dragged him to his cell ignored agony so intense that the inmate urinated as he was hauled up three flights of stairs.

* Hospitalized inmates from Rikers Island were shackled to bed frames and watched by guards until 20 months ago. Among them were AIDS patients, pregnant women and life-support patients.

"They were too ill to get out of bed, much less get out of the building," said Dale Wilker of the Prisoners Rights Project, which sued to have the shackles unlocked.

* At New York's Bedford Hills Correctional Facility for Women, several patients had to be hospitalized because dentist Donald Collings' drill slipped in their mouths while he was drunk, according to a 1984 suit filed by the Prisoners Rights Project. Collings resigned and the state paid damages of $650,000.

Medical care remains a frequent topic of lawsuits filed by U.S. inmates, whose numbers reached a record 627,402 in January.

Courts have ordered eight states and Puerto Rico to improve the medical care in their prison systems, and are demanding corrective actions at individual prisons in 30 other states. Lawsuits are pending in five states, according to the ACLU.