I don't understand what I've done. But I'll explain it to you now.
1. We find the average range (High-Low) per fPeriod.
2. We take the right amount of percent of the gPeriod range. It can be positive, negative and 0 (original).
3. We use this figure to correct the basic formula.