For a bearded dragon under 15" a 20 or 35 gal tank is good. For an adult dragon the minimum tank should be 4'x2'x2', though the height can be reduced to no lower than 16". By vivarium I suspect you mean one that has live plants and soil is biologicaly active, so it naturally breaks down feces etc. I don't think bearded dragons are very suited for this type of vivarium as they do not like moisture and can ingest the sand and wind up being impacted. They are also hard on living plants, often eating them or trambling them. It is also easier for crickets and other insects to disappear in the cage and either breed or harm your dragon, especially at night with crickets.
It may still be possible to setup a living vivarium with dragons but it will have to be one that is more arid that most are. You would most likely have to spot clean the dragon's poop as the soil most likely will be too dry to allow proper breakdown. Alot more research will have to be made to create a properly working semi-desert type vivarium. Unfortunately I don't know enough about it to say if it can or cannot work. I don't think it would work, but I haven't researched it so I can easily be wrong. The tropical humid type vivariums are too humid for dragons, who do best with less than 50% humidity. Most tropical and humid vivarium are above 60% humidity and such humidity could cause many ailments in bearded dragons.
-----
PHLdyPayne