Programming All Known Pokémon-related Formulas

LINK: http://rapidshare.com/files/177919329/Pok_mon_Formules.doc.html

Hi guys, I didn't exactly know where to put this but I made this collection of all mathematic Pokémon-related Formulas which -providing I didn't forget any- covers all ingame calculations the third generation games make.

I made a nice document out of this information and checked everything ingame and it all seems to be very precise.

It goes from obvious things like Damage Calculation, Stat Calculation, Hidden Power Calculation, Experience Calculation, etc..., to Catch Chance Calculations and even Berry Powder, Pay Day Money, Escape Chance and things like that, including example calculations.

Maybe it doesn't all matter very much to competitive play but it is a nice overview for the ones that are specifically interested in the game mechanics, like me.

I also tried to convert formula's with a lot of text and description into mathematic language to make the document look more consistent.

If I made any mistakes or if you can think of anything that can be calculated and is not included in this guide, please tell me by mailing to draojurhul@zeelandet.nl (yes it's Dutch)

Have fun reading, ~

PS: I didn't really know how to post that link... Can people save the file this way?
 
Wow, that are a lot of formula's, seeing them all together. Great work. Maybe you should edit the link into your first post.
 

Caelum

qibz official stalker
is a Site Content Manager Alumnusis a Community Leader Alumnusis a Smogon Discord Contributor Alumnusis a Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Simulator Moderator Alumnus
It's actually pretty well written, I can make minor tweaks (grammar / standardization stuff)and put in into HTML sometime tomorrow and cache it. I don't know how active the OP is (given that he or she hasn't logged in for 10 days) so that's why I'm volunteering.

edit: I'll verify some of the more obscure formulas first with other resources just to make sure.
 

Caelum

qibz official stalker
is a Site Content Manager Alumnusis a Community Leader Alumnusis a Smogon Discord Contributor Alumnusis a Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Simulator Moderator Alumnus
Doubling Posting because I need help :(

I was thinking of just removing a few of the formulas because "they aren't important" but I'd rather keep them if I can find references for them to confirm their accuracy. I've tried searching through Smogon & google but I obviously could have missed it so if anyone could verify and confirm the accuracy of these formulas I can finish this up.

- The "Escape Rate" formula. I've been unable to find a secondary source to confirm the accuracy of that so if someone could provide that I would appreciate it.

- The "Pay Day Money" Formula. I've gotten 2 different answers for this so I want to make sure.

- The Berry Powder Formula. I found about 3 different formulas from random sites so if someone could point me to the correct one / most reliable one I'd appreciate it to confirm.

thanks !
 

X-Act

np: Biffy Clyro - Shock Shock
is a Site Content Manager Alumnusis a Programmer Alumnusis a Smogon Discord Contributor Alumnusis a Top Researcher Alumnusis a Top CAP Contributor Alumnusis a Top Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis an Administrator Alumnus
This is an excellent resource.

Since chaos wants this to be in the site, I would volunteer to compile the formulae in LaTeX and convert them as images. Otherwise the formulae would appear really amateurish in the site.

I would like to correct some things.

The damage formula itself isn't 100% accurate, but there's an article already dedicated to that, which this article can refer to.

In the Critical Hits section, the way it is written holds only for RBY. There, it is actually true that the Level was the thing that doubled. From GSC onwards, this is no longer the case. The Critical Hit doubles in the place that is mentioned in the Damage formula article. Reflect and Light Screen are ignored as well in a critical hit.

Also, Focus Energy raises the critical hit domain by 2 and not by 1 in DP, unlike what's written in the article. And high critical hit moves raise the critical hit domain by 1 and not by 2 in DP (there's a mistake: high CH moves used to increase the CH domain by 2 and not by 3 before DP!)

In the stats formula section, I always write one formula that holds both for HP and for the other stats:

Stat = floor((floor((2 x BS + I + floor(EV/4)) x Level / 100) + X) x N)

where X = 5 if stat is not HP, and Level + 10 if stat is HP.

In the status effects section, the burn attack halving effect does not actually happen to the stat in DP but it happens as per the damage formula article.

I'll check the ball catching formula and the experiece formulae when I get the chance.
 

Caelum

qibz official stalker
is a Site Content Manager Alumnusis a Community Leader Alumnusis a Smogon Discord Contributor Alumnusis a Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Simulator Moderator Alumnus
This is an excellent resource.

Since chaos wants this to be in the site, I would volunteer to compile the formulae in LaTeX and convert them as images. Otherwise the formulae would appear really amateurish in the site.
Heh. That's actually a really good idea, for some reason I didn't even think of doing that.

About the damage formula bit. I did catch the errors (including the critical hit thing) and I corrected it and referenced yours and Peterko's article. I didn't know the level bit was true in RBY though so thanks for that, I assumed it was just an incorrect multiplier in the original document.

Thanks for the catches on Focus Energy & I agree the your version of the stat formula is cleaner so I'll be changing that.

Assuming you (or anything else) confirms the accuracy of the catch rate / experience rate formulas the good bulk of this seems good to go and I can post my version with grammar / corrections before I put it on site to get it looked over sometime in the next few days.


I still have no idea what the Berry Powder formula is but I might just not include it and hold off on it and add it in later if I get confirmation (it's not exactly the most useful of the formulas anyway lol).

Thanks X-Act ^__^.
 
it should open fine in a word processing program. if that doesn't work, try redownloading it or making sure that the file type is .doc.
 
Sorry for not responding quite long...
The escape rate formula is on bulbapedia iirc.
Also the guide was not originally written for DP as I have little or no experience there, it was written for RSE/FRLG.
The Berry Powder formula I can't even remember where I got that... It happened a time ago when I just had FireRed myself. But I used the formula on ingame numbers and it worked very accurate.

For the Pay Day money, the formula's I find all boil down on the same result, which is in the guide...

See the following links for verification of some of your doubts:
http://bulbapedia.bulbagarden.net/wiki/Catch_rate
http://bulbapedia.bulbagarden.net/wiki/Experience
http://www.upokecenter.com/games/emerald/guides/crusher.php

Thank you for posting some mistakes indeed, the critical hit thing was very obvious and the stat formula looks better I agree.
Feel free to change stuff and it would also be a very good idea to convert it to LateX to make the formulas look better... I'm not very familiar with using LateX but the documents always look very good.
 
The reasons I separated the Stat formulas is because when HP is calculated, the Nature is always neutral so it equals 1. Therefore, it could be neglected in the HP formula. The second is of course the 10+L or 5.

Make sure when you read the guide, the Euclid fonts are installed on your computer. Otherwise it may indeed seem very amateuristic.
Euclid is the font TeX / LaTeX uses for equations. Therefore, the document already has a quite good layout imo.

You can install them here if you haven't got them yet: http://levine.sscnet.ucla.edu/general/software/jex/index1.htm
 

Caelum

qibz official stalker
is a Site Content Manager Alumnusis a Community Leader Alumnusis a Smogon Discord Contributor Alumnusis a Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Simulator Moderator Alumnus
I'm actually done with this (apologies to chaos for the delay, I got busy with other stuff in life randomly) but how do I convert Latex to images? I've never done that before (then again I've only written a paper in latex three times and someone else did the technical stuff for me mostly ;-;). I know a way I could do it, but it seems really cheap and wrong lol.

Probably just a question for X-Act but if anyone else knows that would be nice.


(PS: Can I just use any image service to hold them, like imageshack or something, or do I give them to chaos to host. just wondering? )
 
Doug can put them on cap.smogon.com if you can't find chaos (though the latter does have spring break this week so he shouldn't be too busy).
 

Caelum

qibz official stalker
is a Site Content Manager Alumnusis a Community Leader Alumnusis a Smogon Discord Contributor Alumnusis a Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Simulator Moderator Alumnus
Yeah, I don't know why I would even consider having imageshack host them in retrospect >__>. I hassle Doug or chaos when X-Act or something else helps me figure out the above. (*note to self* stop relying on others for latex help normally so you aren't dumb =/)


(and if X-Act reads this, while I'm doing it anyway, do you want me to do Latex stuff for any of your guides with math in it? Just an offer)
 

X-Act

np: Biffy Clyro - Shock Shock
is a Site Content Manager Alumnusis a Programmer Alumnusis a Smogon Discord Contributor Alumnusis a Top Researcher Alumnusis a Top CAP Contributor Alumnusis a Top Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis an Administrator Alumnus
I can compile the LateX formulae when I get the chance. My LateX program (MikTeX, a freeware version) can convert a LateX document to .pdf. Then I can copy each formula using Adobe Acrobat and convert it to any image format using Paint Shop Pro.
 

Caelum

qibz official stalker
is a Site Content Manager Alumnusis a Community Leader Alumnusis a Smogon Discord Contributor Alumnusis a Tiering Contributor Alumnusis a Top Contributor Alumnusis a Smogon Media Contributor Alumnusis a Battle Simulator Moderator Alumnus
Oh nice. I knew you were busy with a bunch of various things so I didn't know if you'd be able to find time for this so I took it upon myself.

Anyway, just whenever you get around to it is fine and thanks.
 

Lorak

*leekspin*
is an Artist Alumnus
Do we know the Safari Zone formula for each generation yet? Effect of bait, rock, etc. quantified numerically.
 
I have a question regarding not the formulas itself, but rather manipulating them for one's own ends. As written in the LC article, the intended order of operations is rather confusing.

Here's what I've got so far, though:
1. Divide the number of EP in the stat by 4.
2. Floor the result.
3. Add double the Pokemon's base stat value.
4. Add the Individual Value in the stat.
5. Multiply by the Pokemon's level.
6. Divide by 100.
7. Floor the result.
8. Add X.
9. Multiply by the nature modifier.
10. Floor the result.

If this is correct, I wish to be able to solve for the individual value, and I'm not sure how one would go about doing so. On the other hand, if I did eventually get such an expression, I won't need those fancy calculators anymore.
 

Users Who Are Viewing This Thread (Users: 1, Guests: 0)

Top