Alright so I will try and give you a "good" answer for your question but I believe Evening and Bobbias both already gave you one.
Your pp is always based on how hard the song is, the harder the song is in terms of Star Raiting, Lengh and other minnor factors, the more pp you will get from those.
The main thing (and the hard one to understand) is that you WONT get the 100% of the raw pp value of each song. Instead, the system used is based on % of each amount of top-scores that the player have (thats to avoid point farming and PP abuse, if you get the 100% raw pp for all the maps you will probably see 100k pp players).
I will give you an example about my taiko performance:

As you can see my top rank is valued in 215 pp and I get the 100% of that value to my overall pp for that gamemode. But you can also see that the #2 song in the list (Heavenly Moon) is worth on 199pp but it only gives me the 95% of it. This is, like I said, a way to avoid pp farming by playing every single set currently ranked. Avalon is an Inner Oni so it is harder, have more Star rating so it gives more pp.
When you have a lot of good plays in your list everyone will start giving you a lower amount of the raw amount of pp. For example, the last one of that list is valued in 159 and I just get the 49% of it.
So for example, if you have a 30 pp play in #2 of your top plays, it will give you a 95% of it only. Everytime you get a new top score, all the lower ones will give you less amount of pp so its hard to calculate how much you will recive most of the times. Looking at the amount of the play valued on % is usualy close enought.
When it comes to mania is exactly the same thing (just that combo doesnt really matter). Of course, if you play 7K you have more notes so its posible to create harder patterns and it will bring more Star Rating to the set so playing that particular keymode will -usualy- give you more amount of PP. Its always related to how hard the song is tho.
I hope this is useful for you and if you have any questions you can still ask them here. If you have no more questions please send me PM or a message in-game to lock this topic. Good luck playing!