Behind the scenes, Pokémon GO does a LOT of math. Being very geeky, I decided to get into what the formulas were for a lot of stuff. A large amount of the data on this site is calculated using these formulas.
I have included them here in case you are geeky too.
Pokémon have scores called "CP" and "HP". But what do they mean?
This page tells you about them and shows the formulas used to calculate them.
Want to know how to figure out the DPS for a Pokémon's Move Set?
This page goes into detail of describing the formulas used to figure that out.
When calculating how much damage a Pokémon will do, Pokémon GO takes into account the Level of the Pokémon. It does this by multiplying the Pokémon's BaseAttack and Attack IV by a constant corresponding to the Pokémon's level.
This page lists the CPM values.