Skip to content
Maintankadin

Theck's MATLAB TPS analysis - WotLK/3.x

Soldierxx
Wed Jul 29, 2009 6:41 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Wouldn't it be possible to make the Threat mod look at your current stats and then make a calculation based on that ? Or is that too complex?
theckhd
Wed Jul 29, 2009 7:24 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Soldierxx wrote:Wouldn't it be possible to make the Threat mod look at your current stats and then make a calculation based on that ? Or is that too complex?

That's exactly what I was proposing.

For example, I write a file called "threat.lua" that contains functions to take your character data and spits out coefficients for converting STR, Hit, etc. to TPS.

Culhag then calls this function or functions in the code he added to RB, rather than using inaccurate static values.
Culhag
Wed Jul 29, 2009 9:15 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

If you can do that (me I have no idea),then it should be pretty easy for me to use it in the calculation.
Cylan
Wed Jul 29, 2009 10:53 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Hey theck,

Have you ever calculated how much TPS Redoubt provides? I was considering dropping a point of it to max out TbtL, but I wasn't sure how much that would hurt me threat-wise (though it would hurt me mitigation-wise, obviously).
tlitp
Wed Jul 29, 2009 11:36 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Code: Select all
%Armor Penetration Constant C
C=400+85*boss_level+4.5*85*(boss_level-59);

%debuffed armor
boss_debuffed_armor=boss_base_armor.*(1-0.2.*Sund_Up).*(1-0.05.*CoW_up);

%Armor penetration cap (max amount of armor that can be removed)
ArPenCap=min([boss_debuffed_armor; (boss_debuffed_armor+C)/3];

%Armor Penetration Rating in %, up to a max of 100%
ArP=min([ArPen./ArPen_rating_to_ArPen; 100.*ones(size(ArPen))]);

%Boss Armor and DR formulas
boss_armor=boss_debuffed_armor - ArP./100.*min([boss_debuffed_armor; ArPenCap]);
boss_DR=boss_armor./(boss_armor+C);


the EJ version posted above is almost correct :
a. the C constant is 467.5*80-22167.5=15232.5, valid for any level 80 PC against a boss-level target
b. the armor-ignoring effects are mostly multiplicative; the raid debuffs (SA/EA, CoW/FF, ST) are strictly multiplicative, one group to another, whereas the rogue's serrated blades talent is not; debuffed_armor=base_armor*(1-0.2*Sund_Up)*(1-0.05*CoW_up)*(1-0.2*ST_up)-640*SB; yes, the base armor of 'level 83 bosses' defaults now to 10643
c. the armor-penetrating effects are strictly additive one to another; the ArP values of gear, consumables, class talents (mace spec for rogues/warriors, blood gorged for DKs) and/or class abilities (battle stance for warriors) are to be subsumed

accurate simulations of shattering throw are rather tricky to make; the average uptime (as in duration of effect per cooldown) is meaningless, as it does not take into account the actual duration of the fight, plus the second-degree interactions with bloodlust/heroism (as they're usually linked)
Lythac
Thu Jul 30, 2009 12:48 am

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

theckhd wrote:I can't decide between sorted (by TPS) and unsorted (by spec). I like the fact that the sorted plot makes it easy to tell which spec is stronger, but it can be difficult to find the spec you want quickly. The unsorted plot makes it much easier to find the spec you want, but harder to see what beats it. I think this is an unavoidable trade-off though.


As your work is based on progression tanking in progression gear (rather than high threat gear in Naxx) it would seem logical to me for-

1) Sorted by DUH threat, non DUH is not progression.

2) Sorted by utility points then DUH threat.

Graph 2 should be of interest to show how much threat you give up for utility.

Stacked bars looks easier to read, also not interested much in non DUH.
Jasari
Thu Jul 30, 2009 1:31 am

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Cylan wrote:Hey theck,

Have you ever calculated how much TPS Redoubt provides? I was considering dropping a point of it to max out TbtL, but I wasn't sure how much that would hurt me threat-wise (though it would hurt me mitigation-wise, obviously).


Why can't you max them both out?
theckhd
Thu Jul 30, 2009 1:32 am

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Cylan wrote:Hey theck,

Have you ever calculated how much TPS Redoubt provides? I was considering dropping a point of it to max out TbtL, but I wasn't sure how much that would hurt me threat-wise (though it would hurt me mitigation-wise, obviously).

I did a quick back-of-the-envelope calculation a long time ago. I'm raiding at the moment, so I can't re-check my math very easily, but I can try and look at it tomorrow. I could add Redoubt into the talent simulator as well for future iterations.
theckhd
Thu Jul 30, 2009 2:31 am

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

tlitp wrote:the EJ version posted above is almost correct :
a. the C constant is 467.5*80-22167.5=15232.5, valid for any level 80 PC against a boss-level target
b. the armor-ignoring effects are mostly multiplicative; the raid debuffs (SA/EA, CoW/FF, ST) are strictly multiplicative, one group to another, whereas the rogue's serrated blades talent is not; debuffed_armor=base_armor*(1-0.2*Sund_Up)*(1-0.05*CoW_up)*(1-0.2*ST_up)-640*SB; yes, the base armor of 'level 83 bosses' defaults now to 10643
c. the armor-penetrating effects are strictly additive one to another; the ArP values of gear, consumables, class talents (mace spec for rogues/warriors, blood gorged for DKs) and/or class abilities (battle stance for warriors) are to be subsumed

accurate simulations of shattering throw are rather tricky to make; the average uptime (as in duration of effect per cooldown) is meaningless, as it does not take into account the actual duration of the fight, plus the second-degree interactions with bloodlust/heroism (as they're usually linked)

Do you have a source for this? Ghostcrawler posted the formula explicitly here:
Ghostcrawler wrote:If (level<60)
C=400+85*targetlevel
Else
C=400+85*targetlevel+4.5*85*(targetlevel-59);

For a level 80 target, C=15232.5. For a level 83, C=16635.


It looks like that's the proper way to work in SB, but later in the thread hellord and others seem to be ignoring it in their calculations. I haven't had time to sift through everything in that thread to figure out why.

I'm not sure if it's worth including ST in my simulations for the reasons you brought up. The difference isn't likely to be a huge one anyway, since most of our damage is holy. Even having the formula completely wrong, the results weren't that significantly different before.
tlitp
Thu Jul 30, 2009 7:23 am

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

I wouldn't refer you to a specific post on EJ, as they are many concerning this very issue; furthermore, the posts dating back to the time the ArP mechanics were re-discovered (early 3.1) are pretty filled up with data/assumptions that proved later on to be wrong; instead, you can check up the current spreadsheets (rogue1, rogue2, warrior), they all contain similar code when it comes to the ArP issue

ST's impact on the overall threat output of a paladin isn't exactly stellar, agreed; however, it would be interesting to run a sim in order to compare/evaluate the scaling factor (i.e. same gear/build/tps strategy, once averaged for a fight of infinite length, disregarding BL/ST; and once for the period of BL/ST alone)
theckhd
Thu Jul 30, 2009 11:55 am

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

tlitp wrote:I wouldn't refer you to a specific post on EJ, as they are many concerning this very issue; furthermore, the posts dating back to the time the ArP mechanics were re-discovered (early 3.1) are pretty filled up with data/assumptions that proved later on to be wrong; instead, you can check up the current spreadsheets (rogue1, rogue2, warrior), they all contain similar code when it comes to the ArP issue

ST's impact on the overall threat output of a paladin isn't exactly stellar, agreed; however, it would be interesting to run a sim in order to compare/evaluate the scaling factor (i.e. same gear/build/tps strategy, once averaged for a fight of infinite length, disregarding BL/ST; and once for the period of BL/ST alone)

I found this series of posts which seems to suggest that GC was wrong, and that C is based off of player level rather than target level, which would explain why it uses 80 rather than 83. Good to know.

All three of those spreadsheets match the code you suggested. I can omit Serrated Blades since that's a rogue-only effect, as well as the other additive class-specific effects like Battle Stance and Mace Spec. I'm a little more torn on the Shattering Throw issue, simply because it's a little tricky to fit into my model. I'm calculating sustained TPS based on one full cycle of our tanking rotation, which is 18 seconds. The easiest way to incorporate ST is probably to calculate once without it, once with it, and calculated the weighted average based on uptime. But again, I'm not certain it's worth going through the work since it's a 10-second effect with a 5-minute cooldown.

There's also the fact that none of those spreadsheets seem to include ST in their calculations. I'm not sure whether they omit it because of the cooldown or something else.

In any event, here's the updated code. I'll probably leave ST_up disabled by default for now, until I decide what to do with it.
Code: Select all
%%%%%%%%%%%%%%%% EJ Armor calcs
%Armor Penetration Constant C
C=400+85*char_level+4.5*85*(char_level-59);

%debuffed armor
boss_debuffed_armor=boss_base_armor.*(1-0.2.*Sund_up).*(1-0.05.*CoW_up).*(1-0.2.*ST_up);

%Armor penetration cap (max amount of armor that can be removed)
ArPenCap=min([boss_debuffed_armor; (boss_debuffed_armor+C)/3]);

%Armor Penetration Rating in %, up to a max of 100%
ArP=min([ArPen./ArPen_rating_to_ArPen; 100.*ones(size(ArPen))]);

%Boss Armor and DR formulas
boss_armor=boss_debuffed_armor - ArP./100.*min([boss_debuffed_armor; ArPenCap]);
boss_DR=boss_armor./(boss_armor+C);
%%%%%%%%%%%%%%%%%%%%%%%


Thanks for all of your help with this, tlitp.
theckhd
Thu Jul 30, 2009 1:17 pm

Talent Specs, again

I found an error in the code that calculates the per-point TPS value of different specs while I was updating it for Redoubt. Apparently I was dividing by 3 instead of 5 for Divine Strength, thus inflating it's value in the last calculation. This version corrects that error, as well as adding in Redoubt.

We simulate the DPS and TPS for each of these talent configs, and calculate the value of each talent point through simple subtraction and division:
  1. no threat talents
  2. 3/3 One-Handed Weapon Specialization (OHWS)
  3. OHWS + 3/3 Touched By The Light (TBTL)
  4. OHWS+TBTL + 3/3 Crusade
  5. OHWS+TBTL + 5/5 Conviction
  6. OHWS+TBTL + 5/5 Seals of the Pure (SotP)
  7. OHWS+TBTL + 5/5 Reckoning
  8. OHWS+TBTL + 0/5 Divine Strength
  9. OHWS+TBTL + 0/3 Redoubt

For example, to evaluate Crusade, we subtract spec 3 from spec 4, and divide the result by 3 (the number of points in Crusade). Since OHWS and TBTL are so far ahead, we use those as the base spec with which to compare the other talents. There are really only two differences from previous analyses here:

Setup:
Rotation: 969
Seals: SoV
Glyphs: V only
Talents: Various, in combinations to isolate the benefit of each talent individually.
Gear: Theck's "WTF Double Vanq again?" set

Code: Select all
Talent     DPS      TPS   (both per point)
Reck      15.2     29.3                   
Conv      18.0     44.1                   
SotP      26.9     74.7                   
Crus      30.3     77.3                   
C(6%)     60.6    154.6                   
Red       35.8     99.3                   
DivStr    41.1    104.7                   
TbtL      50.0    138.6                   
1HWS      87.2    221.6       


Image
The correction to Divine Strength drops it to third place behind TbtL. Redoubt is right behind it, though this is calculated for a gear set that's below the block value DR region of ShoR. The value of each point in Redoubt will decrease exactly the same way block value does in the region of diminishing returns, and will drop to 0 once you're above the ShoR block value cap. Keep in mind that dropping the talent might bring you back into the DR region again though.

The BV break points at which the points in Redoubt actually become useless for threat should be easily calculated. The cap is 3161 BV, so if you let B be the base block value break point when 1.2*B=3161, then the break point with 3/3 Redoubt is 1.3*B=1.3(3161/1.2). Thus:
If you have over 3434 block value with 3/3 Redoubt, you'll see no difference in threat between 2/3 and 3/3 Redoubt
If you have over 3448 block vlaue with 2/3 Redoubt (3736 with 3/3), you'll see no difference in threat between 1/3 and 2/3 Redoubt
If you have over 3477 block vlaue with 1/3 Redoubt (4109 with 3/3), you'll see no difference in threat between 0/3 and 1/3 Redoubt


Here's a quick re-run of the talent spec simulation as well:
Setup:
Rotation: 969
Seals: SoV
Glyphs: V only
Talents: Various combinations of SotP (S), Reckoning (R), Conviction (V), and Crusade (C)
Gear: Theck's "WTF Double Vanq again?" set
Code: Select all
Spec         DPS      TPS      TPS(e)   Util
3S           3109     7953     7953     12 
4S           3136     8027     8027     11 
5S           3163     8102     8102     10 
4S+3R        3184     8122     8122      8 
5S+3R        3211     8198     8198      7 
5S+5R        3243     8260     8260      5 
5S+3R+1V     3230     8245     8245      7 
5S+3R+3V     3269     8339     8339      5 
5S+1V        3181     8148     8148      9 
5S+3V        3219     8240     8240      7 
5V           3118     7949     7949     10 
1V+2C        3107     7928     8084     12 
1V+3C        3137     8006     8239     11 
3R+1V+3C     3185     8099     8334      8 
3V+3C        3174     8097     8333      9 
5V+3C        3212     8188     8426      7 
3R+5V+3C     3261     8283     8525      4 
5V+2C        3180     8108     8267      8 
5V+3C-1T     3159     8043     8277      8 

This first plot is sorted by "no-DUH" TPS. The next two are unsorted and sorted by utility points, respectively:
Image
Image

Image
Cylan
Thu Jul 30, 2009 1:31 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

theckhd wrote:
Cylan wrote:Hey theck,

Have you ever calculated how much TPS Redoubt provides? I was considering dropping a point of it to max out TbtL, but I wasn't sure how much that would hurt me threat-wise (though it would hurt me mitigation-wise, obviously).

I did a quick back-of-the-envelope calculation a long time ago. I'm raiding at the moment, so I can't re-check my math very easily, but I can try and look at it tomorrow. I could add Redoubt into the talent simulator as well for future iterations.

No rush on it. I'm just curious how it does compared to threat talents at this point.

Jasari: I just reread theckd's analysis and figured out a new utility spec:

http://ptr.wowhead.com/?talent#sZV0tAbu ... obc:Gpkcmz

Crusade is so handy for the utility spec. :D
Jasari
Thu Jul 30, 2009 1:59 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Cylan wrote:
Jasari: I just reread theckd's analysis and figured out a new utility spec:

http://ptr.wowhead.com/?talent#sZV0tAbu ... obc:Gpkcmz

Crusade is so handy for the utility spec. :D


Yeah, that's probably the spec I'll be going with when 3.2 goes live.

I've actually been developing a web app that pulls data from armory and lists personalized TPS information. The feature I'm working on right now allows you to create a theoretical spec and have the TPS be calculated on the fly, so that if the standard list of "viable" specs isn't enough, you can add your own.

I'm probably ready to throw a "beta" version online somewhere, but don't have any of my own webspace available - I assume the company I work for wouldn't like to host a Paladin threat calculator. So if anyone knows of a cheap (or free) place that works with ASP, please let me know.
WATERBOYsh
Thu Jul 30, 2009 2:15 pm

Re: Theck's MATLAB TPS analysis (A Jonesy derivative work)

Hey theckhd, I was just wondering something. How hard would it be to convert your matlab stuff to an exel spreadsheet? I don't know any of the math stuff, but you have all the formulas in place already. It could be made so that you plug in your stats and it spits out graphs showing you which stats you should be stacking (could maybe even throw what avoidance stat you should stack for an optimal ratio of defense:dodge:parry). I might can look into this in a few weeks. I'm a programmer, but my company is trying to push out a beta build by the middle of August so I've been really busy lately.

Also, I don't know much about matlab, but can it spit out an executable? Is it an interpreted language? If we want to run your code, what do we need. I was looking at freemat and it seems pretty good, but I don't really want to mess with the code; just run it.