In this thesis we analyze some of the opinion dynamics in both discrete and continuous
cases. In the discrete case, we will find some criteria under which we can say more about
the behavior of the dynamics such as convergence of the agents to the same opinion, or
consensus. For this purpose, we first consider the agent-based bounded confidence model of
the Hegselmann-Krause where multiple agents want to agree on a common scalar, or they
can be divided in several subgroups, with each subgroup having its own agreement value.
In this model, we restrict ourselves to the case when all the agents have the same bound of
confidence, often referred to as homogeneous case. We are interested to study the number
of iterations which is enough for the termination of the Hegselmann-Krause algorithm. In
other words, we want to give an upper bound on the number of iterations which guarantees
the termination of the algorithm independently of reaching a consensus or not. Assuming
the consensus is achieved in the Hegselmann-Krause model, we first give an upper bound on
the number of iterations and then we provide another upper bound without any assumption.
In chapter 3 we use some analysis based on Lyapunov function theory to improve our
upper bound substantially. In our analysis we use two differnt type of Lyapunov functions
which each of them gives us a polynomial upper bound for the termination time. In chapter
4 we consider the Hegselmann-Krause model in higher dimensions. We will see that in higher
dimensions we don’t have lots of nice properties which exist in the scalar case. Then, we
will find some upper bounds for the termination time. Also, at the end we will consider
an extension of the Hegselmann-Krause model to continuous case such that the time is
discrete but the density of the agents is continuous over the real line. In chapter 5 we use
the matrix representation for the discrete dynamics and we provide some conditions on a
chain of stochastic matrices based on their decomposition by permutation matrices such
that it can guarantee the convergence of the chain to a consensus matrix. Also, we provide
some examples and one necessary condition for finite time convergence of an especial case
of averaging gossip algorithms