Fixing a bug in transistor model