Claire Richards lived only 24 years, but she hoped her life — enriched by mathematics and swing dancing and Shakespeare — would inspire others, and that her death from melanoma would teach others to take precautions against skin cancer.

"It's my sincere hope that if more people are informed about melanoma, less people will die from it," she wrote last December.

Richards died July 6 after a recurrence of melanoma that was discovered last October and disrupted her first year of medical school at Northwestern University's Feinberg School of Medicine.

Described as a "limitless ball of positive energy," Richards amassed a network of friends that spanned the globe from Belgium to Chile. Megan Ramey befriended Richards shortly after they both were found to have melanoma in 2010 and started treatment.

"Even when she was sick, she would always ask, 'How are you doing? How are you feeling? How's your dog?'" Ramey recalled. "She wanted to be that positive force for people."

Around Richards, "The shy begin to speak, the bullies begin to care, and everyone lives in the moment," Amelia Krug, a classmate at Southwest High School in Minneapolis, recalled in an e-mail to Richards' parents.

Richards was an honors student at Southwest, earned a physics degree from Boston University and worked in clinical research at Boston Children's Hospital's Immune Disease Institute.

Despite her childhood love of writing and a broad range of interests — including playing chess and playing clarinet in the Greater Twin Cities Youth Symphonies — Richards' parents could tell over time that she was drawn to medicine. Suspicions when their daughter was in middle school turned to strong hunches by high school, when Richards became fascinated by epidemiology and started writing about topics such as the history of bubonic plague.

Actors brought plays to her

There also was Shakespeare and her love of his sonnets.

"We kind of advised her she might do Shakespeare as a hobby," said her mother, Gail Manning, "because she couldn't do medicine as a hobby."

As her health deteriorated, friends read poetry to her and actors from the University of Minnesota performed "Henry IV" for her in her parents' home and the balcony scene from "Romeo and Juliet" on their staircase.

As a friend read Shakespeare's 29th sonnet, her father recalled, Richards starting reciting from memory the melancholy verses of a despondent man brought happiness by the thought of someone who loved him. "For thy sweet love remembered such wealth brings … that then I scorn to change my state with kings."

Fair-skinned and redheaded, Richards was at elevated risk for sunburn and skin cancer, but she generally took care of her skin and didn't use tanning beds, her mother said.

She never described cancer as a battle — because that would require victory or defeat — and hoped that people could learn from her encounter with the disease. While rates of other cancers have been steady or declining, the rate of skin cancer has been increasing — especially among young women.

"These smart, beautiful, nice young women are getting this horrible disease," Manning said.

Richards had been cancer-free for two years until a routine imaging scan detected a nodule in her lung. She eventually returned home from medical school and enrolled in a clinical trial at the Mayo Clinic, which tried to use an experimental "PD 1" medication to boost her immune system.

Part patient and part scientist, Richards used factual journal entries on CaringBridge to help her friends understand her cancer and treatment options. Describing a video of the surgery to remove the nodule in her lung, Richards called it "interesting … to watch a part of my lung being cut out from within my own rib cage. Very cool stuff."

Richards is survived by her mother and father, David Richards, and her brother, Hayden Richards, all of Minneapolis. Services were held last week.

Her charisma and intellect were special, said her med school mentor, Dr. Gary Martin. "She would have been a phenomenal doctor."

The family has requested that memorials be directed to the Stay Out of the Sun Foundation, which supports melanoma research and education at the Mayo Clinic.