-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ActivityDrivenModel: Parse reluctance options
Reluctance options are not part of ConfigParser. Defaults are set and some checks are completed. Also added an example with the reluctance. TODO: Make a unit test on the ActivityDrivenModel with reluctances. Co-authored-by: Moritz Sallermann <[email protected]>
- Loading branch information
1 parent
c8520b9
commit 20d7eac
Showing
9 changed files
with
83 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
[simulation] | ||
model = "ActivityDriven" | ||
# rng_seed = 120 # Leaving this empty will pick a random seed | ||
|
||
[io] | ||
n_output_network = 20 # Write the network every 20 iterations | ||
n_output_agents = 1 # Write the opinions of agents after every iteration | ||
print_progress = true # Print the iteration time ; if not set, then always print | ||
|
||
[model] | ||
max_iterations = 500 # If not set, max iterations is infinite | ||
|
||
[ActivityDriven] | ||
dt = 0.01 # Timestep for the integration of the coupled ODEs | ||
m = 10 # Number of agents contacted, when the agent is active | ||
eps = 0.01 # Minimum activity epsilon; a_i belongs to [epsilon,1] | ||
gamma = 2.1 # Exponent of activity power law distribution of activities | ||
reciprocity = 0.5 # probability that when agent i contacts j via weighted reservoir sampling, j also sends feedback to i. So every agent can have more than m incoming connections | ||
homophily = 0.5 # aka beta. if zero, agents pick their interaction partners at random | ||
alpha = 3.0 # Controversialness of the issue, must be greater than 0. | ||
K = 3.0 # Social interaction strength | ||
mean_activities = false # Use the mean value of the powerlaw distribution for the activities of all agents | ||
mean_weights = false # Use the meanfield approximation of the network edges | ||
|
||
reluctances = true # Assigns a "reluctance" (m_i) to each agent. By default; false and every agent has a reluctance of 1 | ||
reluctance_mean = 1.0 # Mean of distribution before drawing from a truncated normal distribution (default set to 1.0) | ||
reluctance_sigma = 0.25 # Width of normal distribution (before truncating) | ||
reluctance_eps = 0.01 # Minimum such that the normal distribution is truncated at this value | ||
covariance_factor = 0.0 # Determines whether activities and reluctances will be correlated. If set to 0.0 (default) then they will not be correlated. | ||
|
||
[network] | ||
number_of_agents = 1000 | ||
connections_per_agent = 10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters