1 Q4.1

[1] 0.0016
IGRAPH 6821005 U--- 5000 19996 -- Erdos renyi (gnm) graph
+ attr: name (g/c), type (g/c), loops (g/l), m (g/n)
 [1] 0.0004 0.0026 0.0120 0.0288 0.0568 0.0926 0.1206 0.1344 0.1428 0.1272
[11] 0.1000 0.0668 0.0510 0.0288 0.0178 0.0092 0.0052 0.0024 0.0004 0.0000
[21] 0.0002

[1] 0.04761905

2 Q4.2

  • start with Start with n = 100 random infected individuals
  • Every day one individual connected to n infected individuals becomes infected with prob \(Prob = 1 -exp(-p*n)\)
  • infected individual recovers with constant probability r = 0.03 per day.
  • Recovered individuals can become infected again.

3 Q4.3

3.1 Generate with the Barabasi-Albert model

3.1.1 N = 100

Contains summary statistics for the temporal network.
Type of network: directed 
Number of nodes in the final network: 99 
Number of edges in the final network: 98 
Number of new nodes: 98 
Number of new edges: 97 
Number of time-steps: 98 
Maximum in-degree: 24 
Number of bins: 25 

4 Q4.4

  • To implement the prefenetial attachment network with the question 2, we need to compute or estimate the alpha \(\alpha\) of the power law distribution \(PW = aD^{\alpha}\) in question 2 as follows:

4.0.1 Case_05 :

$pars
[1] 1.483884

$value
[1] 836.4084

$counts
function gradient 
      13       13 

$convergence
[1] 0

$message
[1] "CONVERGENCE: REL_REDUCTION_OF_F <= FACTR*EPSMCH"

attr(,"class")
[1] "estimate_pars"

Contains summary statistics for the temporal network.
Type of network: directed 
Number of nodes in the final network: 199 
Number of edges in the final network: 198 
Number of new nodes: 198 
Number of new edges: 197 
Number of time-steps: 198 
Maximum in-degree: 175 
Number of bins: 50 

4.0.2 Case_06 :

$pars
[1] 1.098897

$value
[1] -2374.241

$counts
function gradient 
      14       14 

$convergence
[1] 0

$message
[1] "CONVERGENCE: REL_REDUCTION_OF_F <= FACTR*EPSMCH"

attr(,"class")
[1] "estimate_pars"
Contains summary statistics for the temporal network.
Type of network: directed 
Number of nodes in the final network: 999 
Number of edges in the final network: 998 
Number of new nodes: 998 
Number of new edges: 997 
Number of time-steps: 998 
Maximum in-degree: 214 
Number of bins: 50 

4.0.3 Case_07 :

$pars
[1] 1.013785

$value
[1] -254190.1

$counts
function gradient 
      19       19 

$convergence
[1] 0

$message
[1] "CONVERGENCE: REL_REDUCTION_OF_F <= FACTR*EPSMCH"

attr(,"class")
[1] "estimate_pars"
Contains summary statistics for the temporal network.
Type of network: directed 
Number of nodes in the final network: 4999 
Number of edges in the final network: 4998 
Number of new nodes: 4998 
Number of new edges: 4997 
Number of time-steps: 4998 
Maximum in-degree: 219 
Number of bins: 50