Building lifetime sexual partner networks

This web page contains the experiments (networks built) and additional material for the paper Luis Acedo, Rafael Martí, Francisco Palmi, Víctor Sánchez-Alonso, Francisco-José Santonja, Rafael-Jacinto Villanueva and Javier Villanueva-Oller, Building lifetime sexual partner networks, submitted to be considered for its publication in the journal Computers in Biology and Medicine.

The main objective of this study is to build reliable networks of sexual partners from data of surveys and use them to understand better how sexually transmitted diseases spread among the people.

The pesudo-code described in the paper has been implemented in C++ and several networks have been built in order to study the performance of the implementation. The program needs three parameters:

  • N: the number of people. N is going to take values 5 000, 10 000, 25 000, 50 000, 100 000, 150 000, 250 000, 500 000 and 1 000 000.
  • <k>m: the average number of sexual partners of the men. <k>m takes values 4.5, 5, 5.5 and 6.
  • alfa: is a measure of randomness in the women-men assignment, a bigger alfa implies more freedom in the women-men assignment. alfa takes the values 0 (greedy algorithm), 10, 20 and 30 (GRASP algorithm).

About the LSP network files

In the links listed on the left, you can access to the GIF and PDF files of the LSP networks and the source files with the matchings between women and men. Men are the red nodes and women the blue nodes. In each one of the links, you can see/download:

  • the LSP network in GIF format,
  • the LSP network in PDF format (bigger files than GIF and only available until 100 000 nodes),
  • the source text file of the LSP network.

The PDF files are not available for LSP networks of 150 000 nodes and greater, because these files are too large and difficult to handle to be visualized. Anyway, you can download the source text file of the LSP network and visualize it using Mathematica (see instructions below).

Inside the source text file of each LSP network, we can find the following variables (among others)

  • PobTotal -> total population,
  • edadesH -> age of every man,
  • edadesM -> age of every woman,
  • parHomAntes -> number of lifetime sexual partners of every man,
  • parMujAntes -> number of lifetime sexual partners of every woman,
  • matching -> lifetime sexual partners. The first element of each couple indicates the woman and the second the man.
  • tiempoEjec -> CPU time needed to build the LSP network, in seconds.

If you have Mathematica, from the souce file and the Mathematica file you can download from this link, you will be able to visualize the LSP networks on your own. Open the Mathematica file and follow the instructions inside.