The present application provides a true random
number generator and a
random number generation method based on a magnetic
tunnel junction device. The true random
number generator provided by the present application includes a
control circuit, a magnetic
tunnel junction device, and a random
number generator; the
control circuit is used to provide multiple continuous
voltage pulse signals to the magnetic
tunnel junction device, causing the resistance of the magnetic tunnel junction device to oscillate; the multiple
voltage pulse signals correspond to different flipping probabilities of the magnetic tunnel junction device, and after the multiple continuous
voltage pulse signals act synergistically on the magnetic tunnel junction device, the magnetic tunnel junction device accumulates the flipping probabilities based on in-memory calculations so that the final flipping probability after accumulation tends to be half-and-half probability; the random number generator is used to generate random numbers based on the resistance state of the magnetic tunnel junction device after the multiple continuous
voltage pulse signals are applied. The true random number generator and
random number generation method based on the magnetic tunnel junction device provided by the present application can generate random numbers with high randomness and uniform distribution.