Taketrung / betting-ai

Automatically exported from code.google.com/p/betting-ai
1 stars 1 forks source link

SPIKE - bets matching using Double datatype #29

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
As a developer
I want to test bets matching using Double data type
So that I can take decision on data type used for bets matching
As proven by analysis report

Original issue reported on code.google.com by daniel.k...@gmail.com on 11 Jun 2010 at 11:27

GoogleCodeExporter commented 9 years ago
Bet price is represented by a double data type that is an approximated number. 
Comparing double numbers is not easy, for example numbers that cannot be 
represented as double precisely, have to be compared using +-delta. The other 
approach to compare bet prices is to use Integer data type, multiplying price 
by 100. For example instead of having the price of 2.24, we would write 224 = 
2.24*100.

This story is to investigate, which representation is better: double or 
integer... or  maybe there is something else.

Original comment by daniel.k...@gmail.com on 11 Jun 2010 at 11:39

GoogleCodeExporter commented 9 years ago

Original comment by daniel.k...@gmail.com on 26 Jul 2010 at 4:04

GoogleCodeExporter commented 9 years ago
Whether or not floating numbers should be used to represent bet price and bet 
size is not a simple question. For now it was decided to stay with double type. 
Further investigation may be required in the future.

Original comment by daniel.k...@gmail.com on 28 Jul 2010 at 4:48