In this paper we focus on the stochastic kinetic extension of the well-known Hodgkin-Huxley model of a biological neuron. We show the gradient descent algorithm for training of the neuron model. In comparison with training of the Hodgkin-Huxley model we use only three weights instead of nine. We show that the trained stochastic kinetic model gives equally good results as the trained Hodgkin-Huxley model, while we gain on more concise mathematical description of the training procedure. The trained stochastic kinetic model of neuron is tested in solving the problem of approximation, where for the approximated function the membrane potential obtained using different models of a biological neuron was chosen. Additionally, we present a simple application, in which the trained models of neuron connected with the outputs of a recurrent neural network form a system, which is used to calculate the Euler angles of an object's position in space, based on linear and angular acceleration, direction and the magnitude of Earth's magnetic field. Keywords Hodgkin-Huxley model • Markov kinetic formalism • Gradient descent • AHRS • Attitude and heading reference system where v is the potential on the neuron's membrane, u is the membrane recovery variable and I is the input current (stimulus), while a and b represent the time scale and sensitivity of the recovery variable, respectively. In our paper, however,