•

# [Heavy Math] How to calculate time spent in FSR given fight length?

11 replies to this topic

### #1 Lurchington

Lurchington

King Hippo

• Allied Members
• 679 posts

Posted 26 July 2006 - 04:51 PM

first, as a primer, I'm using this as an inspiration and baseline for this procedure:

http://www.ctmod.net/calculator.ct

Goal:
Using the calculator, and implementing it's functionality in a spreadsheet, I'm trying to remove the necessity of specifying both time spent under the FSR, and the length of the fight. The reasoning for this goal: the numbers aren't valid unless the the time spent in FSR is accurate.

An example:
http://tinyurl.com/r9lxs

this says, for the values I specified, that for a fight length of 50 seconds at 50% of the time under the FSR, I can chain-cast a talented Greater Heal rank 1, and not run out of mana.

That makes no sense, as chain casting means you'll be under the FSR the entire time.

There should be a way to specify the fight length, then use math to find the optimal FSR % for each spell/rank. Instead of giving the FSR a priori

Key Parameters:

Unknown Variables Based on Fight:
Time of fight
Time Spent of FSR

Known Variables Based on Gear:
Spirit
MP5
Percentage of Normal Regeneration under FSR
Mana Pool

Derived Values:

Mana Regenerated Per Second - Based on your In FSR regen, your out of FSR regen, and the percentage of each
Mana to Spend Per Second - Given a starting mana pool, accounts for the fact that you can cast more than you regen given a finite fight and sufficiently large mana pool
"Castable Every" - How often you can cast a given spell, based on the Mana to spend budget.

Formulas for Derived Values

Contribution of spirit to regen/tick (for priest, rounded 12.5 to match ctmod.net value): (13 + spirit/4)

NonFSRTotalpTick = ( 13 + spirit/4) + (.4)*(MP5)
FSRTotalpTick = (FSRRegenerationPct)*( 13 + spirit/4)/100 + (.4)*(MP5)

-
ManaRegennedPerSec = (FSRpct)*FSRTotalpTick/100 + (100-FSRpct)*NonFSRTotalpTick/100
-

-
ManaToSpendPerSec = (ManaRegennedPerSec * FightLength + ManaPool)/FightLength
-

-

If (HealMana/ManaToSpendPerSec)>HealCastTime:
CastableEvery=HealMana/ManaToSpendPerSec
Else:
CastableEvery=HealCastTime
-

(accounts for the fact you can't cast faster than the spell time, even if you have the mana for it)

Restatement of Goal
in terms of the formulas:

I want to be able to specify FightLength, and based on that, find the correct FSRpct to go out of mana at that time.

A helper value I've calculated using for this is TrueFSRpct:

If (CastableEvery - 5) > 0:
TimeNotInFSR = CastableEvery - 5
Else:
TimeNotInFSR = 0

-
TrueFSRpct = 100*5/(5+TimeNotInFSR)
-

I guess I want a mathemathical or Excel-capable procedural way* to make:

FSRpct = TrueFSRpct

* Toying with the goal seek function, but loathe to try it if there's a math solution.

So math wizards? where do I start?

### #2 Lurchington

Lurchington

King Hippo

• Allied Members
• 679 posts

Posted 26 July 2006 - 05:09 PM

http://www.lurchingt...or_FSR_CALC.xls

the macro is for autosorting columns in the scenario tab, you can disable macros if you're paranoid.

in the scenario tab, I'm trying to accurately maximize the Sustainable HPS column (eg: cell F72), by making sure the FSR(%) I specify (eg: cell G72) match up to the actual time in FSR(%) (eg: cell J72)

### #3 Erongg

Erongg

Great Tiger

• Members
• 794 posts

Posted 26 July 2006 - 07:11 PM

So given a certain gear set, you want to be able to input a fight length and a spell(rank) and have it tell you how often you must stay in/out of the FSR to be able to cast that whole time? That is, it will tell you how often you can cast the spell to end up at zero mana at the end of the fight?

### #4 Lurchington

Lurchington

King Hippo

• Allied Members
• 679 posts

Posted 26 July 2006 - 07:13 PM

That seems to cover what I'm looking for.

edit: as a general overview, I'm trying to modify ctmod.net's calculator to just take 1 parameter (fight length) and have it take into account the accurate FSR for each spell.

### #5 Erongg

Erongg

Great Tiger

• Members
• 794 posts

Posted 26 July 2006 - 07:44 PM

Ok, let me see if this helps or makes sense:

Equation 1: time to run oom = (total mana pool/manacost per time) + (total regen/manacost per time)

Further breaking down one of the expressions in Equation 1:

total regen = regen/sec * time to run oom

Further breaking that down:

regen/sec = (FSRpct)*FSRTotalpTick/100 + (100-FSRpct)*NonFSRTotalpTick/100

That shows the logic of the equations I'm going to use, and now I'm going to assign those things variables:

T = time to run oom (or fightlength)
M = total mana pool, or your initial mana
C = mana cost per sec
R = total mana regen per sec
Ri = regen in FSR
Ro = regen out of FSR
F = %time in FSR

Then Equation 1, restated with these variables, is:
T = (M/C) + (R*T)/C

Substituting R = F*Ri + (1-F)*Ro, you can solve for F in terms of T, or you can solve for percentage-in-FSR based on fight length.

F = (C - (M/T) - Ro)/(Ri - Ro)

I think this does what you were looking for?

### #6 Lord BEEF

Lord BEEF

Soda Popinski

• Guild Members
• 3826 posts

Posted 26 July 2006 - 07:46 PM

I can't remember where right this second but someone linked a mod that actually tracks how often you're under the five second rule in actual fights, you may want to try that to get some real world numbers to punch in
Check out my friend's bitchin' Lord of the Rings Art

### #7 Lurchington

Lurchington

King Hippo

• Allied Members
• 679 posts

Posted 26 July 2006 - 07:49 PM

well, busting out the high school algebra here for this:

FSR = 500 / (5+CastableEvery-5)
FSR = 500 / CastableEvery
FSR = 500 / (HealMana / ManatoSpendpSec)
FSR = (500 / HealMana) * ManatoSpendpSec
set (500 / HealMana) to ConA since this is a constant based on heal rank

FSR = ConA * (ManaRegpSec * FL + Mana)/FL (FL is FightLength)
FSR * FL = ConA * (ManaRegpSec*FL + Mana)

ConB = FSRregen/100
ConC= nonFSRregen/100

FSR * FL = ConA * (( FSR*ConB + (100-FSR)*ConC)/2*FL+Mana)
FSR * FL / ConA = (FSR*ConB + (100-FSR)*ConC)/2*FL+Mana
(2/ConA)*FSR = FSR*ConB+(100-FSR)*ConC+ 2*Mana/FL

(2/ConA)*FSR = FSR*ConB+100*ConC-ConC*FSR+ 2*Mana/FL

(2/ConA)*FSR - FSR*ConB + ConC*FSR = 100*ConC + 2*Mana/FL

FSR( 2/ConA - ConB + ConC ) = 100*ConC + 2*Mana/FL

FSR = (100*ConC + 2*Mana/FL)/( 2/ConA - ConB + ConC )

meaning that my only independent variable is FL (FightLength)

any mistakes here, I'm at work so I can't just plug it in :(

### #8 Lurchington

Lurchington

King Hippo

• Allied Members
• 679 posts

Posted 26 July 2006 - 07:52 PM

Thanks for the reply. It came while I was typing mine up :)

I can't remember where right this second but someone linked a mod that actually tracks how often you're under the five second rule in actual fights, you may want to try that to get some real world numbers to punch in

I believe it's muse. I've used to get an overview of my FSR time for specific fights. :)

edit: after reviewing Erongg:

I'll use both of ours in conjuction with my spreadsheet a bit later on tonight when I have time to play with it. Again, thanks

I suspect we're both there, and I'll just handle specific cases where the FSR time is 100. Since that's where it breaks some of these equations.

### #9 hamlet_the_lesser

hamlet_the_lesser

King Hippo

• Members
• 667 posts

Posted 26 July 2006 - 08:06 PM

we have a guy that is learning lua and this is his first project(monitoring time in FSR that is).

### #10 Humbaba

Humbaba

Mr. Sandman

• Allied Members
• 6110 posts

Posted 26 July 2006 - 08:28 PM

Five second rule tracker is the mod that got linked yesterday. FSRT.

### #11 Lord BEEF

Lord BEEF

Soda Popinski

• Guild Members
• 3826 posts

Posted 26 July 2006 - 08:30 PM

Five second rule tracker is the mod that got linked yesterday. FSRT.

Ah thank you. I'll have to toy with this myself. Should give me a better way to evaluate gear and enchant choices, especially since I tend to innervate mages most often these days.
Check out my friend's bitchin' Lord of the Rings Art

### #12 Lurchington

Lurchington

King Hippo

• Allied Members
• 679 posts

Posted 26 July 2006 - 09:08 PM

this is what I finally went with:

FSR = ((100*nonFSR_regenpertick)+(200*ManaPool)/FightLength) / (.4*ManaPerHeal - FSR_regenpertick + FSR_regenpertick)

this seems to work out ok, and works well with my variables. Thanks for the push in the right direction Erongg :)

#### 0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users