## Opinion Dinamycs-Cognitive Opinion Dynamics

The Cognitive Opinion Dynamics model models the state of individuals taking into account several cognitively-grounded variables.

Opinion Dinamycs
119

#### Authorship

Homepage:
View
Is authorship not correct? Feed back

#### Classification(s)

Method-focused categoriesProcess-perspectivePhysical process calculation

#### Model Description

English {{currentDetailLanguage}} English

# Cognitive Opinion Dynamics

The Cognitive Opinion Dynamics model was introduced in [1], which models the state of individuals taking into account several cognitively-grounded variables.

The aim of the model is to simulate response to risk in catastrophic events in the presence of external (institutional) information.

The individual opinion is modelled as a continuous variable Oi ∈ [0, 1], representing the degree of perception of the risk (how probable it is that the catastrophic event will actually happen).

This opinion evolves through interactions with neighbours and external information, based on four internal variables for each individual i:

• risk sensitivity (Ri ∈ {−1, 0, 1}),
• tendency to inform others (βi ∈ [0,1]),
• trust in institutions (Ti ∈ [0,1]), and
• trust in peers (Πi = 1 − Ti).

These values are generated when the population is initialised and stay fixed during the simulation.

The update rules define how Oi values change in time.

The model was shown to be able to reproduce well various real situations. In particular, it is visible that risk sensitivity is more important than trust in institutional information when it comes to evaluating risky situations.

## Statuses

Node statuses are continuous values in [0,1].

## Parameters

Name Type Value Type Default Mandatory Description
I Model float in [0, 1]   True External information
T_range_min Model float in [0, 1]   True Minimum of the range of initial values for T
T_range_max Model float in [0, 1]   True Maximum of the range of initial values for T
B_range_min Model float in [0, 1]   True Minimum of the range of initial values for B
B_range_max Model float in [0, 1]   True Maximum of the range of initial values for B
R_fraction_negative Model float in [0, 1]   True Fraction of nodes having R=-1
R_fraction_neutral Model float in [0, 1]   True Fraction of nodes having R=0
R_fraction_positive Model float in [0, 1]   True Fraction of nodes having R=1

The following relation should hold: R_fraction_negative+R_fraction_neutral+R_fraction_positive=1. To achieve this, the fractions selected will be normalised to sum 1.

The initial state is generated randomly uniformly from the domain defined by model parameters.

The initial infection status can be defined via:

• percentage_infected: Model Parameter, float in [0, 1]
• Infected: Status Parameter, set of nodes

The two options are mutually exclusive and the latter takes precedence over the former.

## Methods

The following class methods are made available to configure, describe and execute the simulation:

### Configure

classndlib.models.opinions.CognitiveOpDynModel.CognitiveOpDynModel(graph)

Model Parameters to be specified via ModelConfig

Parameters: I – external information value in [0,1] T_range_min – the minimum of the range of initial values for T. Range [0,1]. T_range_max – the maximum of the range of initial values for T. Range [0,1]. B_range_min – the minimum of the range of initial values for B. Range [0,1] B_range_max – the maximum of the range of initial values for B. Range [0,1]. R_fraction_negative – fraction of individuals having the node parameter R=-1. R_fraction_positive – fraction of individuals having the node parameter R=1 R_fraction_neutral – fraction of individuals having the node parameter R=0

The following relation should hold: R_fraction_negative+R_fraction_neutral+R_fraction_positive=1. To achieve this, the fractions selected will be normalised to sum 1. Node states are continuous values in [0,1].

The initial state is generated randomly uniformly from the domain defined by model parameters.

CognitiveOpDynModel.__init__(graph)

Model Constructor

Parameters: graph – A networkx graph object
CognitiveOpDynModel.set_initial_status(selfconfiguration)

Override behaviour of methods in class DiffusionModel. Overwrites initial status using random real values. Generates random node profiles.

CognitiveOpDynModel.reset(self)

Reset the simulation setting the actual status to the initial configuration.

### Describe

CognitiveOpDynModel.get_info(self)

Describes the current model parameters (nodes, edges, status)

Returns: a dictionary containing for each parameter class the values specified during model configuration
CognitiveOpDynModel.get_status_map(self)

Specify the statuses allowed by the model and their numeric code

Returns: a dictionary (status->code)

### Execute Simulation

CognitiveOpDynModel.iteration(self)

Execute a single model iteration

Returns: Iteration_id, Incremental node status (dictionary node->status)
CognitiveOpDynModel.iteration_bunch(selfbunch_size)

Execute a bunch of model iterations

Parameters: bunch_size – the number of iterations to execute node_status – if the incremental node status has to be returned. a list containing for each iteration a dictionary {“iteration”: iteration_id, “status”: dictionary_node_to_status}

## Example

In the code below is shown an example of instantiation and execution of a Cognitive Opinion Dynamics model simulation on a random graph: we set the initial infected node set to the 10% of the overall population, the external information value to 015, the B and T intervals equal to [0,1] and the fraction of positive/neutral/infected equal to 1/3.

import networkx as nx
import ndlib.models.ModelConfig as mc
import ndlib.models.opinions.CognitiveOpDynModel as cod

# Network topology
g = nx.erdos_renyi_graph(1000, 0.1)

# Model selection
model = cod.CognitiveOpDynModel(g)

# Model Configuration
config = mc.Configuration()
model.set_initial_status(config)

# Simulation execution
iterations = model.iteration_bunch(200)

 [1] Vilone, F. Giardini, M. Paolucci, and R. Conte, “Reducing individuals’ risk sensitiveness can promote positive and non-alarmist views about catastrophic events in an agent-based simulation,” arXiv preprint arXiv:1609.04566, 2016.

#### How to Cite

D.Vilone (2019). Opinion Dinamycs-Cognitive Opinion Dynamics, Model Item, OpenGMS, https://geomodeling.njnu.edu.cn/modelItem/9ec2fd4f-e38d-4013-930c-631a3b12042b

#### Authorship

Homepage:
View
Is authorship not correct? Feedback

#### QR Code

• {{curRelation.name}}
{{curRelation.name}}

{{curRelation.overview}}
{{curRelation.author.join('; ')}}
{{curRelation.journal}}

Related Items
{{props.row.name}}

You can link resource from repository to this model item, or you can create a new {{typeName.toLowerCase()}}.

{{ props.row.description }}
{{ props.row.description }}
Drop the file here, orclick to upload.
File size should not exceed 10m.
Select From My Space

These authorship information will be submitted to the contributor to review.

Cancel Submit
Cancel Submit
{{ item.label }} {{ item.value }}
{{props.row.localName}}
Model Name :
Cancel Submit Cancel Submit
Name:
Version:
Model Type:
Model Domain:
Scale:
Purpose:
Principles:
Incorporated models:

Model part of

larger framework

Process:
Information:
Initialization:
Hardware Requirements:
Software Requirements:
Inputs:
Outputs:
Cancel Submit
Title Author Date Journal Volume(Issue) Pages Links Doi Operation
Cancel Submit

Yes, this is it Cancel

OK
Cancel Confirm
Model Classifications 1
Model Classifications 2
Title Author Date Journal Volume(Issue) Pages Links Doi Operation

#### NEW

Name:
Affiliation:
Email:
Homepage:

Yes, this is it Cancel

Confirm
path
:
/{{path.name}}
search results of '{{searchContentShown}}'

#### No content to show

{{item.name}}

.

{{item.suffix}}

.{{item.suffix}}

Max: {{toDecimal1(capacity/1073741824)}} GB
Copy
Delete
Rename
/{{path.label}}
Change
/{{path.name}}
Select File
Cancel Confirm
path
:
/{{path.name}}
/..
Cancel Confirm
{{ data.name }}
##### You have select  {{multipleSelection.length+multipleSelectionMyData.length}} data .
• Output Data
• {{item.computableName}}@{{formatDate(item.runTime)}}
{{scope.row.type}}
{{ scope.row.tag }}
• Fork Data
{{it.category}}

#### NEW

Name:
Affiliation:
Email:
Homepage:
previous next conform
Model Classifications

You can link related {{relateItemType}} from repository to this model item, or you can create a new {{relateItemType.toLowerCase()}}.

Related Items
{{ props.row.description }}
{{ props.row.description }}
Cancel OK