To study the rotating trap which is related with BEC,two-dimensional harmonic oscillator is ana- lyzed and Hamihonian is provided.Wave function and energy eigenvalue are given.A coincidence is found that the rotating trap of two-dimensional harmonic oscillator has the similar form as the potential of charged particle in mag- netic field.