Her project, like many others at the institute, uses census data, which reveals the composition of nearly every American household: the number of adults and children, and their ages. From a single household, a large map can be constructed. First, the connections between mom, dad, son and daughter. Added next are dad’s connections at the shop, mom’s at an office, and the children’s at their respective schools. The analysis might determine that, say, a 12-year-old boy living in central Redmond, Wash., near Seattle, will come into regular contact with his parents, his sister, and an average of 20.5 fellow students at his local middle school.

Repeating the process with nearby households generates a dense digital map of interconnections over an entire community. On Dr. Pastore y Piontti’s computer monitor, it resembles a complex electrical circuit, with multicolored wires and cables to and from packed hubs of interaction.

“Think of it like tracing all regular interactions in the video game SimCity,” she said.

To this map, she adds still more connections, incorporating data on travel in and out of that community — by air, train or bus (if such information is available). The final result, which she calls a “contact matrix,” looks like a rough heat map — a colored slide showing who is most likely to interact with whom, by age. From this she subtracts out of all the school interactions, revealing an estimate of how many fewer interactions — and potential new infections — would occur by closing certain schools.

“Each country, each state, can be very different, depending on the patterns of interaction and compositions of households,” Dr. Pastore y Piontti said. “And then there is the question of what is most effective: a week of closing, or two weeks, or closed until next school year.”

Dr. Vespignani had disappeared back into his own office with a pair of senior analysts. They were huddled around a speakerphone, running through the latest modeling changes with an outside researcher. The lab is part of a consortium that advises the C.D.C., and fields continual calls from infectious-disease mapping operations around the world.

The conversation and consulting are nonstop, because the institute must navigate the limitations inherent to all predictive modeling. One challenge is that important venues of disease progression cannot all be anticipated: cruise ships, for example. Another is factoring in random events — say, an infected person who suddenly decides that now is the moment to take a dream trip to Spain.