Attribute Optimization

This article seeks to derive some mathematical results for optimizing Attribute ratios. The derivations assume some familiarity with multivariable calculus and Lagrange multipliers.
Please note that these are only theoretical results, and in-game optimization may differ in practice.
==Expected Critical==
Let r be the CRIT Rate probability (r\le 1) and d be the CRIT Damage (d \ge 0) in decimal form (so 150% CRIT Damage would be d=1.5).
Suppose the damage is x without a CRIT. The expected damage isHere damage is modeled as a random variable using a 2-point distribution. That is, if B(r) is a Bernoulli random variable that takes 1 with probability r and 0 otherwise, then in this model, damage can be written as the random variable x(1+B(r)d). The expected value or first moment is then x(1+rd).
:(1-r)x + r(1+d)x = x(1 + rd)
The objective is to maximize this function, namely the product f = rd.
In general, choose the CRIT Rate r and CRIT Damage d that maximizes their product to maximize the expected damage. That is, ceteris paribus (holding all other attributes constant):
Maximize the product of CRIT Rate and CRIT Damage.
Note that in practice, if one considers other factors, this may change. For example, for a Favonius Warbow, it may be more optimal to have more CRIT so that one can receive more energy. Some characters like Sangonomiya Kokomi may not even rely on CRIT. Some artifact sets and other effects like Blizzard Strayer and Cryo Resonance may give much more CRIT Rate to begin with, that it might be more optimal to stack more CRIT Damage. In practice, the optimization will usually differ based on one's team compositions.
===Crit Ratio===
If one assumes a certain distribution between crit damage and crit rate, then it is possible to derive a special optimal crit ratio. For example, a 2:1 ratio between crit damage and crit rate is sometimes recommended. This 2:1 ratio is optimal if one assumes a special distribution between crit damage and crit rate.
Within Genshin Impact, there is a tendency for crit rate and crit damage to appear in a 1 to 2 ratio, whether for artifacts, weapons, ascensions, etc. That is, for every 1 point in crit rate we gain, we lose 2 points in crit damage. We can express this using the following constraint:
:g = r + \frac{d}{2} - c = 0
for some constant c.
Our new goal is to maximize the product rd with respect to the above constraint. We can do this using Lagrange multipliers.
:\partial_r (f - \lambda g) = d - \lambda = 0
:\partial_d (f - \lambda g) = r - \frac{\lambda}{2} = 0
Solving this system gives
:d = 2r
so the optimal ratio between crit damage and crit rate assuming the given constraint is 2 to 1, as desired.
===Crit Distribution===
One of the key assumptions for the 2:1 rule of thumb to hold is the distribution of crit stats. Note that the assumption that crit damage and crit rate are distributed in a 2:1 ratio does not always hold in practice, in which case, we do not have a 2:1 ratio but rather go back to maximizing the product of crit rate and crit damage.
However, for artifact substats, crit rate and crit damage are usually distributed in such a way. We introduce the notion of the crit value as
:CV = 2r + d
For a 5 star artifact piece, we assume that we get a high roll on both crit rate r_0 and crit damage d_0. Note that we roughly have d_0 = 2r_0. We assume that when we level up the artifact, all upgrades go into either crit rate or crit damage. (When leveling to +20, we can upgrade substats 5 times.) Each time crit is upgraded it increases by r_0, and each time crit damage is upgraded it increases by d_0.
So we have the following table describing the possible stats we can get at +20:
Crit rate	Crit damage	CV
5r_0 	d_0 	12r_0
4r_0 	2d_0 	12r_0
3r_0 	3d_0 	12r_0
2r_0 	4d_0 	12r_0
r_0 	5d_0 	12r_0
So here the constraint
:g = 2r + d - c = 0
approximately holds where the constant c is just the crit value 12r_0. This gives some plausibility for the assumption made in the previous derivation.
==ATK%==
We now consider a third variable ATK%. With this the expected damage becomes
:x(1+a)(1 + rd)
where all other factors are absorbed into a constant x. Here we want to maximize the objective function f = (1+a)(1 + rd).
For artifact substats, we assume that ATK%, CRIT RATE, and CRIT DMG are distributed as follows:
:g = \frac{a}{3} + \frac{r}{2} + \frac{d}{4} - c = 0
That is, they appear in roughly a 3:2:4 ratio.
:\partial_a (f - \lambda g) = 1 + rd - \frac{\lambda}{3} = 0
:\partial_r (f - \lambda g) = (1+a)d - \frac{\lambda}{2} = 0
:\partial_d (f - \lambda g) = (1+a)r - \frac{\lambda}{4} = 0
From this we have that d=2r and
:\lambda = 3(1+rd) = 4(1+a)r
:3(1+2r^2) = 4(1+a)r
Solving this equation gives
:a = \frac{3(1+2r^2)}{4r} - 1 = \frac{3r}{2} - 1 + \frac{3}{4r}
Note this is only a theoretical result derived from a series of assumptions, and in-game optimization may be completely different. The formula is more complicated than the simple 2:1 rule of thumb derived earlier, so when optimizing ATK% in practice, it may be more useful to experiment around rather than follow the exact equation.
==Emblem of Severed Fate==
If a character equips a 4-piece Emblem of Severed Fate, how much should they invest into ER% and ATK%? In terms of maximizing the raw damage number, it is usually optimal to choose more ATK% over ER%. However, having more ER% can help characters gain their bursts more quickly, which could help deal more damage in the long run. For example, some characters such as Raiden Shogun, Mona, Xiangling, Xingqiu rely on their bursts for most of their damage.
Suppose we have no Damage Bonus to begin with. Damage will be proportional to
:f=(1+a)(1+b)
where a is the ATK% and b is the damage bonus. If one equips a 4-piece Emblem of Severed Fate set (which gives +20% ER and damage bonus equal to 25% of one's ER), then
:b = \frac{1.2 + \xi}{4}
where \xi \ge 0 is any extra ER% we have. From artifact substat distributions, we roughly have
:g = \frac{a}{9} + \frac{\xi}{10} - c = 0
Then
:\partial_a (f - \lambda g) = \frac{5.2 + \xi}{4} - \frac{\lambda}{9} = 0
:\partial_{\xi} (f - \lambda g) = \frac{1+a}{4} - \frac{\lambda}{10} = 0
Solving gives
:10\frac{1+a}{4} = 9\frac{5.2 + \xi}{4}
:\xi = \frac{10(1+a)}{9} - 5.2
Note this value is negative for a < 3.68 (368 ATK% which is not realistically achievable).
This means that for maximizing a single-instance of damage (or damage per screenshot), it is usually always optimal to invest into ATK% over ER% when equipping a 4 piece Emblem of Severed Fate. For example, choosing an ATK% sands over an ER% sands will give more damage per screenshot.
However, ER% is beneficial to invest in to the point of spamming one's burst on cooldown if one's burst gives a major chunk of their damage.
==Notes==
==Navigation==
Category:Game Systems
vi:Tối Ưu Hóa Thuộc Tính