Hidden Power (move)/Calculation: Difference between revisions

From Bulbapedia, the community-driven Pokémon encyclopedia.
Jump to navigationJump to search
No edit summary
Line 1: Line 1:
{{cleanup}}
{{m|Hidden Power}} is a {{type2|Normal}}-type move. However, the real type of Hidden Power is determined by [[Pokémon]]'s [[IV]]s and may be one of 18 types, excluding [[Normal (type)|Normal]] and [[???]] types. Its power varies from 30 to 70 and is determined by its user's [[IV]]s as well.  
{{m|Hidden Power}} is a {{type2|Normal}} move. However, the type of Hidden Power can be anything ''except'' Normal- and [[???]]-types. Its damage varies from 30 to 70.


==Generation III==
==Type==
The following applies for Hidden Power in [[Generation III]].
Let us consider an example Pokémon, like Pikachu with this set of IVs:
=== Damage ===
The base power of Hidden Power is not random; it can be calculated with knowledge of a [[Individual values|Pokémon's IVs]].


''Hidden Power damage''=(a+b+c+d+e+f)*40/63+30
{{Talk:Hidden Power calculation/IV|30|31|31|31|30|31}}
* a=1 if the Individual Value of HP divided by 4 has a remainder of 2 or 3. If not, a=0.
* b=2 if the Individual Value of Attack divide by 4 has a remainder of 2 or 3. If not, b=0.
* c=4 if the Individual Value of Defense divided by 4 has a remainder of 2 or 3. If not, c=0.
* d=8 if the Individual Value of Speed divided by 4 has a remainder of 2 or 3. If not, d=0.
* e=16 if the Individual Value of Special Attack divided by 4 has a remainder of 2 or 3. If not, e=0.
* f=32 if the Individual Value of Special Defense divided by 4 has a remainder of 2 or 3. If not, f=0.


=== Type ===
Hidden Power's type of a Pokémon with given IVs is represented by a number, calculated with this formula:
The type of a Hidden Power attack is not random; it can be determined with knowledge of a Pokémon's IVs.


''Hidden Power type''=(u+v+w+x+y+z)*15/63
http://upload.wikimedia.org/math/e/5/9/e59610ef6a7ea896e12b341341149951.png
* u=1 if the Individual Value of HP is odd.
 
* u=0 if the Individual Value of HP is even.
HP(type)=Floor[(a+2b+4c+8d+16e+32f)*15/63]
* v=2 if the Individual Value of Attack is odd.
 
* v=0 if the Individual Value of Attack is even.
where ''a,b,c,d,e,f'' are calculated in this way:
* w=4 if the Individual Value of Defense is odd.
 
* w=0 if the Individual Value of Defense is even.
* a=1 if the Individual Value of HP is odd. If not, a=0
* x=8 if the Individual Value of Speed is odd.
* b=1 if the Individual Value of Attack is odd. If not, b=0
* x=0 if the Individual Value of Speed is even.
* c=1 if the Individual Value of Defense is odd. If not, c=0
* y=16 if the Individual Value of Special Attack is odd.
* d=1 if the Individual Value of Speed is odd. If not, d=0
* y=0 if the Individual Value of Special Attack is even.
* e=1 if the Individual Value of Special Attack is odd. If not, e=0
* z=32 if the Individual Value of Special Defense is odd.
* f=1 if the Individual Value of Special Defense is odd. If not, f=0
* z=0 if the Individual Value of Special Defense is even.
 
Which simply means that every element of the sum in the brace is the reminder of division of corresponding IV and 2, multiplied by appropriate power of 2 (2<sup>0</sup> in case of ''a'' and 2<sup>5</sup> in case of ''f''). The sum may range from 0 (when all IVs are even) to 63 (when all IVs are odd), inclusively. It is worth mentioning that the computed sum may be easily calculated by putting its variables ''a,b,c,d,e,f'' together in reverse order and interpreting this as a number in the binary system, which then needs to be reverted to decimal system:
 
''fedcba<sub>(2)</sub>'' = 32''f''+16''e''+8''d''+4''c''+2''b''+''a'' <sub>(10)</sub>
 
The summed value is then multiplied by 15 and divided by 63, to be sure that the number representing Hidden Power Type will range form 0 to 15, inclusively (16 values in total). The calculated number is then rounded down (''floor[]''), which simply means that only integral part of the calculated number is considered.  


The resulting number will correspond to a type; utilize the table below.  
The resulting number will correspond to a type; utilize the table below.  
{|
{|border="1" style="border: 1px solid black; border-collapse: collapse; " cellspacing="1" cellpadding="3"
!Number
!Number
!Type
!Type
|-
|-style="background-color: #{{Fighting color}}"
| 0
| <span style=color:#fff>0</span>
| Fighting
| [[Fighting (type)|<span style=color:#fff>Fighting</span>]]
|-
|-style="background-color: #{{Flying color}}"
| 1
| 1
| Flying
| Flying
|-
|-style="background-color: #{{poison color}}"
| 2
| 2
| Poison
| Poison
|-
|-style="background-color: #{{Ground color}}"
| 3
| 3
| Ground
| Ground
|-
|-style="background-color: #{{Rock color}}"
| 4
| 4
| Rock
| Rock
|-
|-style="background-color: #{{Bug color}}"
| 5
| 5
| Bug
| Bug
|-
|-style="background-color: #{{Ghost color}}"
| 6
| 6
| Ghost
| Ghost
|-
|-style="background-color: #{{Steel color}}"
| 7
| 7
| Steel
| Steel
|-
|-style="background-color: #{{Fire color}}"
| 8
| 8
| Fire
| Fire
|-
|-style="background-color: #{{Water color}}"
| 9
| 9
| Water
| Water
|-
|-style="background-color: #{{Grass color}}"
| 10
| 10
| Grass
| Grass
|-
|-style="background-color: #{{Electric color}}"
| 11
| 11
| Electric
| Electric
|-
|-style="background-color: #{{Psychic color}}"
| 12
| 12
| Psychic
| Psychic
|-
|-style="background-color: #{{Ice color}}"
| 13
| 13
| Ice
| Ice
|-
|-style="background-color: #{{Dragon color}}"
| 14
| 14
| Dragon
| Dragon
|-
|-style="background-color: #{{Dark color}}"
| 15
| 15
| Dark
| Dark
|}
|}
In our example, we get:
{{Talk:Hidden Power calculation/IV|30<br>''0''|31<br>''1''|31<br>''1''|31<br>''1''|30<br>''0''|31<br>''1''}}
HP Type = Floor[(0 + 2 + 4 + 8 + 0 + 32)*15/63] = Floor [46*15/63] = Floor[10.952] = '''10''', which means that our Pikachu has a [[Grass (type)|grass-type]] [[Hidden Power]].
==Damage==
Damage of the Hidden Power is calculated in a very same manner like its type, using the following formula:
http://upload.wikimedia.org/math/0/5/3/053924e0afcf77815c2db2952442a3a2.png
HP Power = Floor[((u+2v+4w+8x+16y+32z)*40/63)+30]
* u=1 if the Individual Value of HP divided by 4 has a remainder of 2 or 3. If not, u=0.
* v=1 if the Individual Value of Attack divided by 4 has a remainder of 2 or 3. If not, v=0.
* w=1 if the Individual Value of Defense divided by 4 has a remainder of 2 or 3. If not, w=0.
* x=1 if the Individual Value of Speed divided by 4 has a remainder of 2 or 3. If not, x=0.
* y=1 if the Individual Value of Special Attack divided by 4 has a remainder of 2 or 3. If not, y=0.
* z=1 if the Individual Value of Special Defense divided by 4 has a remainder of 2 or 3. If not, z=0.
Like before, the sum may range from 0 to 63, inclusively. The calculated number is then multiplied by 40 and divided by 63 to make sure that the fraction will not exceed 40. Then, the number is increased by 30 and rounded down, making Hidden Power's power a number ranging from 30 to 70, inclusively.
In our example, we get:
{{Talk:Hidden Power calculation/IV|30<br>''1''|31<br>''1''|31<br>''1''|31<br>''1''|30<br>''1''|31<br>''1''}}
HP Type = Floor[((1 + 2 + 4 + 8 + 16 + 32)*40/63)+30] = Floor [(63*40/63)+30] = Floor[70] = '''70''', which means that our Pikachu's Hidden Power's power is '''70'''
{{Talk:Hidden Power calculation/IV|30|31|31|31|30|31}}
{{Talk:Hidden Power calculation/Type|Grass|70|000|564}}
==Number of possible Hidden Powers==
As there are 6 IVs, ranging from 0 to 31 (32 in total), the number of different possible Hidden Powers should be 32<sup>6</sup>=2<sup>30</sup>, which is more than billion possibilities. But let us consider two Pokémon with one different IV:
{{Talk:Hidden Power calculation/IV|'''30'''|31|31|31|30|31|Ani025MS.gif}}
and
{{Talk:Hidden Power calculation/IV|'''26'''|31|31|31|30|31|Ani025MS.gif}}
As we see, both 26 and 30 are dividable by 2 and give the remainder of 2 when divided by 4. So, in both cases the algorithms will interpret the IVs of those Pokémon in the same way, returning Grass-type Hidden Power with 70 power. In fact, there are only four possibilities of IV:
# IV that '''is not''' even and '''does not give''' the reminder of 2 or 3 while dividing by 4,
# IV that '''is''' even and '''gives''' the reminder of 2 or 3 while dividing by 4,
# IV that '''is not''' even and '''gives''' the reminder of 2 or 3 while dividing by 4,
# IV that '''is''' even and '''does not give''' the reminder of 2 or 3 while dividing by 4,
It means that for the mentioned algorithms an IV of 30 is treated in the same way like IVs of 2,6,10,14,18,22 and 26 (8 in total). As we see, there are 8 IVs in every of four categories, giving us 32 in total. Conclusively, the real number of possible Hidden Powers is 4<sup>6</sup>=2<sup>12</sup>=4096. This number, however is far too large, as the real number of possible variations of Hidden power is simply 16*41=656, as Hidden Power exists in 16 types and has 41 different powers. The huge difference between 656 and 4096 is explained by the function ''floor[]'', which reduces many different numbers to one.
==External links==
Many Pokémon related sites prepared web-based calculators, which allows to compute Hidden Power of a Pokémon with given IVs:
* [http://www.psypokes.com/dex/hp.php Psypoke's Hidden Power Calculator]
* [http://www.serebii.net/games/hidden-power.shtml Hidden Power explanation on Serebii.net]
* [http://www.legendarypokemon.net/javacalc.html Legendary Pokémon calculator] 


[[Category: Game mechanics]]
[[Category: Game mechanics]]

Revision as of 04:20, 22 June 2008

Hidden Power is a Template:Type2-type move. However, the real type of Hidden Power is determined by Pokémon's IVs and may be one of 18 types, excluding Normal and ??? types. Its power varies from 30 to 70 and is determined by its user's IVs as well.

Type

Let us consider an example Pokémon, like Pikachu with this set of IVs:

Talk:Hidden Power calculation/IV

Hidden Power's type of a Pokémon with given IVs is represented by a number, calculated with this formula:

e59610ef6a7ea896e12b341341149951.png

HP(type)=Floor[(a+2b+4c+8d+16e+32f)*15/63]

where a,b,c,d,e,f are calculated in this way:

  • a=1 if the Individual Value of HP is odd. If not, a=0
  • b=1 if the Individual Value of Attack is odd. If not, b=0
  • c=1 if the Individual Value of Defense is odd. If not, c=0
  • d=1 if the Individual Value of Speed is odd. If not, d=0
  • e=1 if the Individual Value of Special Attack is odd. If not, e=0
  • f=1 if the Individual Value of Special Defense is odd. If not, f=0

Which simply means that every element of the sum in the brace is the reminder of division of corresponding IV and 2, multiplied by appropriate power of 2 (20 in case of a and 25 in case of f). The sum may range from 0 (when all IVs are even) to 63 (when all IVs are odd), inclusively. It is worth mentioning that the computed sum may be easily calculated by putting its variables a,b,c,d,e,f together in reverse order and interpreting this as a number in the binary system, which then needs to be reverted to decimal system:

fedcba(2) = 32f+16e+8d+4c+2b+a (10)

The summed value is then multiplied by 15 and divided by 63, to be sure that the number representing Hidden Power Type will range form 0 to 15, inclusively (16 values in total). The calculated number is then rounded down (floor[]), which simply means that only integral part of the calculated number is considered.

The resulting number will correspond to a type; utilize the table below.

Number Type
0 Fighting
1 Flying
2 Poison
3 Ground
4 Rock
5 Bug
6 Ghost
7 Steel
8 Fire
9 Water
10 Grass
11 Electric
12 Psychic
13 Ice
14 Dragon
15 Dark

In our example, we get: Talk:Hidden Power calculation/IV HP Type = Floor[(0 + 2 + 4 + 8 + 0 + 32)*15/63] = Floor [46*15/63] = Floor[10.952] = 10, which means that our Pikachu has a grass-type Hidden Power.

Damage

Damage of the Hidden Power is calculated in a very same manner like its type, using the following formula:

053924e0afcf77815c2db2952442a3a2.png

HP Power = Floor[((u+2v+4w+8x+16y+32z)*40/63)+30]

  • u=1 if the Individual Value of HP divided by 4 has a remainder of 2 or 3. If not, u=0.
  • v=1 if the Individual Value of Attack divided by 4 has a remainder of 2 or 3. If not, v=0.
  • w=1 if the Individual Value of Defense divided by 4 has a remainder of 2 or 3. If not, w=0.
  • x=1 if the Individual Value of Speed divided by 4 has a remainder of 2 or 3. If not, x=0.
  • y=1 if the Individual Value of Special Attack divided by 4 has a remainder of 2 or 3. If not, y=0.
  • z=1 if the Individual Value of Special Defense divided by 4 has a remainder of 2 or 3. If not, z=0.

Like before, the sum may range from 0 to 63, inclusively. The calculated number is then multiplied by 40 and divided by 63 to make sure that the fraction will not exceed 40. Then, the number is increased by 30 and rounded down, making Hidden Power's power a number ranging from 30 to 70, inclusively.

In our example, we get: Talk:Hidden Power calculation/IV


HP Type = Floor[((1 + 2 + 4 + 8 + 16 + 32)*40/63)+30] = Floor [(63*40/63)+30] = Floor[70] = 70, which means that our Pikachu's Hidden Power's power is 70

Talk:Hidden Power calculation/IV Talk:Hidden Power calculation/Type

Number of possible Hidden Powers

As there are 6 IVs, ranging from 0 to 31 (32 in total), the number of different possible Hidden Powers should be 326=230, which is more than billion possibilities. But let us consider two Pokémon with one different IV:

Talk:Hidden Power calculation/IV

and

Talk:Hidden Power calculation/IV

As we see, both 26 and 30 are dividable by 2 and give the remainder of 2 when divided by 4. So, in both cases the algorithms will interpret the IVs of those Pokémon in the same way, returning Grass-type Hidden Power with 70 power. In fact, there are only four possibilities of IV:

  1. IV that is not even and does not give the reminder of 2 or 3 while dividing by 4,
  2. IV that is even and gives the reminder of 2 or 3 while dividing by 4,
  3. IV that is not even and gives the reminder of 2 or 3 while dividing by 4,
  4. IV that is even and does not give the reminder of 2 or 3 while dividing by 4,

It means that for the mentioned algorithms an IV of 30 is treated in the same way like IVs of 2,6,10,14,18,22 and 26 (8 in total). As we see, there are 8 IVs in every of four categories, giving us 32 in total. Conclusively, the real number of possible Hidden Powers is 46=212=4096. This number, however is far too large, as the real number of possible variations of Hidden power is simply 16*41=656, as Hidden Power exists in 16 types and has 41 different powers. The huge difference between 656 and 4096 is explained by the function floor[], which reduces many different numbers to one.

External links

Many Pokémon related sites prepared web-based calculators, which allows to compute Hidden Power of a Pokémon with given IVs: