I am trying to define a function that is itself based off the results of other functions:
cpr[x_, i_, n_] := [cpm[x, i, n]/pxl[n, i]]
where:
cpm[x_, i_, n_] := Product[pm[x, i], {x, 1, n}]
and I want it to change to change its behavior every time that cpr < 1.
Specifically, I'd like to write this function such that x substracts the previous n required to cause cpr <1 and have i increase by one every time cpr<1 until the sum of all n's equals a predefined upper bound.
Any insights would be greatly appreciated!