.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $6.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 2: The Ascension Wars

Reply
 
Thread Tools Display Modes
  #61  
Old February 16th, 2005, 10:11 AM

Oversway Oversway is offline
First Lieutenant
 
Join Date: Feb 2005
Posts: 693
Thanks: 0
Thanked 0 Times in 0 Posts
Oversway is on a distinguished road
Default Re: Random Magic Paths - is it truly random?


Quote:
The only thing that bothers me, is the streakyness of some picks
But if you had a higher chance to pick a certain path because you hadn't gotten one in awhile, that wouldn't be random.
Reply With Quote
  #62  
Old February 16th, 2005, 02:46 PM
BigDaddy's Avatar

BigDaddy BigDaddy is offline
Second Lieutenant
 
Join Date: Feb 2005
Location: Central Illinois
Posts: 434
Thanks: 7
Thanked 3 Times in 3 Posts
BigDaddy is an unknown quantity at this point
Default Re: Random Magic Paths - is it truly random?

I'm inclined to believe the system IS random. I think anyone who doesn't think so, should just start a game and run a test with King of the deep or other applicable units. Hire like 200 of them and count them up. You may need 300 for checking all 8 paths. Don't play the game, just give yourself like 9 starting provinces and go to work. My results of 168 sea kings yielded 83 elemental picks and 85 sorcery picks. This yield no significant statistical difference from the null hypothesis.

Restrain yourself from trusting the tests of others if your test comes out more even. I apoligize in advance to anyone who feels insulted, but the probability of getting the 746 elemental paths to 675 sorcery paths is significantly <1%, so I had to either accept that the system wasn't random, or do a controlled test myself (whick i did, and drew my own conclusions). For instance, non controlled in game test may be skewed by using some random paths for blood hunting or less desireable one as troop ferries.
Reply With Quote
  #63  
Old February 16th, 2005, 03:42 PM
Bummer_Duck's Avatar

Bummer_Duck Bummer_Duck is offline
Corporal
 
Join Date: Jan 2005
Location: MN
Posts: 55
Thanks: 0
Thanked 0 Times in 0 Posts
Bummer_Duck is on a distinguished road
Default Re: Random Magic Paths - is it truly random?

Quote:
Don't play the game, just give yourself like 9 starting provinces and go to work. My results of 168 sea kings yielded 83 elemental picks and 85 sorcery picks.
All this tells us is the overall randomness. However, if the picks follow some sort of pattern, your conclusion will be wrong, even if it looks distributed. This is why I recorded each mage, in the order I recruited them.

I guess what I am saying is if you get 50 death mages in a row, then 50 blood mages in a row, etc, totalling them all up at the end will look like it is a random distribution, even though it was not. That was the main reason for my first post. I felt, and still do, that it is not completely random. I always seem to get "gaps" and 2-4 paths that have the majority of the random picks, at any given point. Testing on a large scale is somewhat irelevent, as you don't recruit 1000 mages (or I don't)

Again, this seems to be my perception...
Reply With Quote
  #64  
Old February 16th, 2005, 03:53 PM
BigDaddy's Avatar

BigDaddy BigDaddy is offline
Second Lieutenant
 
Join Date: Feb 2005
Location: Central Illinois
Posts: 434
Thanks: 7
Thanked 3 Times in 3 Posts
BigDaddy is an unknown quantity at this point
Default Re: Random Magic Paths - is it truly random?

Perception is difficult with the study of randomness. You have to repeatedly see the same pattern before you can assume the either random number generator or pregenerated random number table is flawed. I'm not sure which this game uses. Anyway, strings of mages are entirely likely. . . Kind of like a couple having 4 girls and no boys. The likelyhood of that is .5^4 or (6.25%).

If you want to test your hypothesis you need to document patterns. . .BBF ... BBF...

I don't think 1000 mages will produce much more significance than say 400, or even 300. Thats just the way significance works. I've misplace my statistics book, or I'd tell you exactly how to find significance, but trust me, you don't need 1000 mage, 300 will do.
Reply With Quote
  #65  
Old February 16th, 2005, 04:14 PM
BigDaddy's Avatar

BigDaddy BigDaddy is offline
Second Lieutenant
 
Join Date: Feb 2005
Location: Central Illinois
Posts: 434
Thanks: 7
Thanked 3 Times in 3 Posts
BigDaddy is an unknown quantity at this point
Default Re: Random Magic Paths - is it truly random?

Well, Bummer_Duck, you have to do larger scale tests to get any significance out of your test, like I said earlier about the likelyhood of a couple getting 4 girls and no boys, the likelyhood of getting a couple blood mages in a row is not that remote. The likely hood of getting 6 blood mages in a row is, however, quite remote .125^6=.00038%. Significance increase markedly for the first several units sampled, so you need a significant number of mages to make any judgement. If that doesn't suit your fancy, try hiring 20 mages after starting 10 new games and draw your results from there.

Even after 200 units 4 paths are very likely to have a "majority" of the picks, 2-3, however, are not.
Reply With Quote
  #66  
Old February 16th, 2005, 04:46 PM
BigDaddy's Avatar

BigDaddy BigDaddy is offline
Second Lieutenant
 
Join Date: Feb 2005
Location: Central Illinois
Posts: 434
Thanks: 7
Thanked 3 Times in 3 Posts
BigDaddy is an unknown quantity at this point
Default Re: Random Magic Paths - is it truly random?

I apologize for posting 3 time in a row, but I think I may need to expound on statistics and randomness, since it seems the topic may be misunderstood. Indeed parts of statistics are still theoretical, and it took until the middle ages before statistics was really a science.

First, remember that BEFORE you run a test you can estimate the probabilities of something happening, like 2 blood paths in a row (.125^2=1.54% chance), BUT in a random system the previous result does not effect the next result. So, after you recruit and get a blood path, the probability of the next recruit being a blood path is still 1/8. This is what makes next round projections impossible in a random system, and is why you need patterns to prove your hypothesis.

Also, it appears that significance is misunderstood. So:

Statistical Significance-the probability (P) that a sample (s) is representative of the population (S).

More simply the probability that the mages you hired are representative of all the mages that have been and ever will be recruited.

While demonstrating why large numbers of samples (recruits) are necessary is more difficult, a simple example can show why just a few recruits is not enough is quite simple.

So, if you hire just 1 mage, and assume it is representative of the population you'll get a result of 100% of mages belong to 1 path. Similarly if you hire just 8, and don't get mages of 2 paths, you could conclude that some paths recieve 0% of random picks. In a random system the likelyhood of these results declines with sample size (the number of mages recruited). In conclusion, simply take our word for it that you NEED to recruit many mages to draw any conclusions. Significance (alpha) can be found given population constraints (even for infinite populations), however, I've misplaced my book. I am quite experienced (and educated) in statistics and trust me that you do not need 10000 or even 1000 recruits to test a sytem with 7 degrees of freedom, 300-400 will be just fine.

I sincerely hope this helps.
Reply With Quote
  #67  
Old February 16th, 2005, 08:57 PM
Arralen's Avatar

Arralen Arralen is offline
Major General
 
Join Date: Nov 2000
Location: 500km from Ulm
Posts: 2,279
Thanks: 9
Thanked 18 Times in 12 Posts
Arralen is on a distinguished road
Default Re: Random Magic Paths - is it truly random?

You may be right, daddy, but you just quite don't hit the mark.

I'm 100% with Bummer here:
There are odd patterns in the randomly generated commanders skills.

But those patterns are so short, that they will not influence the overall result if you do several hundreds of test, e.g. 500 sages.
I estimate the sample size, where those patterns could be observed, is about 20.. 30. After that, the alghorithm produced the next pattern.

And the significance is not in the number of samples you get by buying sages in a test, but in how often this behaviour is observed in ongoing games. And I must state -again- that I have seen it way to often as to dismiss it as statistical oddities.

Hey, I have even got commanders which had the very same randomly drawn name, additionally to having the same magic skills.

And this behaviour is quite understandable, as we are not talking about a bunch of thown dice, but about complex programm code, whose behaviour isn't really suited to be discribed by statistical analysis but maybe by chaos theory

What if the RNG works great, but is -because of some flaw somewhere else- fed with exactly the same seeding value turn after turn, unless the numbers of orders in a turn is odd, in which case it uses the cross summ of all player 1 commmander names as seed for it's next sequence of random numbers?
You could buy sages for ages, and in the end you'll find perfect random skill distributions. But for 20 or 50 turns you may not get a single "blood" one, but alternating air and earth ones.
__________________
As for AI the most effective work around to this problem so far is to simply use an American instead, they tend to put up a bit more of a fight than your average Artificial Idiot.
... James McGuigan on rec.games.computer.stars somewhen back in 1998 ...
Reply With Quote
  #68  
Old February 16th, 2005, 11:08 PM
BigDaddy's Avatar

BigDaddy BigDaddy is offline
Second Lieutenant
 
Join Date: Feb 2005
Location: Central Illinois
Posts: 434
Thanks: 7
Thanked 3 Times in 3 Posts
BigDaddy is an unknown quantity at this point
Default Re: Random Magic Paths - is it truly random?

You have a 6.9% chance in any game to draw 20 random path mages in a row without getting a blood mage. An actual example of the strange behavior might be more helpful.

I must admit I'm skeptical about the odd behavior not being random. Random systems often spit out nearly patternlike garbage all the time, especially short patterns when the system has a low number of degrees of freedom. But then you never see that pattern again. If you just use a coin for instance you'll get lots of HHHT's, but that doesn't make the toss not random. A large number of degrees of freedom cut down significantly on the number of false patterns, but such a test is for the programmers not for us. Repeatedly getting commander with the same skills and names MIGHT be worrisome, but we were never told the name where random, plus I doubt much double checking was done on the naming system.

On the technical side, it is possible that your computer or operating system is limiting the randomness of the RNG (which would explain why some people are certain of the problem and others aren't so sure). Has anyone using a non-windows OS witnessed this problem?

Also, if the program uses a pregenerated random number list or table, you may very well find yourself in the midst of a pattern, but this type of problem is easily patched with a larger table and more complex seed starting position. This is an entirely plausible problem, but not one I have personally witnessed.

People are not able to generate random numbers themselves, its been shown. They have tendency to just pick a number they haven't picked for a while. It is far more likely for a computer or die to pick 1,2,3 but it is highly unlikely a human would ever do that (unless they knew that was a problem of course). All I'm saying is that human preception of random and actual randomness are quite different. It is also quite unlikely that computers are entirely random, but they are a lot better than people.
Reply With Quote
  #69  
Old February 17th, 2005, 07:49 AM
Saber Cherry's Avatar

Saber Cherry Saber Cherry is offline
Major General
 
Join Date: Oct 2003
Location: Crystal Tokyo
Posts: 2,453
Thanks: 0
Thanked 0 Times in 0 Posts
Saber Cherry is on a distinguished road
Default Re: Random Magic Paths - is it truly random?

Furthermore, unless I'm just up too late and should really go to bed now (probably true), it seems that the chances of 20 random picks missing a least one path (in other words, getting 20 consecutive sages and still not having 8 paths between them) is 43.6%, which is relatively high. Math:

1-((1-.0692)^8), where the .0692 is derived from the same calculation as above.

As far as RNGs go, I found a really nice one, called the Mersenne Twister. It is a software RNG, but the software actually finds stray radioactive particles in the dust on your CPU and monitors them for randomness. If you clean your case a lot the randomness goes down, which may explain some of the problems in this thread.

On the other hand... I just disassembled dom2.exe and got this little code fragment... maybe this is the problem?

Code:

public int rand(){
for(int i=0; i<100; i++){
if(seemsRandom(i)){return i;}
}
return secret_very_random_number;
}

public boolean seemsRandom(int x){
// note: add some stuff here before Dominions 3 is released
return true;
}

private int secret_very_random_number=42;

__________________
Cherry
Reply With Quote
  #70  
Old February 17th, 2005, 02:06 PM
The_Tauren13's Avatar

The_Tauren13 The_Tauren13 is offline
First Lieutenant
 
Join Date: Jul 2004
Location: Albuquerque, NM
Posts: 605
Thanks: 0
Thanked 0 Times in 0 Posts
The_Tauren13 is on a distinguished road
Default Re: Random Magic Paths - is it truly random?

roflmfao
__________________
Every time you download music, God kills a kitten.
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 04:41 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2024, Shrapnel Games, Inc. - All Rights Reserved.