I guess it will depend on whether you want to do serious dressage schooling or not! I wouldn't go narrower than 20m if poss altho you would get away with 19m. And length - if you only ever wanted to do a 20m circle in one place then that would be ok too! However - how good it would be for the surface would be another matter! So really and truely I would make it as close to 40x20 as you possibly can!
Ok,I'm not interested in being able to do dressage in it. Just basic lungeing,long reining and simple schooling of ponies....lead reins mostly,and no bigger than 14.2hh