1. A robot comprising: a body; an arm connected to the body; a plurality of legs supporting the body; and a behavior control system constructed to control the motion of each of the body, the arm, and the plurality of legs according to desired motion trajectories, wherein the behavior control system is configured to generate time-series changing patterns of first state variables and second state variables, respectively, as desired motion trajectories according to a stochastic transition model, which expresses the first state variables indicating a motional state of the arm and the second state variables indicating a motional state of the body, which are variation factors of the values of the first state variables, as random variables, such that at least one of the first state variables follows a first specified motion trajectory determined for the robot to carry out a specified task and the second state variables cause the robot to satisfy a continuously stable dynamic condition.