def METHOD_NAME(self, hypothesis, **kwargs):
    r"""The update method. Given a hypothesised association between a predicted state or
    predicted measurement and an actual measurement, calculate the posterior state.
    .. math::
        \alpha_t^i = E^{ki}(F\alpha_{t-1})^i
    Measurements are assumed to be discrete categories from a finite set of measurement
    categories :math:`Z = \{\zeta^n|n\in \mathbf{N}, n\le N\}` (for some finite :math:`N`).
    A measurement should be equivalent to a basis vector :math:`e^k`, (the N-tuple with all
    components equal to 0, except the k-th (indices starting at 0), which is 1). This
    indicates that the measured category is :math:`\zeta^k`.
    The equation above can be simplified to:
    .. math::
        \alpha_t = E^Ty_t \circ F\alpha_{t-1}
    where :math:`\circ` denotes element-wise (Hadamard) product.
    Parameters
    ----------
    hypothesis : :class:`~.SingleHypothesis`
        the prediction-measurement association hypothesis. This hypothesis may carry a
        predicted measurement, or a predicted state. In the latter case a predicted
        measurement will be calculated.
    **kwargs : various
        These are passed to :meth:`predict_measurement`.
    Returns
    -------
    : :class:`~.CategoricalStateUpdate`
        The posterior categorical state.
    """
    prediction = hypothesis.prediction
    measurement = hypothesis.measurement
    measurement_model = hypothesis.measurement.measurement_model
    measurement_model = self._check_measurement_model(measurement_model)
    if hypothesis.measurement_prediction is None:
        # Attach the measurement prediction to the hypothesis
        hypothesis.measurement_prediction = self.predict_measurement(
            predicted_state=prediction,
            measurement_model=measurement_model,
            measurement=measurement,
            **kwargs
        )
    emission_matrix = measurement_model.emission_matrix
    likelihood = emission_matrix.T @ measurement.state_vector
    posterior = np.multiply(likelihood, hypothesis.prediction.state_vector)
    posterior = posterior / np.sum(posterior)
    return Update.from_state(hypothesis.prediction, posterior,
                             timestamp=hypothesis.measurement.timestamp, hypothesis=hypothesis)