After much facepalmery I finally decided to read the rest of this line
iResearchBuffer *= GC.getGameSpeedInfo(GC.getGameINLINE().getGameSpee dType()).getResearchPercent();
..... and realised that its the game speed tech cost multiplier, as in 67 for quick, 100 for normal speed, 150 for Epic, and 300 for marathon, explains where the /100 vanished to
Pretty sure i've got this figured out now.
The amount of gold they are willing to trade is the lowest value of either the iMaxGold in the spoilered code below
Or this
which is
AIs total gold - (12*defecit * Speed modifier)/100.
The actual slider percentage is irrelevant
The iMaxGold I mentioned earlier acts as a cap defining the absolute max the AI is willing to trade away in a turn, even if they had more. Its calculated by
((AI Total Population * (Turns since you met the AI + 10) * iMaxGoldTradePercent)/100) - the gold the AI has traded to the player
Turns since meeting is found by (current turn number - number of turn you met), so on the turn you actually meet them this is zero.
iMaxGoldTradePercent is an AI personality number found in the XML, each AI has either a 5 or 10 value for it and if theres any interest i'll table them up and post it.
The final max gold the AI is willing to trade is the lowest result of these two formulae rounded down to the nearest 10.
Unfortunately screenshotting isn't working for some reason so heres an example thats easy to calculate, and easy to test in WB.
If at turn 0 you have met an AI with a iMaxGoldTradePercent of 10 (Churchill is one example) and 2000 gold with a 1 pop city then we get
Gold available to trade = (Pop (1) * (turns known (0) + 10) * MaxGoldTradePercent (10))/100 - 0 gold traded to us
Simplified 1*10*10/100 = 1
Which when rounded down leaves 0....
We can also find the population required to allow him to trade 50 gold on turn 1
50 = Pop * 10 * 10/100
Pop = 50/1 = 50