Machine-translated by Google. Questions are authored in English.
Top

Discussion

We have to use a Hopfield network to store three vectors as follows :

(1, 1, 1, 1, 1)
(1, -1, -1, 1, -1)
(-1, 1, -1, -1, -1)

Find the weight matrix using outer products method :

  • A.\[\begin{bmatrix} 0 & -1 & 1 & 3 & 1 \\ -1 & 0 & 1 & -1 & 1 \\ 1 & 1 & 0 & 1 & 3 \\ 3 & -1 & 1 & 0 & 1 \\ 1 & 1 & 3 & 1 & 0 \end{bmatrix}\]
  • B.\[\begin{bmatrix} 0 & -1 & -1 & 3 & 1 \\ -1 & 0 & 1 & -1 & 1 \\ 1 & 1 & 0 & 1 & 2 \end{bmatrix}\]
  • C.\[\begin{bmatrix} 0 & -1 & 1 \\ -1 & 0 & 1 \\ 1 & -1 & 0 \\ 3 & -1 & 1 \\ 2 & 1 & 1 \end{bmatrix}\]
  • D.\[\begin{bmatrix} 1 & 3 & 1 \\ 1 & -1 & 1 \\ 0 & 1 & 3 \\ 1 & 0 & 1 \\ 3 & 1 & 0 \end{bmatrix}\]

Answer: A

The weight matrix is that of option A, with rows (0, -1, 1, 3, 1), (-1, 0, 1, -1, 1), (1, 1, 0, 1, 3), (3, -1, 1, 0, 1) and (1, 1, 3, 1, 0).

By the outer product rule, \(W = \sum_k x_k x_k^{T} - 3I\) (subtracting 3I sets the diagonal to zero), so each weight is \(w_{ij} = \sum_k x_{k,i}\, x_{k,j}\) for \(i \ne j\).

\[ \begin{aligned} w_{12} &= 1 - 1 - 1 = -1 \\ w_{14} &= 1 + 1 + 1 = 3 \\ w_{24} &= 1 - 1 - 1 = -1 \\ w_{35} &= 1 + 1 + 1 = 3 \end{aligned} \]

The other entries work out the same way to 1, and the matrix is symmetric. Options B, C and D are not even 5 by 5 matrices, while a network of five neurons needs a 5 by 5 weight matrix.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.