[00:50] MSG: Read error: Operation timed out [01:01] Join: Mizcu joined #corewars [01:12] Join: Caelian_ joined #corewars [01:15] MSG: Ping timeout: 240 seconds [05:43] MSG: Read error: Operation timed out [05:54] Join: Mizcu joined #corewars [07:35] now that bvowk has mastered Nethack, maybe he could try defeating the current speed-slogging record in it ;) [07:35] (6480 turns) [08:05] Nick Change: Caelian_ changed nick to Caelian [09:40] MSG: Ping timeout: 240 seconds [09:48] Join: Fluffy joined #corewars [11:04] Join: fiveop joined #corewars [12:30] Join: Core_old joined #corewars [13:19] Part: Core_old left #corewars [15:27] someone alive? [15:31] (hmm, this question would make an interesting mini-challenge to redcode..) [15:31] lol [15:33] but seriously: i have X numbers, and i have to divide them into two groups, which have the same sum of numbers, or as close as possible. What would be good method to approach this problem (in C)? [15:33] (Not related to evolver-project) [15:34] which both have the same number when numbers within are summed.. [15:35] * pak21 starts thinking [15:35] How big is X? [15:36] i dont need exact code as result, but lets say >10, less than INT [15:37] Do you need the best solution, or just a "good" one? [15:37] first thought was to put all the numbers in one array, sort the array, then separate numbers as ABABAB.. , check the separation of numbers in A & B, then swap two numbers in A & B which are closest to the difference [15:37] i am just improving my way of thinking, doesnt need to be best [15:38] The first thing I'd do is run over the (unsorted) data. Add the next number to whichever set is currently smaller. [15:38] If X is moderately large and your numbers aren't pathalogically distributed, that shouldn't be too bad. [15:39] Do your two sets have to be the same size? Your algorithm would guarantee that, but mine wouldn't. [15:41] if the numbers inputted are not known, its hard to divide them into groups with exact same sum-content [15:41] so some difference should be expected [15:43] i met this when doing little research into data-compression, and Shannon-Fano coding does similiar operation before creating a binary tree [15:43] MSG: Quit: Lost terminal [15:44] ~ [15:45] i wonder if Neo could put up that as a minichallenge, create a redcode-program that sort ~handful of numbers to two such groups [15:45] You've now got me thinking about the knapsack problem, which quite closely related to me. [15:48] s/which/which seems/ [15:49] there is probably something in the knapsack-problem i did get with 10 second look in wikipedia [15:50] Is what you're doing essentially the knapsack problem with a knapsack of size (total of numbers/2)? [15:52] yes, with two sacks with as even "weight" as possible [15:53] So there's probably some code out there to do this for you. Problem solved :-) (sort of anyway) [15:54] Shannon-Fano coding for published in 1948, so i would be pretty damned if it wouldnt have been already coded [15:54] for -> was [15:55] I wasn't sure how similar the "similar operation" S-F coding does was to your problem. [15:58] i have to say i find data compression facinating, but i dont have the mathematical head to churn it out, big interesting in coding to smack it out, and its not something to make a job out of. [15:59] darn lazy online-dictionary, facinating -> fascinating [16:00] * pak21 looks up S-F coding [16:02] I'm sure there's a relation between what you're thinking about and why Huffman coding is better than S-F coding. [16:02] But I'd need my information theory textbook to do some more thinking, and that's at home... [16:02] But as it's 17:00 here :-) [16:03] Join: John joined #corewars [16:04] Wikipedia's page on Huffman Coding is written a bit too academic to my favour, but i am getting the idea what is happening in it [16:04] flavouir [16:04] Hi :-) [16:04] Compression? [16:04] F_l_a_v_o_(u_)r [16:04] my headtionary is stuck [16:04] yes, little bit of compression research [16:06] It may be too academic again, but I'd strongly recommend David MacKay's textbook [16:06] So long as you don't mind Bayesian statistics [16:07] I implemented some compression stuff once [16:07] I always thought Burrows-Wheeler transforms are pretty neat [16:07] I did the same (while taking David's course :-) ) [16:08] I even won a frisbee for pointing out mistakes in the book :-) [16:08] Neat :-) [16:09] I have to say that i find BW-transform kind of dubious. [16:09] It is provably efficient, but there is probably better way of getting the same results without mashing the data through 20 magical foodmills [16:11] * pak21 goes home - may be back online soon, but no guarantees... [16:34] * pak21 is back, at least briefly [16:45] Arithmetic coding uses range 0-1 when encoding; how about switching it to 0-360 and encode it to Sine-wave? [16:45] and then smack it with FFT? [16:46] (just throwing ideas, i wont be studying Fourier transform yet for some time) [16:48] not that the resulting wave would be any good transmitted wireless over one meter.. [17:16] Join: Fizmo joined #corewars [17:16] hi hi [17:16] hiya [17:16] hi Miz [17:21] Hi Christian [17:22] Hi John [17:35] need to leave now [17:35] * Fizmo waves [17:35] Time for me to go too [17:36] * John waves [17:36] MSG: Quit: mov.i #1,1 [17:36] byebye [17:36] MSG: Quit: ChatZilla 0.9.78.1 [Firefox 2.0.0.3/2007030919] [19:15] MSG: Quit: Ex-Chat [19:35] Join: fiveop joined #corewars [21:08] Join: ares_ joined #corewars [21:10] MSG: Ping timeout: 240 seconds [21:45] Join: Caelian joined #corewars [21:49] MSG: Quit: Lost terminal