This article was published on April 14, 2020

How math logic could test more people for coronavirus with fewer resources


How math logic could test more people for coronavirus with fewer resources

Rapid testing of patients is of great importance during a pandemic. But at a time when there aren’t enough COVID-19 tests or testing has been slow, is there a way to enhance the process? As a mathematician and engineer, I asked myself if there was anything a theoretician could do to help meet the demands of the World Health Organization to test as many patients as possible.

Well, there might be a way to test many patients with a few test tubes. Instead of using one test tube to produce a result for one sample, we can use several test tubes to test many more samples – with the help of some logic.

The general idea is simple. A sample taken from each of our theoretical patients is distributed to half of the test tubes that we have, in different combinations. If we have ten test tubes, for example, we would distribute the samples from each patient into a different combination of five of them.

Any tube that tests negative tells us that all the patients that share that test tube must be negative. Meanwhile, test tubes that test positive could contain samples from a number of positive patients – and an individual patient will test positive only if all their associated test tubes are positive.

This approach is efficient at the early stages of an epidemic in particular, when there are relatively few people that might test positive.

Modifying the approach

As more patients are infected, however, identifying who has the virus is more challenging because the positively tested tubes are more likely to include even greater combinations of patients. To overcome this difficulty, the approach has to be modified as illustrated in the example below.

Say that we have six test tubes and 20 patients. And the test tubes are ordered and numbered as #1, #2, #3, #4, #5, and #6. Each patient is given a six-digit number made up of zeros and ones (a binary system). Each digit corresponds to a test tube – a “0” means we don’t add the sample to the corresponding test tube, whereas a “1” means that we do.

The approach can be scaled up with some extra logic. Nadzeya Shanchuk/Shutterstock

For example, patient #1 is given the number [0 0 0 1 1 1], which means that only test tubes #4, #5, and #6 will contain samples from patient #1. Patient #2 is given the number [0 0 1 0 1 1], which means that only test tubes #3, #5, and #6 will contain samples from patient #2. And so on, for all 20 patients.

After adding the samples from all 20 patients, the six tubes go through testing. If, then, the test returns positive for tubes #4, #5, and #6, for example, we can say that only patient #1 – allocated the number [0 0 0 1 1 1] – will be positive, because only that patient had samples added to all three test tubes – #4, #5, and #6 – and none to the rest.

Now comes the difficult part. Say that test tubes #3, #4, #5, and #6 return positive. We can say that all patients with samples added to tubes #1 and #2 are negative, but we cannot be definite about the rest, since we have multiple possibilities with test tubes #3, #4, #5 and #6. Are patients [0 0 1 0 1 1] and [0 0 1 1 1 0] sick, or perhaps [0 0 0 1 1 1], [0 0 1 0 1 1], and [0 0 1 1 0 1], or maybe all four of them? All these combinations would result in test tubes #3, #4, #5, and #6 returning positive. So, is there a way to get a definite answer for who are the sick patients?

Yes, but only if the test is now able to return not only a positive or negative result, but also some degree of “positiveness”, for example by identifying the amount of antibody that there is in a sample. Using this, we can compare the amount of “positiveness” between test tubes, which gives us a clue as to the right combination of patients that test positive.

A degree of ‘positiveness’

Going back to our example, if the positiveness in test tubes #4 and #5 is the same (let’s say the same amount of antibody in both), but different in #3 and #6, then we can conclude that patients [0 0 0 1 1 1] and [0 0 1 0 1 1] can’t both be positive since the sample from the first patient [0 0 0 1 1 1] is in tubes #4, and #5, whereas the sample from the other patient [0 0 1 0 1 1] is in tube #5 (but not #4). This means the positiveness in those test tubes cannot be the same if both patients are sick (tube #5 will have the positiveness of both patients, but tube #4 will have the positiveness of just one).

The only two patients that would return identical positiveness in tubes #4 and #5 are patients [0 0 0 1 1 1] and [0 0 1 1 1 0], since samples from both of these would have been added to both tubes #4 and #5, resulting in the same positiveness in both test tubes.

In the example above we were able to test 20 patients with as few as six test tubes. But the method can be scaled up to test many thousands of patients with many fewer test tubes. And even with machines being developed that can process tests within five minutes, this approach could still be much quicker – and cheaper in places where there fewer resources.

Using maths, then, we can enhance the testing of collected samples, particularly when, and in areas where, testing is challenging. In these cases, it could potentially help to mitigate the novel Coronavirus and save many lives.The Conversation

This article is republished from The Conversation by Usama Kadri, Senior Lecturer of Applied Mathematics, Cardiff University under a Creative Commons license. Read the original article.

Get the TNW newsletter

Get the most important tech news in your inbox each week.

Also tagged with