Simulation of the hydrodynamic model of semiconductor devices by a finite element method