A 40 lb bag of pellets will last around 24 hours when heating your home with the pellets so the 20 lb bag of pellets should last at least 12 hours of burning time to heat your home with a pellet stove.
Most people go through at least 1 40 lb bag of wood pellets per day when they're heating their homes with the wood pellets.