code logs -> 2009 -> Fri, 04 Dec 2009< code.20091203.log - code.20091205.log >
--- Log opened Fri Dec 04 00:00:00 2009
00:02 gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has joined #code
00:07 Netsplit over, joins: Vornicus, simon`, @jerith, GeekSoldier, crem
00:07 Netsplit over, joins: EvilDarkLord, SmithKurosaki, KazWork, Namegduf, MyCatVerbs, Alek
00:09 You're now known as TheWatcher[T-2]
00:10 Netsplit *.net <-> *.split quits: Alek, Namegduf, SmithKurosaki, EvilDarkLord, MyCatVerbs, KazWork
00:10 * gnolam headdesks.
00:11
< gnolam>
One of my ugly hacks coming back to bite me in the ass. Who'da thunk it?
00:11
< Vornicus>
Gee.
00:12 Netsplit over, joins: EvilDarkLord, SmithKurosaki, KazWork, Namegduf, MyCatVerbs, Alek
00:13 You're now known as TheWatcher[zZzZ]
00:18 Derakon[work] [Derakon@Nightstar-d44d635e.ucsf.edu] has quit [[NS] Quit: Leaving]
00:27
< gnolam>
(I'm currently working on underwater rendering. To render the water surface I just switch to culling front faces and reverse the normal when calculating the cubemap reflection. For some reason, when I got below a certain (very shallow!) depth, everything got grayed out. I spent about an hour going over every line of my shaders before I realized it was the giant "extend to horizon" quads I put in place because I haven't implemented an adaptive
00:56 Derakon[AFK] [Derakon@Nightstar-5abd3ac9.ca.comcast.net] has joined #code
00:57 Derakon[AFK] is now known as Derakon
01:06
< Vornicus>
Hokay so. Headers now fixed; now I need to get /chapter and /section to pull themselves out of columns. This might be pretty easy, actually.
01:33 Attilla [The.Attilla@FBC920.398CA6.F5AD58.B7D1D3] has quit [Connection reset by peer]
01:49
< Vornicus>
Or not exactly. Got it, sort of, but now my body text is huge.
01:50
< gnolam>
That's just your distorted <body><img> talking.
01:50 * gnolam hides.
01:51 * Vornicus shoots gnomlam, points out that he's working in LaTeX
01:51
< Vornicus>
(also the font size is literally called \Huge, so)
01:58
< Vornicus>
There that goes. Okay.
02:01
< Vornicus>
Now that I actually have some idea of what LaTeX is actually capable of, these others will be relatively easy.
02:02 Kazriko [kaz@Nightstar-e09690fa.client.bresnan.net] has joined #code
02:29 Kazriko [kaz@Nightstar-e09690fa.client.bresnan.net] has quit [[NS] Quit: Leaving]
02:47 gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has quit [[NS] Quit: Z?]
03:31
< Derakon>
Holy blap, the Angband source is 137681 lines of C.
04:36
< Alek>
that actually sounds.... small. huh.
04:37
< Vornicus>
It's not very.
04:40 * Vornicus fiddles with LaTeX, is pretty sure he actually sort of gets it now.
04:51 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [[NS] Quit: Leaving]
04:53 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code
04:57
< Derakon>
Alek: for some perspective, Jetblade, counting all configuration modules, is just under 8k lines of Python. I expect that the finished game would be maybe two to three times that, tops.
05:16 * Derakon figures out how to automatically make every item in the game be identified when he finds it.
05:16
< Derakon>
So that's the first step of the tweak I wanted...the rest'll be harder, of course.
05:20 Thaqui [Thaqui@27B34E.D54D49.F53FA1.6A113C] has joined #code
05:26
< Derakon>
I note to my considerable dismay that the Angband source code uses tabs for indenting instead of spaces.
06:32 Derakon is now known as Derakon[AFK]
06:56
< McMartin>
Wow. I guess having state really helps.
06:56 * McMartin solves #126 in 90s, finds everyone else did basically exactly the same thing but solved it in several hundred ms instead.
06:57
< McMartin>
Including the Haskell code, which uses IOArray monads. Cheating!
07:16
< Vornicus>
Heh
07:33 AnnoDomini [annodomini@Nightstar-6ee2c5d2.adsl.tpnet.pl] has joined #code
07:54 * McMartin also blows out his RAM a few times before getting the lazy evaluation under control.
08:28 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [[NS] Quit: ]
08:30 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code
08:39
< Vornicus>
So, next target: make Problem, Subproblem, and Solution work together.
08:59 Rhamphoryncus [rhamph@Nightstar-a62bd960.abhsia.telus.net] has quit [Client exited]
08:59 You're now known as TheWatcher
09:03
< McMartin>
Hrm. There's gotta be a better way to do #127, but damned if I know what it is.
09:03
< McMartin>
The part where you actually factorize takes two seconds, and then dealing with the results seems to be taking upwards of half an hour.
09:03 Vornicus is now known as Vornicus-Latens
09:06
< Vornicus-Latens>
rad(abc) = rad(a) * rad(b) * rad(c), if you manage to get that first bit done.
09:08
< McMartin>
Yes.
09:08
< McMartin>
Assuming that they're all relatively prime. Which they are.
09:08
< McMartin>
And since the rad(abc) < c check is cheaper than the relatively prime check, you do it first.
09:08
< Vornicus-Latens>
Similarly you only need to check two pairs of relative primeness - the third is implied.
09:09
< McMartin>
It's more that (ignoring a couple of lame prefilters) there appear to be 7.2M candidates.
09:09
< McMartin>
And they seem to get noticably denser once c > 10000 or so.
09:10
< McMartin>
If 2*rad(c) >= c we can also discard that c instantly.
09:11
< Vornicus-Latens>
--only happens if radc is squarefree or almost.
09:12
< McMartin>
Yeah, like I said, lame filter.
09:12
< Vornicus-Latens>
lame.
09:12
< McMartin>
But I see no guarantee that any larger factor won't possibly miss things.
09:12
< McMartin>
I don't see why you only have to check two pairs though, in the general case. 2, 3, 15 has ab and ac but not bc, and 2, 3, 8 has ab and bc but not ac.
09:13
< Vornicus-Latens>
Because you won't get either of those!
09:13
< Vornicus-Latens>
You'll get 2, 13, 15, or 3, 12, 15.
09:14
< McMartin>
While it is true that I won't get either of those, I have no a priori reason to believe that a property of sums will have any bearing on a property of division.
09:14
< Vornicus-Latens>
If a and c are relatively prime, then... oh, shit, I think you can do /only one/ gcd and have it work.
09:14
< McMartin>
Unless there is, in fact, a proof that if a and c are relatively prime then a and (c-a) are relatively prime and (c-a) and c are.
09:14
< Vornicus-Latens>
There is!
09:15
< Vornicus-Latens>
In fact it is embedded in Euclid's original algorithm - which was repeated subtractions, not division with remainder.
09:16
< McMartin>
Even so, that sounds like it's not going to be a particularly huge improvement. It would be, at best, a 75% speedup.
09:16
< McMartin>
That isn't nearly enough to make this finish in under a minute.
09:16
< McMartin>
I suspect the existence of a better filter.
09:16
< McMartin>
*pre-filter, rather.
09:17
< McMartin>
(Asymptotically, it's going from n^2 log n to n^2, which is real, but still kind of laughable.)
09:17
< McMartin>
(I'm guessing there's something that drops it to O(n) or below.)
09:17
< McMartin>
Also assuming I'm correctly remembering that gcd is O(log n).
09:18
< Vornicus-Latens>
If two numbers share a factor then you can, in any addition or subtraction involving those two numbers, factor that out - and you're left with integers, and the integers are closed, so the result (once you pull the factor back in) is integer.
09:19
< Vornicus-Latens>
er, also shares the factor.
09:19
< Vornicus-Latens>
You're right, it's not much improvement. Except...
09:22 * McMartin 's dumb version is up to all values where c is below 83,000 now.
09:22
< Vornicus-Latens>
Hm, how would I actually end up doing this? c, having been factored, can be placed in a bunch of seive piles; you can then take a set of possible a values and, instead of gcding, just difference out the lower gcds.
09:22
< McMartin>
Seives are, of course, made of inconceivable sadness in Haskell.
09:23
< Vornicus-Latens>
:(
09:23
< McMartin>
I'm currently using a princely 13MB of memory for all my data structures, and they're all firmly write-once except for the actual output stream.
09:24
< McMartin>
The other thing is that performing the seive would end up being at least as if not more expensive than just doing the linear check.
09:24
< McMartin>
Because you'd be doing set subtraction. Which is O(n).
09:25
< McMartin>
Which is the same as a list filter.
09:26 * Vornicus-Latens asks Wolfram Alpha.
09:26
< McMartin>
The trick is almost certainly in the choice of a, though, not c. I'm watching my results scroll by and it looks like perhaps one in three values of c actually has at least one abc-hit in it.
09:26
< McMartin>
And they have *lots*.
09:28
< McMartin>
c = 88625, for instance, has 17,465 corresponding abc hits, assuming my algo isn't buggy.
09:28
< Vornicus-Latens>
mcwhut
09:29
< McMartin>
(And it got the right answer for c<1000, so...)
09:29 * McMartin is now past 90k.
09:29 * McMartin is still only using 3% of his 512MB of RAM.
09:32
< McMartin>
I guess they're rarer than Pythagorean Triples, but.
09:33
< Vornicus-Latens>
Triples at least you can generate.
09:34
< McMartin>
Yeah, and it won't surprise me if you can generate these too.
09:34
< McMartin>
(96k)
09:39 * Vornicus-Latens actually goes to bed.
09:53 ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has quit [Operation timed out]
10:00 Attilla [The.Attilla@FBC920.398CA6.F5AD58.B7D1D3] has joined #code
10:20 Thaqui [Thaqui@27B34E.D54D49.F53FA1.6A113C] has quit [Connection closed]
10:20
< AnnoDomini>
It seems that the new euphemism for failing a test is 'join the Jedi Academy' in my Uni.
11:07 MyCatSchemes [mycatverbs@Nightstar-3b2c2db2.bethere.co.uk] has joined #code
11:28 gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has joined #code
11:36 Tarinaky [Tarinaky@Nightstar-7b0c05ad.adsl.virginmedia.net] has quit [Operation timed out]
11:41 ToxicFrog [ToxicFrog@ServerAdministrator.Nightstar.Net] has joined #code
11:50 Tarinaky [Tarinaky@Nightstar-cd385d3b.adsl.virginmedia.net] has joined #code
12:05 AbuDhabi [annodomini@Nightstar-bbe88297.adsl.tpnet.pl] has joined #code
12:07 AnnoDomini [annodomini@Nightstar-6ee2c5d2.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
12:25
< simon`>
I wonder why they think Jedis fail tests.
13:39
< AbuDhabi>
Microsoft products are shit.
13:39
< AbuDhabi>
That is all.
13:47
< simon`>
there are six palindrome unixtimes from now and a week ahead
14:06
< gnolam>
Oh, evil Satan
14:06
< gnolam>
oscillate my metallic
14:06
< gnolam>
sonatas live, ho!
14:21 Tarinaky [Tarinaky@Nightstar-cd385d3b.adsl.virginmedia.net] has quit [Ping timeout: 121 seconds]
14:24 crem [moo@Nightstar-8ca3eea7.adsl.mgts.by] has quit [Client closed the connection]
14:29 crem [moo@Nightstar-8ca3eea7.adsl.mgts.by] has joined #code
14:35 AnnoDomini [annodomini@Nightstar-13a67611.adsl.tpnet.pl] has joined #code
14:35 Tarinaky [Tarinaky@Nightstar-2b47a2d9.adsl.virginmedia.net] has joined #code
14:37 AbuDhabi [annodomini@Nightstar-bbe88297.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
14:40 AbuDhabi [annodomini@Nightstar-1e44073d.adsl.tpnet.pl] has joined #code
14:42 AnnoDomini [annodomini@Nightstar-13a67611.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
14:46 AnnoDomini [annodomini@Nightstar-a8ece2d3.adsl.tpnet.pl] has joined #code
14:48 AbuDhabi [annodomini@Nightstar-1e44073d.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
14:50
< gnolam>
Oh hey, Bing is actuall better than Google for searching for C++ stuff. The ++s appear to have actual meaning.
14:50
< gnolam>
+y
14:51 AbuDhabi [annodomini@Nightstar-7f100388.adsl.tpnet.pl] has joined #code
14:51 AnnoDomini [annodomini@Nightstar-a8ece2d3.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
15:14 Tarinaky [Tarinaky@Nightstar-2b47a2d9.adsl.virginmedia.net] has quit [Ping timeout: 121 seconds]
15:20 AnnoDomini [annodomini@Nightstar-f75657b1.adsl.tpnet.pl] has joined #code
15:22 AbuDhabi [annodomini@Nightstar-7f100388.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
15:25
< Attilla>
Maybe it will also recognise other punctuation.
15:28 Tarinaky [Tarinaky@Nightstar-41f555ed.adsl.virginmedia.net] has joined #code
15:30 AbuDhabi [annodomini@Nightstar-b87577af.adsl.tpnet.pl] has joined #code
15:32 AnnoDomini [annodomini@Nightstar-f75657b1.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
15:41 Tarinaky [Tarinaky@Nightstar-41f555ed.adsl.virginmedia.net] has quit [Ping timeout: 121 seconds]
15:55 Tarinaky [Tarinaky@Nightstar-52356a03.adsl.virginmedia.net] has joined #code
16:02
< gnolam>
But the main thing is that it doesn't distract med with shitty DHTML.
16:08 * gnolam stabs Google some more for putting the final nail in e-mail etiquette's coffin.
16:14
< Attilla>
At least it's not XHTML! :V
16:14
< Attilla>
Let's have a clock... THAT FOLLOWS YOUR POINTER
16:15
< simon`>
I hate email
16:16
< simon`>
gmail's web interface has made me forget how horrible email is, but now that I've tried getting a client up and running, I realize how dissatisfactory the clients I know are.
16:22 * AbuDhabi uses the old HTML interface on Gmail.
16:34
< gnolam>
You're pretty much forced to, if you want it to run at any speed. :P
16:39
< gnolam>
Attilla: Err... what?
16:46
< Attilla>
Some random XHTML scripts I recall when I first started doing html in secondary school, this one site had tons of them
16:47
< Attilla>
Including an ASCII clock that followed your cursor around
16:48
< gnolam>
Err... XHTML is just HTML with stricter XML markup.
16:50
< Attilla>
fine, I meant DHTML?
16:53
< gnolam>
Yes.
16:53
< Attilla>
Huh, that's what you mentioned. Then fine :|
16:53 * Attilla harumphs
17:02
< gnolam>
Javascript - the scource of the World Wide Web.
17:02
< Alek>
scourge
17:03
< gnolam>
... yes, thank you.
17:04
< gnolam>
Need more caffeine.
17:04
< gnolam>
SPAWN MORE TEA
17:05
< AbuDhabi>
It's not like tea grows on trees.
17:10
< Alek>
oh wait...
17:11
< Alek>
¬_¬
17:19 Rhamphoryncus [rhamph@Nightstar-a62bd960.abhsia.telus.net] has joined #code
18:02
< gnolam>
There. Finally got my meeting minutes transcribed and uploaded.
18:02
< gnolam>
Now: to seek compensation.
18:05
< gnolam>
Only I have no idea how to do so. Hmm.
18:28 SmithKurosaki [Smith@Nightstar-e2478917.cable.rogers.com] has quit [Ping timeout: 121 seconds]
18:28 SmithKurosaki [Smith@Nightstar-e2478917.cable.rogers.com] has joined #code
18:45 AgentIchiro [Smith@Nightstar-f933638e.dsl.teksavvy.com] has joined #code
18:45 SmithKurosaki [Smith@Nightstar-e2478917.cable.rogers.com] has quit [Ping timeout: 121 seconds]
18:46 AgentIchiro is now known as SmithKurosaki
18:49 MyCatSchemes [mycatverbs@Nightstar-3b2c2db2.bethere.co.uk] has quit [[NS] Quit: Leaving]
20:10
< McMartin>
Oy. I was getting wrong answers due to internal integer overflow. Silliness.
20:18
< simon`>
hehe
20:28 Thaqui [Thaqui@27B34E.D54D49.F53FA1.6A113C] has joined #code
21:20 * McMartin solves #127, reads the real solution
21:20
< McMartin>
It's got a stateless one, but I cannot comprehend it.
21:20
< McMartin>
It's a single list comprehension with ten lines of generators and conditions, and uses some syntactic constructs I didn't know Haskell even had.
21:33
< Rhamphoryncus>
Bah. That's just storing the state on the stack and in temporaries
21:38
< McMartin>
"stateless" means "directly mutable state".
21:38
< McMartin>
SSO with reuse of physical memory locations in compiled code still counts as stateless even if it compiles to an identical binary.
21:54 crem [moo@Nightstar-8ca3eea7.adsl.mgts.by] has quit [Client closed the connection]
22:00
< AbuDhabi>
What is the purpose of Reset buttons in online forms?
22:01
<@TheWatcher>
To reset the contents of the form fields to the value specified in the value attributes when the form was sent
22:02
<@TheWatcher>
When the fields are empty initially, it's kinda pointless. But sometimes fields come prefilled, and resetting back to those values can be useful sometimes.
22:02
< AbuDhabi>
Wow.
22:02
< AbuDhabi>
And here I thought it was just there to annoy users.
22:03
< AbuDhabi>
Maybe it's its placement.
23:06 Thaqui [Thaqui@27B34E.D54D49.F53FA1.6A113C] has quit [Connection closed]
--- Log closed Sat Dec 05 00:00:01 2009
code logs -> 2009 -> Fri, 04 Dec 2009< code.20091203.log - code.20091205.log >