I have absolutely no idea how I did this, and my Pokemon yellow was lost long ago. However there is definately a glitch.
It involved talking in the city where the water gym is and then flying to where the first gym is. Wonder around outside of the grass above the forest and enter. The music Stopped and my Pikachu stopped.
He had a blank face and would not follow me. Every few seconds my character dissapeared on screen and some japanese symbol replaced him, before going back to him. In this form I was able to walk THROUGH objects like trees and the signpost.
Unfortunately I freaked and switched off the game before exploring. I think this only occurres in the forest. (Memories of something to do with a 'bills secret garden' pop up in my head).
There IS a glitch in the game and hopefully someone can find it
Good luck Searching!!