50cc? What is the wattage? My generator has a 160cc Honda engine. I suspect that it cost a medium-sized fortune, but it was there when I bought the van.
If you want a fair bit of power, it is really useful. It uses 230g per kw per hour, according to the spec. So with a 1KW load, that's about 22p per hour.
In my experience of using petrol generators, they work out at about one hour per litre (half an hour per litre for smelly 2-stroke ones) though it does depend on the load.
If you are only charging a
battery, perhaps half that consumption. So your gallon ought to last five to ten hours. That's about £1.25 per hour.
A motorhome engine idling will probably use about two thirds of that much diesel. Say about £0.85 per hour.
But then there is the maintenance aspect. Again, the motorhome engine works out cheaper.