Hi,
i am new on this forum. I studied math, but i have no answer to this problem.
I am creating a space game. Currently i need a formula for this problem.
Here is the case:
Lets say, a space ship weapon consumes 10 Power / sec. The power generator provides 100 Power and generates 4 Power / sec.
The question: After which time the power generator is "empty"?
Lets go through step by step without a formula:
1. After 10 sec (100 Power / (10 Power Consumption / sec) = 10 sec) the Power Generator would be empty, if it wouldnt has Regeneration.
2. But during this time the Power Generator generates 50 Power (10 sec * 4 Power = 40 Power).
3. After 4 sec (40 Power / (10 Power Consumption / sec) = 4 sec) the Power Generator would be empty again, if it wouldnt has Regeneration.
4. But during this time the Power Generator generates 16 Power (4 sec * 4 Power = 16 Power).
5. After 1,6 sec (16 Power / (10 Power Consumption / sec) = 1,6 sec) the Power Generator would be empty again, if it wouldnt has Regeneration.
6. But during this time the Power Generator generates 6,4 Power (1,6 sec * 4 Power = 6,4 Power).
7. Now we can make the final step. The space ship weapon has a good Rate of Fire. For example 4 shots / sec. So 2,5 Power Consumption / Shot.
Lets make it easy and just add time one last time: 6,4 Power / 10 Power Consumption / sec = 0,64 sec
>>> 10 sec + 4 sec + 1,6 + 0,64 sec = 16,24 sec
Now what i need is a formula to calculate those values.
Thanks in advance and best regards
Sebastian
i am new on this forum. I studied math, but i have no answer to this problem.
I am creating a space game. Currently i need a formula for this problem.
Here is the case:
Lets say, a space ship weapon consumes 10 Power / sec. The power generator provides 100 Power and generates 4 Power / sec.
The question: After which time the power generator is "empty"?
Lets go through step by step without a formula:
1. After 10 sec (100 Power / (10 Power Consumption / sec) = 10 sec) the Power Generator would be empty, if it wouldnt has Regeneration.
2. But during this time the Power Generator generates 50 Power (10 sec * 4 Power = 40 Power).
3. After 4 sec (40 Power / (10 Power Consumption / sec) = 4 sec) the Power Generator would be empty again, if it wouldnt has Regeneration.
4. But during this time the Power Generator generates 16 Power (4 sec * 4 Power = 16 Power).
5. After 1,6 sec (16 Power / (10 Power Consumption / sec) = 1,6 sec) the Power Generator would be empty again, if it wouldnt has Regeneration.
6. But during this time the Power Generator generates 6,4 Power (1,6 sec * 4 Power = 6,4 Power).
7. Now we can make the final step. The space ship weapon has a good Rate of Fire. For example 4 shots / sec. So 2,5 Power Consumption / Shot.
Lets make it easy and just add time one last time: 6,4 Power / 10 Power Consumption / sec = 0,64 sec
>>> 10 sec + 4 sec + 1,6 + 0,64 sec = 16,24 sec
Now what i need is a formula to calculate those values.
Thanks in advance and best regards
Sebastian