In June 1769, 21-year-old Thomas Day and his friend John Bicknell went to the Orphan Hospital in Shrewsbury to select a prepubescent girl for Day. This was not a gesture of charity to remove the girl from her destitute situation but an experiment in which Day was trying to create his "perfect wife".

Born in 1748, Day had inherited a fortune from his father, a prosperous government official. He went to boarding school, where he thrived in the harsh regime of cold baths and punishments. He was clever and excelled in school and later at university. Dressed shoddily and with unkempt hair, Day eschewed the conventions of fashion, etiquette and status, preferring to wash himself in streams and live a simple life, withdrawn from temptations and comforts. And he needed a wife to join him.

After several unsuccessful attempts to find one, Day decided to mould one himself, in the manner of Pygmalion. He wanted a wife who was clever enough to discuss philosophy, astronomy and literature, while at the same time being entirely devoted to him and compliant to his wishes. She would need to be physically resilient to withstand the austere life that he envisaged, but at the same time gentle and caring. She should be young and beautiful like a goddess and "virginal like a country maiden".

Day, like many of his friends, was inspired by Jean–Jacques Rousseau's ideas of returning to nature, and in particular by his novel Émile, or on Education. Rousseau's thesis was that children were essentially good, but became corrupted by society and the influence of civilisation. In Émile he argued that education should protect children from this disturbing influence: the boy Émile is breastfed by his mother, allowed to roam freely through nature and is never scolded, while at the same time being shaped into a strong man by enduring the hardships of cold, hunger and pain. Day decided to use the same system to create a wife for himself.

At the Shrewsbury orphanage he chose a 12–year old with auburn ringlets, but within a few weeks he was at the Holborn branch of the Foundling Hospital in London, picking a second girl – this one with "flaxen locks". He would educate them both, and whoever turned out better would become his wife – a promise he sealed with a contract. Protected by his wealth and rank, Day had purchased these girls, Wendy Moore writes, as easily "as he might buy two shoe buckles".

Over the next year Sabrina and Lucretia were required to carry out household chores while learning about physics, geography and astronomy, and they were kept entirely ignorant as to Day's real intentions. According to one of Day's friends, Lucretia turned out to be "invincibly stupid", and so he decided to concentrate on Sabrina. While Lucretia was placed as an apprentice in a milliner's shop, Sabrina's ordeal was only just beginning.

As Day was planning a life of austerity, the girl had to be "educated" to withstand all kinds of physical hardships – cold, pain and terror, all in accordance with Rousseau's scheme in Emile. Day's extraordinary methods included dripping hot wax on to Sabrina's naked arms and shoulders (ordering her not to cry or move) and shooting guns at her skirts or close to her ears without warning (again, she was told to remain still). Maybe most astonishing of all was that Day lived openly with Sabrina in Litchfield among his friends of the Lunar Society, a circle of scientists, thinkers and industrialists in the Midlands which included Erasmus Darwin, the inventor Richard Lovell Edgeworth and the chemist James Keir.

Day's experiment didn't work out. Sabrina, he told his friends, "failed to meet his expectations". After two years, she was dispatched to a boarding school and Day resumed the search for a perfect wife among his peers. Over the next years he went through a staggering number of engagements and declarations of love – but each time something went wrong. One woman refused to marry him after he presented her with a list of expectations and a "proposed mode of living" that included complete seclusion from society, while another was discarded because she wanted to keep her diamond earrings.

Day was a paradoxical character: he became known for his charitable work, giving away much of his fortune to the poor though never giving much thought about Sabrina and her well–being after he abandoned her. He was an adamant abolitionist while at the same time making Sabrina practically his slave.

In the end, Day married Esther Milnes, an accomplished heiress and poet who became completely submissive to his will. Sabrina, meanwhile, spent several years at boarding school, was apprenticed to a dressmaker and then married Day's old friend, John Bicknell. It was only then that she learned the full extent of the experiment, but when she demanded some explanation from Day, he replied: "… whether those intentions were wild, chimerical, & extravagant … that object relates to myself alone & you are the last person in the world to whom I owe any apologies".

Within three years she was a widow, left with two young sons and no money because Bicknell had gambled everything away. She became a housekeeper at a boarding school in London and died aged 86, but not before she had suffered the humiliation of her story becoming public in a series of biographies.

As in her previous book, Wedlock, which portrayed Mary Eleanor Bowes and her disastrous and cruel marriage, Moore has again found an excruciatingly gruesome and fascinating story. But instead of turning these portraits into misery biographies, she weaves them into the broader context of the time. In Wedlock, she told a tale of evil and dependency, folded into the ideas of marriage and divorce in the late 18th century – and in How to Create the Perfect Wife, she investigates education, liberty and the role of women. It is pleasing to see a writer bringing together painstaking research with gripping storytelling. I can't wait for her next book.

• Andrea Wulf's Chasing Venus is published by Heinemann