I'm trying to find the expected number of trials, $x$, to achieve $n$ number of successes, when the probability of a success is dependent on the results of the last trial.
Specifically, I'm trying to calculate the effects of gacha pity on the expected number of trials to achieve $n$ number of successes. How it works is if a certain number of trials, $t$, have occurred without a success, the probability of success, $p$, will be increased by a set amount, $q$, for each failure. Once a success has been achieved, the number of trials in order to activate the probability increase is set back to $t$. I know that the expected number of trials for a number of successes is given by $x = n/p$, but this only works when $p$ is constant.
In the gacha system I'm examining:
$$p = 0.02,$$ $$t = 50,$$ $$q = +0.02$$
Any ideas or places you could point me to would be appreciated!