00:02:40 And obviously we don't know about the rest of the system, what you do with the Unix-timestamp-corresponding-to-the-most-recent-Manila-midnight-that-has-already-happened. 00:02:50 :t (**) 00:02:51 forall a. (Floating a) => a -> a -> a 00:02:58 Hmm. Let's put this vaguely algebraically: Manila = UTC + 8 hours. Now, if you have the UTC time 12:00 and want that in Manila time, you add 8 hours. If you have the Manila time 12:00 and want that in UTC time, you subtract 8 hours (obviously). 00:03:17 fizzie: looks like Dagoth-Ur showed up in Arena too 00:03:31 Hrm. That's not quite helping... 00:03:35 Lessee. 00:04:29 pikhq_: The simplest prose-style explanation I can make for the "clamp to midnight, subtract eight" rule is: "clamp to midnight" represents UTC 00:00:00; after you subtract eight hours, it represents UTC 16:00:00; any UTC 16:00:00 time will be a Manila 00:00:00, because it's UTC+8. 00:04:42 fizzie: Right, that's a bit better. 00:04:52 myndzi: ^ 00:04:58 But I did try that out earlier and it didn't help, so it probably won't now, either. 00:05:41 Jesus are you still explaining counting to myndzi. 00:08:29 -!- oerjan has quit (Quit: Clearly you are doomed, good night.). 00:09:12 Anyway, if you look at Manila time of 04:00, the corresponding UTC time is 20:00 (subtract eight hours). When you clamp to midnight, you're subtracting 20 hours; so the UTC midnight will be Manila time 04:00-(20 hours) = 08:00. You will need to subtract 8 hours from that to get a midnight in Manila. (But it will be the midnight of the previous day, because you will be subtracting a total of 28 hours.) 00:10:21 For Manila 12:00, corresponding UTC is 04:00. Clamp to midnight means subtracting 4 hours. That UTC midnight is Manila time 08:00. Again, you will need to subtract 8 hours to get a midnight in Manila, and will end up subtracting a total of 12 hours, and you get the midnight of "today" in Manila. 00:12:26 In fact, any UTC midnight is going to always be 08:00AM in Manila, that's what UTC+8 means. If you want a midnight in Manila, you must subtract eight hours, or add 16. 00:13:36 myndzi: *drumroll* 00:13:43 (THIS IS EXCITING OKAY) 00:14:14 i'm writing. be patient 00:14:21 :'( 00:14:44 I'm not going to be awake to see how this ends, sadly; it's past 02am here. 00:14:54 there'll be a link for you tomorrow 00:14:55 :) 00:15:04 sorry for the frustration i've caused, thank you for your efforts 00:15:09 * elliott awaits eagerly. 00:16:52 (It is 02:15AM here in UTC+2. Currently it's 00:15AM in UTC. If you do a "clamp to UTC midnight" operation, you will subtract 15 minutes, so that time in my timezone will be 02:00AM. You'll need to subtract 2 more hours to get a local midnight. Substitute 8 for 2 for Manila. Sorry, couldn't resist.) 00:18:11 :D 00:19:02 (Current Unix timestamp is about 1322871375. 1322871375%86400 = 975, about 16 minutes. If you subtract that from current time, it's about 02am here. You will need to subtract further two hours from the Unix timestamp to get a Unix timestamp value that corresponds to our midnight. Sorry, couldn't resist that either.) 00:19:06 Okay, seriously. -> 00:22:32 (When the time was "today, 01:00am" here in Finland, it was 23:00 in UTC. If you clamped that timestamp to previous UTC midnight, you'd end up subtracting 23 hours, leading to "yesterday, 02:00am". Then you could subtract two more hours to get a local midnight, but it would be "yesterday, 00:00", a day earlier than you wanted. This might explain the issues you mentioned.) 00:22:38 Seriously for reals now. -> 00:22:39 -!- derdon has quit (Remote host closed the connection). 00:26:27 myndzi: I think fizzie is trolling you. 00:28:55 (If it was "today, 01:00am" here, and you wanted to round to local midnight, you could (I'm not sure I would): add two hours to the timestamp, so you'd have a Unix timestamp that'd translate to UTC 01:00am; a different instant in time, yet same in local time. Then clamp to UTC midnight, which would end up subtracting the "proper" one hour. Then you would reverse the initial "time zone conversion" by subtracting two hours, and end up with local "today, 00:00", U 00:28:55 TC. That sort of thing would work, though the idea of having Unix timestamps that represent time instants that have the "local time" value when converted-to-display-as-UTC is a bit iffy. But if you're doing something like that, it does work.) 00:29:06 No, maybe some of that stuff might actually help. 00:29:27 I mean, after talk of "timestamps in local time", it's not inconcievable it could be something like that. 00:30:28 fizzie: Hi. 00:32:21 (But I'm still pretty sure if you just get current time() value, round to previous multiple of 86400, then; (a) subtracting K hours will give a local midnight in the UTC+K timezone, but it could be the "wrong" midnight; and (b) adding K hours will not give a local midnight, assuming K is not 12; at least as long as the resulting value is treated as a real Unix timestamp and converted to local time properly.) 00:32:28 Okay, maybe I really should go. 00:32:53 `finger 00:32:55 ​/home/hackbot/hackbot.hg/multibot_cmds/lib/limits: line 5: exec: finger: not found 00:33:00 ... 00:33:39 What does "..." even mean? You say it so often. 00:34:09 -!- DCliche has joined. 00:34:57 ellipsis 00:35:21 That's not what it means, that's what it is. 00:35:33 In this case, 00:35:40 why doesn't finger exist? 00:35:44 * Phantom_Hoover → sleep 00:35:47 -!- Phantom_Hoover has quit (Quit: Leaving). 00:35:55 'Cause it's not installed? 00:35:58 \$ finger 00:35:59 bash: finger: command not found 00:37:38 -!- Ngevd has quit (Ping timeout: 252 seconds). 00:37:40 (Also even after all this thinking, if I were making a "production" system, I'd seriously consider testing my thing at Manila local times of 04:00, 12:00 and 20:00, and checking that mycode(now()) approximately equals now()-4*3600, now()-12*3600 and now()-20*3600, respectively. Assuming now() returns current Unix timestamp, and mycode() is supposed to return a Unix timestamp corresponding to local midnight.) 00:37:41 -!- Klisz has quit (Ping timeout: 255 seconds). 00:37:48 `log \.\.\. 00:37:53 2010-10-22.txt:21:21:13: pikhq: Sure, neither of us can watch that, but... 00:38:15 fizzie: Having fun are we? 00:38:23 elliott: So much! 00:48:18 -!- GreaseMonkey has quit (Quit: The Other Game). 00:48:27 fizzie: I hope you're not still here. 00:50:32 Nooo... 00:51:52 -!- elliott has quit (Remote host closed the connection). 00:52:47 -!- elliott has joined. 00:53:09 fizzie: Keep not being here, then. 00:53:22 fizzie: (But I don't think myndzi is still here.) 00:54:11 -!- HalfTauRSquared has changed nick to PiRSquared17. 00:58:07 But I'm unsure why not: 1. Get current Unix timestamp. 2. Convert timestamp into a broken-down structure with 'year', 'month', 'day', 'hour', 'min', 'sec' members in timezone of interest; pretty much any language can do that. 3. Set hour = min = day = 0. 4. Convert structure to Unix timestamp. 5. Use result for DB query. 00:58:19 So simple there's no many places to go wrong; is easy to change the target timezone; and (major win?) works also for the large parts of the world that do the stupid DST thing, even during the changeover days. 00:58:33 Except I mean hour = min = sec = 0. 00:58:43 Seconds, days, who cares. 00:59:15 fizzie: I think it's because it looks like WHERE foo > ((bar - nonsense) + lol). 00:59:41 So it'd be either (a) actually learning SQL's trivial timezone facilities (which would take 5 minutes, as opposed to the 2 days invested so far; clearly unworkable, this is the Easiest Way) or (b) another round-trip. 00:59:51 I... guess it could be that. 01:00:05 fizzie: Well, *he* claims it's because he doesn't know much SQL. 01:00:50 -!- hagb4rd has quit (Quit: Nettalk6 - www.ntalk.de). 01:01:31 fizzie: How does one go from an SDL_Surface to its PixelFormat :P 01:01:33 If it's a programming language doing the thing, it doesn't need SQL. Though I suppose it could be that it's just a fixed query without parameters or something. 01:01:51 Uh, maybe you needed to lock it first? 01:01:56 fizzie: Well, what I meant is that foo and bar are both columns. 01:01:59 nonsense and lol being constants. 01:02:08 Also, eh? 01:02:55 The PixelFormat for the screen surface might be allowed to change. Maybe. Well, maybe not. 01:03:24 fizzie: Yes, but how do I get at it? 01:04:43 Uh, surface->format? 01:05:01 fizzie: Hmm. A thing that seems to be gleefully unexposed through the Haskell binding. I swear I've solved this problem before. 01:05:15 Ah, right, the binding. 01:05:25 I vaguely recall something about it too. 01:05:27 If only I remembered how. 01:05:31 Maybe I'll gerp. 01:05:32 grep. 01:05:41 Someone make a grep alterantive called gerp, that won't be confused at all. 01:05:44 So many tpyosk. 01:07:25 surfaceGetPixelFormat :: Surface -> PixelFormat 01:07:46 From the docs of Graphics.UI.SDL.Types. 01:08:29 Oh. 01:08:31 That might work. :p 01:08:42 fizzie: (A pure function...?) 01:09:08 Yeah, that's a bit funny. 01:09:32 surfaceGetPixelFormat surface 01:09:32 = unsafePerformIO \$ 01:09:33 withForeignPtr surface \$ \ptr -> 01:09:33 newForeignPtr_ =<< (\hsc_ptr -> peekByteOff hsc_ptr 4) ptr 01:09:39 Yeah, real pure. 01:10:04 fizzie: Well, there's nothing wrong with that for immutable fields. 01:10:12 You just said it could change is all. 01:10:22 I guess it doesn't. 01:10:36 After all, setvideomode returns a new screen surface. 01:10:46 Right. 01:11:05 Now to figure out why SDL-gfx circles are cyan despite being drawn with a white colour. 01:11:06 It is "read-only" in the SDL_Surface struct doc. 01:11:21 I have a feeling the answer may be very 90s. 01:12:22 ARGB <-> RGBA sort of mishaps can easily get cyan, but I guess there were mapping functions that took a PixelFormat. 01:12:54 white <- SDL.mapRGB (SDL.surfaceGetPixelFormat surf) 255 255 255 01:12:54 SDLP.box surf (SDL.Rect 10 10 10 10) white 01:13:01 is what it looks like now after changing circles to boxes :P 01:13:20 Which generates a single cyan pixel. *sign* :/ 01:13:34 Well, that certainly looks like it should be someone else's problem to make work right. 01:14:21 Maybe the lazy language made libSDL lazy too, and it couldn't be arsed to fill more bytes. 01:14:26 Heh. 01:14:31 Well, SDL-gfx is nothing "official", is it? 01:14:42 All these things are so dormant because nobody actually does software rendering in 2011. 01:14:53 And if they do they don't use wuss drawing libraries to do it. 01:16:34 fizzie: ARGB? 01:16:38 someone uses that? 01:16:39 why? 01:17:13 Why's mapRGB 'IO Pixel' anyway? I don't think PixelFormat structures ever change. (Though don't quote me on that.) ((Actually, come to think of it, the palettes probably are mutable.)) 01:17:23 Vorpal: I don't think it's any mor 01:17:31 fizzie: any mor? 01:17:31 e unnatural than RGBA. 01:17:33 ah 01:17:34 -!- zzo38 has joined. 01:17:49 fizzie: RBGA is just the normal way of doing it though afaik 01:17:55 elliott: I believe people mostly use sdl to get a opengl context these days, and sound of course 01:18:11 Also you get to write 0xaabbcc without having to add an explicit 00 if you don't-care about alpha. 01:18:20 heh 01:18:54 Vorpal: Sound? OpenAL these days, surely. 01:19:06 fizzie: nevertheless, ARGB is seldom seen when drawing stuff. Maybe in file formats? I don't know. 01:19:23 It's all /Open.L/ nowadays. 01:19:29 elliott: iirc openal is great for 3D sound, with positioning and such 01:19:43 elliott: but make it rather complicated to play, say, a stereo sound track 01:19:55 * elliott is planning to use OpenAL for AII, and that's 2D. 01:20:01 mhm 01:20:12 Vorpal: And of course in-memory it may easily end up being ABGR or BGRA if you read it byte-orientedly. 01:20:13 Mostly because some of that positioning stuff is relevant, if only to make further away sounds quieter. 01:20:25 fizzie: heh 01:20:46 fizzie: is that for little or big endian? 01:21:11 fizzie: but stuff like opengl does it as GLfloat[4] basically 01:22:10 The pixel buffers still have a format. But I suppose you normally aren't supposed to actually play with those bytes. 01:22:46 fizzie: you generally just send them along in buffer objects and such 01:23:06 Honestly, all I want to do is animate some circles going around each other. 01:23:10 Maybe I can use that gloss thing. 01:23:21 elliott: putpixel :P 01:23:27 Vorpal: From Haskell? 01:23:30 Rather slow. 01:23:31 elliott: ouch 01:23:44 Haskell's FFI is low-overhead, but not /that/ low-overhead. 01:23:51 elliott: could you do a real time software ray tracer in haskell? 01:24:03 You can't do that with C. 01:24:09 At least if realtime involves >10fps. 01:24:12 elliott: you can for some simple scenes 01:24:24 I have one that runs in 50 FPS for a plane, two balls and a cone here 01:24:29 I'm sure you could do it. Probably not on Unix. 01:24:29 on my core i8 01:24:30 err 01:24:31 i7* 01:24:36 it is using openmp 01:24:38 @ should be able to do ray-tracing just fine. 01:24:41 elliott: yes on unix 01:24:55 Vorpal: "Can Haskell do X in an environment practically designed to work against Haskell in areas such as X?" 01:24:56 elliott: it is part of a lab at university. We are running it on core i7s there 01:25:09 elliott: hm? 01:25:19 "Hm?"? 01:25:20 elliott: I'm just saying you can do it in C (actually C++ here...) 01:25:28 Sure, so? 01:25:29 elliott: you said you couldn't do it with C 01:25:57 Well, I thought you meant more complex scenes than that. 01:26:01 ah 01:26:34 Congrats, you named one of the few areas where the performance of tight, math-heavy loops that fit in cache is still relevant! 01:26:43 pikhq_: quite :P 01:26:50 * elliott thinks @ will raytrace just fine. 01:26:54 elliott: but you can to some degree do it on more complex scenes, you just need like way more CPUs :P 01:26:55 I've again forgotten what "Ncon" meant in the "caveats" field of glxinfo. I guess non-conformant, but that's not saying much either. 01:27:02 Pure mathematical code is pretty easy to eliminate all the overhead from. 01:27:06 Which, for perverse reasons, is what most people think of as more general "performance". 01:27:17 pikhq_: indeed not the case. 01:27:18 Just get things unboxed and the loop into an iteration and you're done. 01:27:32 pikhq_: it is however an area I'm greatly interested in. 01:28:22 elliott: I'd imagine worst-case scenario you'd have a @lang-subset->verified-safe-machine-code compiler and a way to execute verified-safe machine code. 01:28:29 @ might lose where you have a tight loop that involves a lot of operations on things larger than machine words and no allocation. 01:28:39 pikhq_: ray tracing is interesting. Especially real time ray tracing. Since there is no way we are going to get real time photon mapping (or even further away I believe: real time MLT) 01:28:39 There might be some overhead imposed there. 01:28:44 Or even make that assembly instead of @ lang. 01:28:58 pikhq_: Weelll, there's @ll. 01:29:03 But that's not really for human consumption. 01:29:13 Nor is assembly. :) 01:29:25 (@ll being an imperative, safe-by-construction language that shares @lang's type system.) 01:29:29 It's only human-used for perverse edge cases, or for perverse people. 01:29:35 (Kind of like LLVM IR, but with things like allocation built in to the language.) 01:29:41 pikhq_: boot loaders 01:29:46 pikhq_: demo scene 01:29:49 (@lang of course compiles down to @ll.) 01:29:52 Vorpal: Perverse edge case, perverse people. 01:29:53 pikhq_: I guess those count as perverse? 01:29:53 Vorpal: "perverse edge cases", "perverse people" 01:29:56 right 01:30:05 pikhq_: compiler writers? 01:30:11 for the generating bit 01:30:20 They're not actually human-writing assembly. 01:30:25 hm true 01:30:26 They're human-writing assembly generation. 01:30:31 Oh, @ will also lose where you have a tight loop that does allocation, and can deal with a slow allocation, but /cannot/ deal with a GC pause. 01:30:32 yeah 01:30:57 More commonly: @ will lose if you need a loop to not allocate but you can't get the @lang compiler to not allocate there. 01:31:16 Although since I can have pluggable GCs, you could run a low-throughput concurrent collector in those situations for that pool. 01:31:19 Dunno. 01:31:22 elliott: how well will @ keep up with hard realtime requirements? I know there aren't a lot of them on PCs. But one case comes to mind if you are interested. 01:31:29 Vorpal: Go on,. 01:31:33 s/,// 01:32:07 elliott: accelerometer in laptop. You want to send the "get the fucking head off the disk RIGHT NOW" command with hard realtime constraints when it happens. 01:32:17 Er, I think that's done in hardware. 01:32:23 elliott: not on thinkpads at least 01:32:30 You should get a refund. 01:32:33 elliott: you need a polling daemon running on it 01:32:35 But anyway, does that correspond to an interrupt on the host computer? 01:32:36 which sucks yes 01:32:39 What, polling? 01:32:42 elliott: yes 01:32:51 elliott: it is terrible 01:32:55 I don't *want* @ to be good at this. Your HD deserves to die if it's protected by such an infernal contraption. 01:33:11 If it caused a host interrupt instead, then I think @ would be able to handle it. 01:33:22 I mean, if you're under heavy load it might not work out. 01:33:24 Vorpal: Um, that's not going to be any worse on @ than on any other OS. 01:33:33 pikhq_: vxworks :P 01:33:34 But yeah, if you have a userspace polling daemon and that works, then @ will handle it. 01:33:38 But I'm shocked that it works. 01:33:49 If it needs to poll, pretty much any kernel is only going to poll when you jump back into kernel space. 01:33:51 elliott: I can't say I have tested it 01:34:03 Vorpal: Lend Sgeo your laptop and you'll find out. 01:34:08 elliott: aiee! 01:34:16 And probably not even that often; I'd be willing to bet it simply sets up a timer for the checking. 01:34:32 Which shouldn't be anything impossible for @. 01:34:35 Vorpal: Anyway, @ is designed for SSDs :) 01:34:37 elliott: anyway yes it seems like a terrible design due to not offering any protection during booting 01:34:40 and so on 01:34:49 Specifically, 1-2 Tio+ SSDs. 01:35:04 elliott: those are fucking expensive 01:35:11 Pretty much all you need is for @ to make reasonable guarantees on interrupts being handled (including timer interrupts) 01:35:12 Vorpal: They are now. 01:35:14 Vorpal: Presently. 01:35:18 good point 01:35:26 Vorpal: @ is designed for where computers will be, not where computers are and have been. 01:35:26 They probably won't be when I'm in my 20s. 01:35:40 by the time @ is done SSDs will be a thing of the past :P 01:35:47 pikhq_: Can I hire you to write my marketing copy? 01:35:54 elliott: Plausibly. :) 01:36:09 It'll be like those computer ads from the 60s. 01:36:19 By the time @ is done we've all been fused into the Core Mind, I'd say. 01:36:23 @. The revolutionary new system from @ Systems, Incorporated. 01:36:24 Plugin `compose' failed with: Unknown command: "The" 01:36:27 fizzie: At which point, no worries. 01:36:33 Vorpal: @ is designed for where computers will be, not where computers are and have been. <-- you mean DRM-filled pieces of crap designed to run C and .NET code? 01:36:44 Vorpal: That's where computers are, yes. 01:36:48 The *only* computer operations system powering the new Microsoft Singularity(tm) software. 01:36:53 pikhq_: and where they are going. 01:36:59 Vorpal: Not really. 01:37:07 Get it now before Omega gets it for you.(tm) 01:37:07 pikhq_: oh? I'm not sure we will get less DRM 01:37:10 Trusted @-puting Initiative. 01:37:24 Vorpal: I give it 10 years tops for the media companies to collapse entirely. 01:37:30 pikhq_: heh 01:37:32 Making DRM pointless. 01:37:35 Vorpal: I don't think mandatory hardware DRM will catch on 01:37:35 (well, more so) 01:37:39 pikhq_: what about DRM for games? 01:37:47 "media companies" 01:37:51 elliott: I *hope* it won't 01:37:54 Vorpal: So it's not something "computers" will suffer by the @-relevant definition 01:38:04 Though the game industry is probably *less* doomed than others. 01:38:13 pikhq_: but where will we be then? I don't think there is enough people to support open source for niche applications 01:38:31 pikhq_: DRM for autodesk? 01:38:33 stuff like that 01:38:33 Media =/= programming. 01:38:43 indeed 01:38:44 Although I don't know what pikhq_ intended by "media" exactly. 01:38:52 but those companies want DRM too 01:38:59 elliott: Mostly TV, music, movies. 01:39:19 * elliott thinks if Netflix's boost for original content gets off the ground, then it'll surviev. 01:39:20 *survive. 01:39:28 pikhq_: I can see more than just media wanting DRM: games, specialised applications 01:39:28 And I would consider Netflix a TV company. 01:39:47 Vorpal: I think specialised applications need DRM less than mass-market stuff. 01:39:52 elliott: hm 01:39:55 Because the people who want it can afford it, and nobody else wants it. 01:40:01 hah 01:40:04 And ofc the people who want it need support. 01:40:06 Because it's specialised. 01:40:15 And so the internet won't help for support. 01:40:28 elliott: mathematica then? It isn't exactly mass-market. But it is popular enough to find well seeded over torrents 01:40:53 maybe not the linux version, but certainly the windows version 01:41:06 What Wolfram wants has very little connection to what is reasonable or what anyone else wants 01:41:27 elliott: true. But other applications in the same general category. Mathlab perhaps. 01:41:44 Also, DRM is a quixotic effort anyways. 01:41:47 Vorpal: *Matlab 01:41:51 right 01:41:51 http://en.wikipedia.org/wiki/MATHLAB 01:41:52 Why even consider it? 01:41:53 I believe I can get AutoCAD from university btw 01:41:56 ok you guys. 01:41:57 https://docs.google.com/a/searchfanatics.com/spreadsheet/ccc?key=0Aqlaw_Uc29ZrdGRuMDVoQzcwR1VHQm1VV3AxZXZRX2c&hl=en_US#gid=0 01:41:59 MATHLAB is an on-line system providing machine aid for the mechanical symbolic processes encountered in analysis. It is capable of performing, automatically and symbolically, such common procedures as simplification, substitution, differentiation, polynomial factorization, indefinite integration, direct and inverse Laplace transforms, the solution of linear differential equations with constant coefficients, the solution of simultaneous linear equa 01:41:59 tions, and the inversion of matrices. It also supplies fairly elaborate bookkeeping facilities appropriate to its on-line operation. 01:42:04 have at it 01:42:13 myndzi: Did you read fizzie's last words? 01:42:22 nope, i've been writing all this time 01:42:27 which last words where 01:42:44 00:16:52: (It is 02:15AM here in UTC+2. Currently it's 00:15AM in UTC. If you do a "clamp to UTC midnight" operation, you will subtract 15 minutes, so that time in my timezone will be 02:00AM. You'll need to subtract 2 more hours to get a local midnight. Substitute 8 for 2 for Manila. Sorry, couldn't resist.) 01:42:44 00:18:11: :D 01:42:44 00:19:02: (Current Unix timestamp is about 1322871375. 1322871375%86400 = 975, about 16 minutes. If you subtract that from current time, it's about 02am here. You will need to subtract further two hours from the Unix timestamp to get a Unix timestamp value that corresponds to our midnight. Sorry, couldn't resist that either.) 01:42:47 00:19:06: Okay, seriously. -> 01:42:49 00:22:32: (When the time was "today, 01:00am" here in Finland, it was 23:00 in UTC. If you clamped that timestamp to previous UTC midnight, you'd end up subtracting 23 hours, leading to "yesterday, 02:00am". Then you could subtract two more hours to get a local midnight, but it would be "yesterday, 00:00", a day earlier than you wanted. This might explain the issues you mentioned.) 01:42:54 00:22:38: Seriously for reals now. -> 01:42:56 00:22:39: -!- derdon has quit (Remote host closed the connection). 01:42:58 00:26:27: myndzi: I think fizzie is trolling you. 01:43:00 00:28:55: (If it was "today, 01:00am" here, and you wanted to round to local midnight, you could (I'm not sure I would): add two hours to the timestamp, so you'd have a Unix timestamp that'd translate to UTC 01:00am; a different instant in time, yet same in local time. Then clamp to UTC midnight, which would end up subtracting the "proper" one hour. Then you would reverse the initial "time zone conversion" by subtracting two hours, and en 01:43:05 d up with local "today, 00:00", U 01:43:06 elliott: "AutoCAD 2012 was released on 2011, March 22" <-- wut. 01:43:07 00:28:55: TC. That sort of thing would work, though the idea of having Unix timestamps that represent time instants that have the "local time" value when converted-to-display-as-UTC is a bit iffy. But if you're doing something like that, it does work.) 01:43:11 00:29:06: No, maybe some of that stuff might actually help. 01:43:13 00:29:27: I mean, after talk of "timestamps in local time", it's not inconcievable it could be something like that. 01:43:16 00:30:28: fizzie: Hi. 01:43:18 00:32:21: (But I'm still pretty sure if you just get current time() value, round to previous multiple of 86400, then; (a) subtracting K hours will give a local midnight in the UTC+K timezone, but it could be the "wrong" midnight; and (b) adding K hours will not give a local midnight, assuming K is not 12; at least as long as the resulting value is treated as a real Unix timestamp and converted to local time properly.) 01:43:23 00:32:28: Okay, maybe I really should go. 01:43:25 [...] 01:43:26 a search term would have sufficed 01:43:27 :) 01:43:27 00:37:40: (Also even after all this thinking, if I were making a "production" system, I'd seriously consider testing my thing at Manila local times of 04:00, 12:00 and 20:00, and checking that mycode(now()) approximately equals now()-4*3600, now()-12*3600 and now()-20*3600, respectively. Assuming now() returns current Unix timestamp, and mycode() is supposed to return a Unix timestamp corresponding to local midnight.) 01:43:55 @tell fizzie myndzi's reply: https://docs.google.com/spreadsheet/ccc?key=0Aqlaw_Uc29ZrdGRuMDVoQzcwR1VHQm1VV3AxZXZRX2c&hl=en_US#gid=0 01:43:55 Consider it noted. 01:43:57 Why would such a thing require the co-operation of the OS at all? 01:43:59 it doesn't look like he got it anyway 01:44:00 That sounds stupid to me 01:44:16 and i don't think he was trolling me because everyone here thought i was crazy ;) 01:44:25 i thought i was crazy too until i sat down and thought about it 01:44:35 Sgeo: Such a what? 01:44:46 please do tell me if the spreadsheet makes it clear for you...? 01:45:04 myndzi: I only glanced at it. I'd rather leave it up to fizzie, so I guess we'll see tomorrow. 01:45:04 myndzi: no: "Firefox has detected that the server is redirecting the request for this address in a way that will never complete." 01:45:09 elliott, telling the HD head to get off of the disk in the event of significant motion 01:45:10 myndzi: broken for me 01:45:15 wtf 01:45:18 it's just a google docs link 01:45:19 Sgeo: Bitter, are we? 01:45:27 myndzi: *shrug* 01:45:29 myndzi: So, basically, you were discussing a *completely different thing* than we thought you were. 01:45:32 not going to spend time debugging 01:45:54 so, basically, you have no reading comprehension at all, as it was stated multiple times and clearly 01:45:56 -!- TeruFSX_ has quit (Read error: Connection reset by peer). 01:45:56 :P 01:45:57 elliott, I'm responding to something Vorpal said I thin 01:45:58 thinkl 01:46:04 Sgeo: what? 01:46:05 Sgeo: It was a joke. 01:46:15 Of course to go from 00:00:00 UTC+8 -> x UTC+0, you add 8 hours, thus getting 08:00:00 UTC+0. 01:46:18 Er, I think that's done in hardware. 01:46:18 elliott: not on thinkpads at least 01:46:20 Sgeo: because bad architecture 01:46:23 Oh, didn't see that 01:46:34 Sgeo: polling even 01:46:42 Erm, wait. Bleh. 01:46:44 No. 01:46:47 No you don't. 01:47:05 To go from x UTC+0 -> UTC+8 you add 8. To do the inverse you subtract. 01:47:12 so, basically, you have no reading comprehension at all, as it was stated multiple times and clearly <-- you just failed horribly at expressing yourself then 01:47:31 -!- TeruFSX has joined. 01:47:48 * elliott still thinks myndzi is wrong, but also thinks that multiple people arguing with myndzi is much less productive than the best person here arguing with myndzi alone. 01:47:49 * myndzi still thinks elliott is wrong, but also thinks that multiple people arguing with elliott is much less productive than the best person here arguing with elliott alone. 01:47:54 Rude. 01:48:20 I'm not sure about that for either of you. 01:48:25 Still talking about Unix timestamps and UTC? 01:48:36 PiRSquared17: not still. again. 01:48:42 Vorpal: ? 01:48:44 because myndzi bought it up 01:48:54 I'm not sure about that for either of you. 01:48:55 ? 01:49:01 elliott: indeed. 01:49:07 ? 01:49:12 I'm not going to specify further to avoid offending you both 01:50:13 Vorpal: (The best person is meant to be fizzie, and myndzi's response was scripted, if that's what you mean.) 01:50:38 not at all what I meant 01:50:39 but whatever 01:51:08 elliott: speaking of rendering, this is cool: https://en.wikipedia.org/wiki/Metropolis_light_transport 01:51:23 Vorpal: I know what you think you were getting at, but it doesn't really work as an insult at all. 01:51:38 elliott: who said insult? 01:51:41 Is there a name for the class of functions that can be expressed as an infinite term polynomial? 01:51:46 elliott: just forget it! 01:52:03 Sgeo: sure one such name is "functions that can be expressed as an infinite term polynomial" 01:52:47 i can't even find in the history the last time it was summed up, but somebody else restated it and i agreed 01:52:58 anyway. 01:53:14 hopefully the document makes both the question and the answer exceedingly clear 01:53:19 and everybody can agree and be happy :) 01:53:26 I do not care about the time problem any more. 01:53:27 good thing i did the chart too 01:53:28 whatever 01:53:36 * elliott expects it'll go another way entirely. 01:53:51 elliott: what will go another way? 01:53:58 The thing you don't care about. 01:54:20 tis all i have to say on the matter, go back to ... whatever it is you guys do in here :P 01:55:17 myndzi: But what if fizzie proves you wrong. It's no fun without bloodshed :( 01:55:49 -!- GreaseMonkey has joined. 01:56:03 i'll happily be proven wrong 01:56:12 The thing you don't care about. <-- ? 01:56:19 all i wanted to do was grok it in the first place 01:56:24 Vorpal: You're being pretty thick. 01:56:38 elliott: I don't care about what way it is going any more! 01:57:07 I do not care about the time problem any more. 01:57:09 * elliott expects it'll go another way entirely. 01:57:10 elliott: what will go another way? 01:57:11 The thing you don't care about. 01:57:25 elliott: go another way than WHAT? 01:57:27 i care what about thing going that where more have it done 01:57:33 i can't even find in the history the last time it was summed up, but somebody else restated it and i agreed 01:57:33 anyway. 01:57:33 hopefully the document makes both the question and the answer exceedingly clear 01:57:33 and everybody can agree and be happy :) 01:57:41 Vorpal: For something you don't care about you are asking lost of questions about it. 01:57:55 elliott: oh I see. A trick. 01:57:58 good job 01:58:05 What? 01:58:18 elliott: I'm not even meta-discussing it further. 01:58:24 You're being a fucking moron, I said something to someone other than you and then you proceeded to act dense about what I was talking about for like five minutes. 01:58:42 hey guys? i heard that .999 repeating = 1 01:58:46 * myndzi ducks and hides 01:58:51 elliott: you mean * elliott expects it'll go another way entirely wasn't aimed at me? 01:58:57 Of course it fucking wasn't. 01:59:00 he was responding to me 01:59:00 oh okay 01:59:05 whatever 01:59:05 * elliott expects it'll go another way entirely. 01:59:05 myndzi: .999 repeating does indeed = 1. 01:59:13 .999.999.999.999.999... = 1. 01:59:13 thing is, it didn't look like that here 01:59:19 elliott: i know, but it is a nefarious and easy flamewar starter 01:59:23 which was the joke :) 01:59:35 myndzi: You missed my joke. :'( 01:59:42 I don't think anyone in here is stupid enough to deny that .9r = 1. 01:59:43 i was typing at the time 01:59:46 i lol'd a little 02:00:22 Is there an easy way to determine whether a given number has more than one representation in decimal? 02:00:26 myndzi: that is only true in base 10 surely? 02:00:38 in base 16 I assume .ffff = 1 02:00:39 well, yes 02:00:42 well .fff... 02:00:46 Sgeo: const True 02:00:47 what about .fffffuuuuuuuu 02:01:00 myndzi: which base is that? 02:01:01 i actually managed to explain to my mom why the adding digits trick works in any base 02:01:07 30-something? 02:01:22 Vorpal: well it has to be at least 31 02:01:23 > 0.99999999999999999999 02:01:24 1.0 02:01:26 something like that anyway 02:01:28 myndzi: ah 02:01:32 I love how http://en.wikipedia.org/wiki/0.999... has like a thousand proofs. 02:01:38 elliott, What about 0? Or .333repeating 02:01:56 @type (0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0) 02:01:57 Sgeo: 0 = 0.00000000000000000000000000000 :-) 02:01:57 A 103-tuple is too large for GHC 02:01:57 (max size is 62) 02:01:57 Workaround: use nested tuples or define a data type 02:01:59 elliott: I love how this section exists: https://en.wikipedia.org/wiki/0.999..#In_popular_culture 02:02:14 (max size is 62) what? 02:02:16 Sgeo: .3r is a fair point. 02:02:28 interestingly i actually have a script that detects likely encoded text in base 2 through 36 and makes a guess at the correct base, then decodes it 02:02:35 it was interesting to write 02:02:51 Sgeo: Anything with a finite decimal representation has multiple representations. 02:03:10 Sgeo: I'm sure you can find for yourself how to determine whether a number has one of those. 02:03:13 3C11343F3M3I113B343P38113I3H38113N3I113M343S113N3B3C3H3A3M113C3H11343L353C3N3L343L3S1135343M383M 02:03:18 elliott: hm what about 0+ 02:03:19 err 02:03:20 0? 02:03:36 I can't think of another for 0 02:03:39 0 is just, like, -0.9999999999999999999999999999999999999999. 02:03:48 (-0).99999999999 02:03:50 = 1 02:03:50 elliott: no that is -1? 02:03:51 Q.E.D. 02:03:57 Vorpal: No, that's -(0.999999999). 02:04:12 what do you mean by (-0).99999999999 exactly 02:04:19 (-0).9999999... = -0 + 9/9 = -0 + 1 = +0. 02:04:24 obviously he means negative zero times point nine repeating to infinity 02:04:30 hm 02:04:31 the answer is obviously q 02:04:43 ah 02:04:53 elliott, are there numbers with more than two decimal representations? 02:05:18 Sgeo: Yes, for instance 0 is 0, 0.00000..., and (-0).999... 02:05:23 guess that depends on how you represent numbers 02:05:27 Which would also imply that a number without a finite decimal representation could have multiple decimal representations 02:05:30 also how does "-0 + 1 = +0" 02:05:51 myndzi: magic 02:06:03 I'm not counting extra 0s at the end to be a separate representation 02:06:08 so... magnets? 02:06:19 > -0 + 1 02:06:20 1 02:06:22 Sgeo: the interesting thing about .99999... etc 02:06:24 > (-0) + 1 02:06:25 1 02:06:33 is that you can actually produce it by long division with 9 into 9 02:06:40 if you break a little rule and follow the process 02:07:08 (9 goes into 9 0 times) 02:07:24 it'd be interesting if you could do the same thing with other values, but i expect it to be unlikely 02:08:20 (actually, i'm pretty sure you can produce .9999 by dividing any number by itself with long division, if you don't count it as going into itself exactly) 02:09:04 elliott: yeah I can't get -0 + 1 = +0 02:09:20 you're educated stupid 02:09:22 elliott: what sort of weird system is that 02:09:43 > (-0)::CReal + 1::CReal 02:09:43 : parse error on input `::' 02:09:48 blergh 02:09:50 whatever 02:09:52 sour creal 02:09:56 Decimals suck, Dedekindcuts4life 02:09:58 > (-0::CReal)+(1::CReal) 02:09:59 1.0 02:10:04 elliott: NOT 0.0 02:10:05 see 02:10:06 CReal has an off-by-one. 02:10:09 > (-0::CReal) 02:10:10 0.0 02:10:13 Vorpal: CReal just doesn't support negative 0. 02:10:15 It's limited. 02:10:21 interesting: if you do the same long division shenanigans with less than one, you wind up with carries that make it .999999 anyway ;) 02:10:22 elliott: lets do it in float then 02:10:29 > (-0) == 0 02:10:30 True 02:10:30 Floats are inaccurate! 02:11:29 elliott: I call your -0 + 1 = +0 bullshit unless you can back it up by a reliable source /such as/ oerjan (when he gets back) or a wikipedia articles with proper references. 02:11:48 Vorpal: oerjan is educated evil. 02:11:57 so it /is/ bullshit then 02:12:13 so give me an actual different representation of 0 02:12:56 Counterpoint: You smell funny. 02:13:10 go to sleep already 02:13:17 It's 2 am. 02:13:20 you only do this when you need to sleep 02:13:29 No, I only do it when I want to irritate you. 02:13:33 It's really easy. 02:13:42 which mostly happens when you are sleepy 02:13:56 Whatever your excuse! 02:14:27 -!- kallisti has quit (Ping timeout: 252 seconds). 02:14:49 !bf >,[.>,]+[<.]!testing 02:25:01 -!- kallisti has joined. 02:30:55 -!- pikhq has joined. 02:31:07 -!- pikhq_ has quit (Ping timeout: 244 seconds). 02:47:52 -!- calamari has joined. 02:54:15 i have a girl here now 02:54:29 8/ 02:54:56 i have a box 02:55:02 i wish i had a box 02:59:35 !bf >,[.>,]+[<.]!testing 02:59:43 ^bf >,[.>,]+[<.]!testing 02:59:44 testinggnitset 03:07:09 oklopol: do you want a box, i can give you a box 03:09:18 ^bf >,[.>,]+[<.]!po 03:09:18 poop 03:13:10 ^bf >,[.>,]+[<.]!a 03:13:10 aa 03:13:13 ^bf >,[.>,]+[<.]! 03:13:36 oklopol: btw i'm working on the thing that ph proved you wrong with 03:13:38 it's working super great. 03:13:53 just flinging particles around in 2d 03:13:56 watching them form stable orbits 03:14:39 anyone happen to know how I can figure out what is causing a kernel module to be in use? 03:14:48 um... it being loaded 03:14:57 kernel modules are only "used" because they're explicitly loaded 03:15:20 sorry I guess I didn't ask the question right 03:15:24 ^bf >,[.>,]+<[<.]!race 03:15:25 racecar 03:15:29 I'm trying to remove a module 03:15:44 modprobe -r foo 03:15:48 exactly 03:15:48 assuming by remove you mean unload 03:15:56 FATAL: Module snd_hda_intel is in use. 03:15:59 ah. 03:16:07 you'll have to disable ALSA somehow i think 03:16:11 why are you trying to do that 03:16:21 because I'm trying to avoid rebooting 03:16:37 I need to change the options for the module 03:29:31 -!- calamari has quit (Remote host closed the connection). 03:32:14 ^bf >,[.>,]+<[<.]!10 03:32:14 101 03:34:44 -!- calamari has joined. 03:36:16 -!- hagb4rd has joined. 03:36:57 ^bf >,[.>,]+<[<.]!m a d a m i 03:36:58 m a d a m i m a d a m 03:41:00 ^bf >,[.>,]+<[<.]!amanaplanac 03:41:01 amanaplanacanalpanama 03:41:23 Check the phase of the moon on the calendar and then guess what you think is the tropical Moon sign at this time. (Use numbers if you prefer; I prefer to use numbers myself but it doesn't matter) Try to guess also the sign for Mercury and for Venus? 03:42:23 O, you are making palindrome. It is palindrome using letters (only letters) as units, so you need to put spaces afterward by yourself. Once I found the very long palindrome text!! 03:45:25 -!- DCliche has changed nick to Klisz. 03:55:07 ^bf >,[.>,]+<[<.]!lololololol 03:55:07 lolololololololololol 04:02:08 -!- Sgeo has quit (Read error: Connection reset by peer). 04:02:53 -!- Sgeo has joined. 04:08:58 -!- MDude has changed nick to MSleep. 04:13:40 ^bf >,[.>,]+<[<.]!madam president, commissioner, in this case, i would like this document to ban the advertising of tobacco products, regardless of all our people. 04:13:40 madam president, commissioner, in this case, i would like this document to ban the advertising of tobacco products, regardless of all our people.elpoep ruo lla fo sseldrager ,stcudorp occabot fo gnisitrevda ... 04:17:32 fungot: hi 04:17:33 PiRSquared17: mr president, mr president, that the special relationship between france and germany at the brussels summit achieved was clarification as regards financing. in other words the extension of the schengen acquis in the applicant countries as well. i am still looking for. 04:18:45 How long does it take for ARM processor program to fill an amount of RAM with null bytes? 04:20:21 @faq How long does it take for ARM processor program to fill an amount of RAM with null bytes? 04:20:21 The answer is: Yes! Haskell can do that. 04:21:02 I mean in a program written in assembly language (or machine code); not Haskell. 04:21:12 I know 04:31:15 "He who lives by the sword...should probably bring something better to a gun fight." 04:32:02 ^style ct 04:32:02 Selected style: ct (Chrono Trigger game script) 04:32:07 fungot: 04:32:07 PiRSquared17: the masamune!! grribit... in that energy field, our molecular structure to the north. it's a great place for a picnic! heard that magus's place... 04:32:28 I'm so glad this channel is #bots. 04:34:09 At least ^bf >,[.>,]+<[<.]!... was related to esoteric programming languages 04:35:45 O, whatever............................ 04:39:16 "O, whatever............................" --zzo38 04:42:16 Can you make 1962 points in one turn of Scrabble game? How many points can you score in total in a Scrabble game? 04:42:32 3 04:44:17 http://www.ocf.berkeley.edu/~wwu/cgi-bin/yabb/YaBB.cgi?board=riddles_general;action=display;num=1071784078 04:59:28 -!- Sgeo has quit (Ping timeout: 248 seconds). 04:59:38 Sure, if QWUZTJA is a word 05:02:54 It so is 05:03:34 -!- Sgeo has joined. 05:07:33 I, for one, welcome our new esolang overlords 05:09:05 --Ken Calamari, winner of 10 cents on the game show "The Simpsons" against a computer 05:10:15 is that another way of saying I put my 2 cents in? 05:13:18 bye 05:13:20 -!- calamari has quit (Quit: Leaving). 05:30:56 -!- Sgeo has quit (Ping timeout: 248 seconds). 05:32:57 -!- Sgeo has joined. 05:59:38 -!- pikhq_ has joined. 05:59:56 -!- pikhq has quit (Ping timeout: 252 seconds). 06:06:15 pikhq_: the majority of your messages are bot commands. 06:06:17 erm 06:06:33 PiRSquared17: the majority of your messages are bot commands. 06:06:52 seriously. stop that. 06:10:09 And my last message was an hour ago... I stopped 06:14:57 -!- PiRSquared17 has left ("."). 06:18:22 . 06:19:10 -!- copumpkin has quit (Quit: Computer has gone to sleep.). 06:19:51 -!- copumpkin has joined. 06:20:06 elliott: you can now bye snoop dogg velvet house shoes 06:20:44 bye, snoop dogg velvet house shoes 06:20:45 we will miss you 06:21:06 also 06:21:07 the word 06:21:09 is slipper 06:22:33 that is not what they're being advertised as 06:23:12 where the fuck is oerjan he's had like 6 hours of sleep come on dude i need to bug you about quadtree zippers 06:23:38 wtf is a quadtree 06:23:49 are you fucking serious 06:23:58 yes 06:24:05 do you have an internet connection 06:24:08 oh 06:24:09 4-tree 06:24:20 wow yeah it's that data structure that not a single person on the planet calls a 4-tree 06:25:18 um yeah in general people say n-tree 06:25:23 and a quadtree is a 4-tree 06:25:25 so... :) 06:25:33 no everybody calls quadtrees quadtrees 06:25:45 http://en.wikipedia.org/wiki/Quadtree wikipedia doesn't even list 4-tree as an alternate name 06:25:59 "4-tree" on wikipedia returns 2-3-4-tree as first result, nothing relevant on first page 06:26:01 erm 06:26:02 *on google 06:30:48 fine. 06:39:44 -!- hagb4rd has quit (Ping timeout: 248 seconds). 06:58:47 -!- hagb4rd has joined. 07:00:05 -!- Klisz has quit (Quit: You are now graced with my absence.). 07:05:27 -!- itidus21 has joined. 07:05:58 note to self: http://sprunge.us/KjUW 07:29:54 What is this program for? 07:30:29 it was the start of a quadtree-with-zippers library, but then I threw it away to abstract it out better to reduce code duplication, and used sprunge + this channel as a backup in case it went horribly wrong :P 07:30:34 it's coming along very nicely now 07:34:23 http://sprunge.us/LCNO deriving zippers by differentiation is one of the most beautiful things 07:35:28 kallisti: look at that. tell me that's not amazing. 07:36:10 :> is good 07:37:04 kallisti: btw homestuck book is out. 07:39:02 ....okay? 07:39:46 focus _ (Branch _ _ _ _) = error "focus: path too short" 07:39:49 when does this happen? 07:39:52 oh 07:39:53 nevermind 07:40:06 I didn't notice the Dir argument is _ too 07:40:41 you could put [] there instead of _ I think... but then it won't be all vertically symmetrical with the _ 07:40:46 *the other _'s 07:40:50 * kallisti cares about things like that. 07:41:15 also I have no fucking clue what's going on in this code. 07:45:43 I'm focus moves the zipper around? 07:45:45 or something 07:45:54 that's what it looks like it does. 07:47:39 elliott: would it be possible to make a typeclass for both STRef and IORef 07:47:45 so you can write code generally for either of them? 07:47:51 I think it should be 07:47:53 trivially. shut up, I'm trying to be as mindlessly consumerist as possible. 07:48:14 elliott: why isn't this standard then, aside from needing a multi-param typeclass 07:48:24 because nobody needs it, SHUT UP TRYING TO SPEND SO MUCH MONEY 07:48:38 on homestuck booko? 07:48:52 *bkooo 07:48:55 *boook 07:48:57 yes. also the newest problem sleuth book which also just came out. 07:48:59 and uh 07:49:00 other shit because 07:49:03 shipping is over \$30 07:49:07 heh 07:49:08 yeah 07:49:09 I love that. 07:49:19 I actually get free shipping for most things on Amazon 07:49:25 for a year, anyway. because I have a student account. 07:49:29 UM WAIT there's t-rex plushes let me examine the prices 07:49:33 I didn't know you could use differential calculus to figure out types but now I can see how it works. 07:49:37 kallisti: topatoco ain't amazon 07:49:44 no shit. 07:49:55 * kallisti bought a Problem Sleuth fractal shirt from that site. 07:50:03 it's awesome. 07:50:25 I think I'm going to go for one of the sbahj shirts 07:50:28 because 07:50:30 they glow in the fucking dark 07:50:57 ok YES a small t-rex plush is exactly what my life needs right now. as well as a hole in my pocket. TWO BIRDS, ONE STONE MADE OUT OF MONEY!! 07:52:01 elliott: how are you affording this. 07:52:11 THAT'S THE PROBLEM YOU SOLVE AFTER BUYING SO MANY THINGS!!! NOT BEFORE!!! 07:52:17 IF I SPEND TIME TO THINK ABOUT THAT THIS SHIT WILL SELL OUT 07:52:19 I remember when I was 16 I had an average of 0.1 dollars 07:52:21 WHICH IT WILL BE DOING RAPIDLY AS I SPEAK 07:52:29 http://www.topatoco.com/merchant.mvc?Screen=PROD&Store_Code=TO&Product_Code=QW-EXTREME&Category_Code=QW 07:52:38 this.... wow. 07:52:50 lol 07:52:54 so extreme 07:53:02 * kallisti also has a Dave record t-shirt 07:53:17 and that yellow shirt with the bandit riding a velociraptor. 07:53:23 because. IF YOU BUY 3 SHIRTS THERE'S A DISCOUNT OMG 07:54:27 also it wasn't a hole in my pocket because at the time I had like \$2000 07:54:54 you can see where that logic has gotten me though: I now have like \$200 07:55:06 (in my defense I had to buy A WHOLE CAR. ALL OF IT) 07:55:58 Do you have something to cut a hole in your pocket? Does it need to be large enough for a t-rex plush to fit through? 07:58:23 probably, though the T-rex plush will fit snuggly in his new pocket hole. it's a well known law of fixed that burning a hole in your pocket so that money can escape will immediately fill the resultant gap with T-rex plushes 07:58:38 proportional to the inverse square of the money spent. 07:58:39 hmm, the wee plush is definitely the best bet, as opposed to the big one 07:58:42 wee is 19, big is 39 07:58:54 big t-rex is adorable but not 20 dollars adorable 07:59:22 * kallisti snuggles a 20 dollar bill. so cute. 07:59:50 * elliott wonders what the chances of the stairs shirt being interpreted sincerely are. 08:00:05 kind of want to go for the slam-dunk one instead, it's so artsy 08:00:51 I think all of the SBaHJ shirts can be taken seriously. 08:01:11 well yes. the stairs one is definitely the loudest of 'em though 08:01:18 http://www.topatoco.com/graphics/mspa-sbahj-black-pic.jpg 08:01:19 http://www.topatoco.com/graphics/00000001/mspa-bigman.jpg 08:01:20 decide for me, kallisti 08:02:01 !perl print (qw(blackpic bigman))[int(rant(2))] 08:02:04 syntax error at /tmp/input.16316 line 1, near ")[" 08:02:08 .....ASSHOLE 08:02:10 PERL HATH SPOKEN 08:02:14 !perl print (qw(blackpic bigman)[int(rant(2))]) 08:02:15 Undefined subroutine &main::rant called at /tmp/input.16387 line 1. 08:02:18 wat 08:02:18 oh 08:02:21 !perl print (qw(blackpic bigman)[int(rand(2))]) 08:02:21 blackpic 08:02:27 but dudel 08:02:29 now let me actually click on the links 08:02:31 look at that hoop 08:02:32 it's so 08:02:33 artsy 08:02:44 hmm 08:02:51 i think i'll go with stairs though 08:02:52 because 08:02:55 i don't like red shirts 08:02:59 dunno the hoop is pretty nice. 08:03:09 yeah it is but 08:03:11 i really don't like red shirts 08:03:15 i mean 08:03:19 not that shade at least 08:04:17 the stairs shirt could use more compression artifacts 08:04:50 i would omit the first two problem sleuth books because really i am only buying the third because of the doodle but 08:04:55 if i'm gonna have the books they might as well be in a readable form 08:05:19 you're practically looking for excuses to spend obscene amounts of money on overpriced merchandise 08:05:30 totally. 08:05:32 BUT THINK OF THIS WAY YOU'RE SUPPORTING YOUR FAVORITE WEBCOMIC YEAAAAH 08:05:42 it's not really overpriced though? topatoco prices are pretty reasonable 08:05:44 and also topatoco and whoever makes those shirts. 08:05:49 and they're giving me that \$5 three-pack discount!!! 08:05:55 lol 08:05:55 kallisti: topatoco is run by jeffrey rowland 08:06:01 (wigu, overcompensating) 08:06:05 (i sound like wikipedia) 08:06:11 you aRE WIKIPEDIA 08:07:29 elliott: well it's not overpriced for novelty t-shirts you can only get alone 08:07:34 but it is overpriced for clothing. 08:07:41 I guess the books are probably not overpriced. 08:07:44 kallisti: \$20 is not that bad for a t-shirt... 08:07:45 because they're probably huge. 08:08:00 8.5" x 8" 08:08:19 I mean like 08:08:20 thickness 08:08:26 or well 08:08:29 3-dimensional volume. :P 08:08:43 hs book is 162 pages 08:08:44 (act 1) 08:08:48 (there are going to be like 50 books) 08:08:49 (probably) 08:09:55 I wonder how many pages of homestuck on average are on a page. 08:10:08 also how do you put a flash movie in a book? :P 08:10:27 you don't 08:10:30 you adapt it for the medium 08:10:38 well, yes... 08:10:44 that's what I assumed. 08:11:56 homestuck popup book would be epic. 08:12:11 "Let's Do This Thimg. Let's Make It Happen." --topatoco confirmation button 08:12:32 CAPITALISM COMPLETE 08:12:34 gotta love their leet markteing skillz 08:12:45 appealing to your niche fandom. 08:12:50 with references to things. 08:13:20 does... Dinosaur Comics have a book? 08:13:23 please tell me it does. 08:15:15 kallisti: two of them 08:21:22 We need a User Friendly/MSPA crossover 08:21:29 (Note: Not a serious suggestion) 08:21:32 -!- GreaseMonkey has quit (Quit: The Other Game). 08:22:08 what we need is for user friendly to stop existing 08:22:10 retroactively 08:22:16 OH MY GOD IT FINISHED? 08:22:23 THANK THE LORD 08:22:53 It's still on repeat for now, isn't it? 08:23:15 that counts as over 08:23:43 It could come back 08:23:51 I think 08:24:09 So could Nazism. 08:24:17 I'm not saying it's comparable, but it's comparable. 08:24:53 What is the use of making differentiations on Haskell types? 08:25:32 Apparently the derivative of a Haskell type is a zipper. I do not know what that means, so don't ask me to elaborat.e 08:25:36 elabora.te 08:25:38 al 08:25:44 elaborate. 08:26:09 zzo38: http://en.wikibooks.org/wiki/Haskell/Zippers 08:26:18 Can integrations be done? 08:26:19 zzo38: that covers deriving them automatically with the differentiation rules too 08:26:33 http://www.haskell.org/haskellwiki/Zipper is also good for showing why zippers are useful (but lacks the derivation stuff) 08:26:50 also http://strictlypositive.org/calculus/ is where the whole thing originated 08:26:55 with a buncha papers 08:26:56 It seems to me that differentiation won't work with function types as far as I can tell 08:27:28 zzo38: (A -> B) = B^A 08:27:31 so sure you can do it 08:27:43 e.g. (Bool -> a) === a^2 === a*a === (a,a) 08:28:39 elliott: Yes I can see that, but what if the A is some other type you don't know? 08:28:55 How is a (Bool -> a) the same as an (a,a)? 08:29:02 zzo38: well, then it's harder :) 08:29:16 Sgeo: oneWay f = (f False, f True) 08:29:28 Sgeo: theOtherWay (a,b) x = if x then b else a 08:29:42 oh, *~(a,b) 08:29:44 needs to be lazy 08:29:59 Oh 08:30:06 For some reason I was thinking (a -> Bool) 08:31:51 The storylines page updated! http://www.userfriendly.org/archivist/gallery/storylines.html 08:32:54 I can practically quote http://www.userfriendly.org/animation/episode1.html from memory. 08:33:03 my condolences 08:33:53 wat 08:34:44 HE LIVES IN LIKE 08:34:45 Ok, so maybe I don't remember it 100% exactly 08:34:47 But I'm close 08:34:56 A CLIPART WORLD. 08:34:58 -!- monqy has quit (Quit: hello). 08:35:02 HIS ENTIRE WORLD IS CLIPART 08:35:21 also lol sailor moon. 08:35:28 so terrible 08:35:29 this is so bad 08:35:30 what is this. 08:35:32 aaaaaaah 08:36:22 It seems that if the (a) in (a -> b) is a Maybe type then it might be able to be done I suppose? 08:38:34 Sadly, episode 2 was never made. 08:38:44 Sgeo: Sadly? 08:39:12 zzo38: ah indeed. 08:39:47 Fortunately, there are other animations 08:39:55 (Maybe a -> b)' = (b^(a+1))' = (a+1)*b^a = (Fin |a+1|, a -> b) 08:40:05 what a thoroughly odd type 08:40:11 Sgeo: why do you like clipart universe. 08:40:26 http://www.userfriendly.org/animation/ 08:40:29 *|a|+1 08:40:30 no 08:40:36 What does (Fin |a+1|) means? 08:40:51 zzo38: Fin n for natural n is the type with n elements, you can define this in a dependently typed language 08:40:54 kallisti, bought a UF book when I was a kid. 08:40:55 actually wait 08:40:58 it isn't fin, I'm an idiot 08:41:00 Didn't realize what it was until I bought it 08:41:04 (Maybe a -> b)' = (b^(a+1))' = (a+1)*b^a = (Maybe a, a -> b) 08:41:09 there 08:41:12 Read it, loved it, misplaced it on a summer camp field trip 08:41:19 Remembered the URL I saw 08:41:19 elliott: Yes, that one (Maybe a, a -> b) is the answer I was thinking of. 08:41:23 that's uh, the derivative of (Maybe a -> b) with respect to a 08:41:24 Sgeo: no stop telling me this 08:41:26 you're just making it worse. 08:41:31 so there should be 08:41:42 foo :: a -> (Maybe a, a -> b) -> (Maybe a -> b) 08:41:43 and 08:41:47 I wonder if UF had a major impact on my life 08:41:51 bar :: (Maybe a -> b) -> (a, (Maybe a, a -> b)) 08:41:59 elliott: so types here represent their number of inhabitants in this system? 08:42:07 kallisti: no 08:42:19 kallisti: 1 is just the notation for the unit type 08:42:21 2 for Bool 08:42:22 etc. 08:42:24 0 for Void 08:42:27 a+b is alternation, i.e. Either a b 08:42:36 obviously the notation is picked for the effects on cardinality 08:42:43 elliott: and all of this are -- yes 08:42:44 that. 08:42:50 s/this/these/ 08:43:26 what happens with recursive types? 08:43:37 infinity right? 08:43:41 no 08:43:46 you reason about them with fixed-points 08:43:52 you can basically just use the chain rule 08:43:52 for instance 08:44:01 http://sprunge.us/LCNO 08:44:03 where i do just that. 08:44:22 And I think it is repect to b isn't it? Rather than repect to a? 08:44:49 zzo38: hmm, maybe -- but isn't that the rule you use for a^n for constant n? 08:44:56 oh, riht 08:44:59 yes, it's with respect to b :) 08:44:59 *right 08:45:03 so it's actually 08:45:09 foo :: b -> (Maybe a, a -> b) -> (Maybe a -> b) 08:45:15 bar :: (Maybe a -> b) -> (b, (Maybe a, a -> b)) 08:45:22 bar makes sense, the b is obviously (f Nothing) 08:45:29 but I'm not sure what the (Maybe a) is at all 08:45:31 hmmm is there an integer division type? 08:45:37 I can't seem to remember where the book started, but it ended at the end of a Star Wars parody. Or was it an LOTR Parody 08:45:39 kallisti: you can't divide or subtract, generally 08:46:25 * Sgeo wikipedias 08:47:41 Ah, ok, it was User Friendly, O'Reilly, 1999, ISBN 1-56592-673-0 January 25, 1998 - December 25, 1998 (misses out December 20 and probably some others) 08:49:41 kallisti, I hope you don't think good or bad graphics make a webcomic 08:50:46 hahaha 08:50:49 is Sgeo seriously offended 08:50:54 because kallisti doesn't like user friendly 08:50:58 aka one of the worst comics in ever 08:51:35 I'm just amused that "clipart" is the insult used 08:51:46 no it's so much more than that 08:51:51 clipart is like... the state of mind. 08:52:04 it's a clipart universe in a very real sense 08:52:15 not just TANGIBLE VISUAL PROJECTIONS OF ENTITIES 08:52:18 AHAHAHAHAAHAHAH 08:52:21 :) 08:52:48 Sgeo: note that 08:52:51 bad art 08:52:53 does in fact make a web comic worse 08:53:06 although i disagree that clipart=bad 08:53:22 elliott, T&R is not bad. 08:53:36 TOUCHING A LOT OF NERVES TODAY 08:53:41 also: completely misreading things I said! 08:53:44 Although "worse" doesn't imply bad I guess 08:53:48 art is one aspect of a comic 08:53:56 if triangle and robert is sufficiently funny 08:54:04 then it is only harmed by its quality of art, not ruined by it 08:54:15 whether meets this criterion or not 08:54:18 is for you to decide. 08:55:37 As far as I know, it means, if the (Maybe a) is (Just x) then the (b) should instead be (f \$ Just x) and the (a -> b) becoming (\a -> if a == x then f Nothing else f (Just a)) so there can be more than one answer; the simple definition is: bar f = (f Nothing, (Nothing, f . Just)) 08:57:08 zzo38: well, you need the answer that makes it a bijection along with foo 08:57:21 that looks like it would work 08:57:26 but I'm not sure what foo will do with that Nothing 08:58:32 -!- Ngevd has joined. 08:58:34 foo x (Nothing, f) = maybe x f; 08:58:40 Hello! 08:59:11 zzo38: and the Just case? :p 09:01:53 okokokokokokokokokokokokokokokokokokokokokokoko 09:01:55 okokokokokokokokokokokoko 09:01:58 okokokokokokokokokokokokoko 09:02:02 etc 09:02:06 foo x (Just y, f) Nothing = f y; foo x (Just y, f) (Just z) = if y == z then x else f z; 09:03:35 zzo38: strange that an Eq constraint is required 09:03:37 oklopol: hi 09:06:06 hies. 09:06:08 elliott: Yes it does seems strange. Am I correct about these functions though? It seem to me, that is how calculus says these functions are supposed to be, but I might have made some mistake 09:06:34 zzo38: It seems right to me, just strange. 09:07:21 Sgeo: I could see user friendly being funny if you lived in a 90s office culture clipart universe 09:07:44 Yes, it seems right to me too 09:07:51 zzo38: I'm glad you agree. 09:07:56 I think UF introduced me to Linux 09:08:16 Is (Maybe a) just a+1? 09:08:25 yes 09:08:48 Statement: as k approaches infinity, the curve y = x^(-k+1) approaches xy = 0 09:09:36 What is [a]? 09:09:48 I have used (Maybe a) to represent the "Sa" in Typographical Number Theory although it wouldn't seem to work unless you have a type that can only hold bijective functions 09:09:54 a^inf? 09:10:09 Sgeo: List(a) = 1 + a*List(a) 09:10:49 If a is >1, isn't that infinity? 09:10:53 So I suppose it is aleph 0 09:11:01 >=1 09:11:03 Sgeo: types are not, in fact, literally numbers. 09:11:48 How do I tell if I can do IPv6? 09:11:53 Ngevd: you can't 09:12:09 :( 09:12:32 But there must be some command for dealing with IPv6 isn't it? 09:12:38 How can I tell if my computer has an IPv6-capable internet connection? 09:13:00 It probably depend whether you are on Windows or Linux? 09:13:05 Ngevd: It doesn't. 09:13:13 If you're in the UK, it doesn't. 09:13:15 " Statement: as k approaches infinity, the curve y = x^(-k+1) approaches xy = 0" you have one crazy topology 09:13:17 Unless you're with, uh, Bogons or... 09:13:24 There's two other ISPs that do it. Absolutely nothing big name. 09:13:38 Oh 09:13:50 (1, 1) is always there for instance 09:13:54 I suppose ask the ISP if you want to know if they provide it 09:14:40 I'm with quite a big ISP 09:24:24 Can you write Applicative laws in terms of pure fmap liftA2 (,) 09:24:40 zzo38: didn't oerjan show you how to do that earlier? 09:25:18 elliott: oerjan confirmed it can be done; I don't remember if the laws were shown. 09:26:35 -!- derrik has joined. 09:26:48 zzo38: oh did you get my message thing? 09:26:58 pure = slide >>= pure or whatever 09:27:08 kallisti: What message thing? 09:27:30 :t \a b -> (a <\$>) <\$> b 09:27:31 forall a b (f :: * -> *) (f1 :: * -> *). (Functor f, Functor f1) => (a -> b) -> f1 (f a) -> f1 (f b) 09:27:32 the message says 09:27:35 pure = slide >>= pure 09:27:38 @hoogle (a -> b) -> f1 (f a) -> f1 (f b) 09:27:38 Prelude fmap :: Functor f => (a -> b) -> f a -> f b 09:27:38 Data.Functor fmap :: Functor f => (a -> b) -> f a -> f b 09:27:39 Control.Monad fmap :: Functor f => (a -> b) -> f a -> f b 09:28:30 kallisti: What is that, though? 09:28:45 oh I thought it was related to something you were doing. 09:29:58 kallisti: that was me, you idiot 09:30:22 I thought slide was a barrier monad thing 09:30:41 no 09:30:58 -!- Phantom_Hoover has joined. 09:31:21 hi Phantom_Hoover 09:35:12 elliott: hi 09:37:10 I may start AAARGH 09:37:19 DO'T SAY "I may"!!! 09:37:38 I am thinking about contributing to rosetta code 09:44:05 I reckon I can do an "is even" program with a 10 by 2 piet program 09:44:36 -!- pikhq_ has quit (Ping timeout: 244 seconds). 09:44:39 -!- pikhq has joined. 09:51:50 And most of that is getting it to say "y" or "n" 10:05:36 -!- Ngevd has quit (Ping timeout: 248 seconds). 10:11:53 -!- Ngevd has joined. 10:13:58 Hmmm 10:14:02 Hmmmmm 10:14:07 hmmmmm 10:14:15 A functional Piet-like language 10:14:39 Using a combitor stack 10:14:48 No 10:14:59 -!- derrik has quit (Quit: quitter). 10:15:39 Like Flobnar? 10:16:37 `word 25 10:16:45 scheishece ung adawskrakauffiilei meaneflics ths angezcatitionvermoderotmat pos calodikarountickepat serprierayalandeseuriocas of co chstit ratiouskinaveong mana la al vidifey verne fratee consic prics ceteghtaystrestishartheer anfree leinflucterquilecid per 10:26:58 At first I thought of number theory in Haskell types by using types that can only hold bijective functions, but now I thought, is there another way, by using type families? 10:34:09 -!- zzo38 has quit (Remote host closed the connection). 10:36:05 -!- sebbu2 has joined. 10:36:18 ceteghtaystrestishartheer 10:36:26 kallisti: did you ever finish that better version of word 10:36:43 no 10:36:50 it will happen though :P 10:36:57 I HAVE TWO WEEKS OF CHRISTMAS BREAK 10:37:08 and then the beginning of next semester will be pretty easy. 10:37:15 so I'll time there as well to work on projects. 10:39:13 -!- sebbu has quit (Ping timeout: 248 seconds). 10:39:48 Well, I've given up trying to write an Eodermdrone interpreter, on account of not actually understanding Eodermdrone 10:45:42 i'm so shocked 10:48:17 -!- Phantom_Hoover has quit (Ping timeout: 248 seconds). 11:02:01 -!- Phantom_Hoover has joined. 11:08:00 elliott: you should give Eodermdrone a try! 11:09:04 no 11:34:47 gah 11:35:02 i am not smart enough to write this function 11:36:14 Is it possible to write it in another language, such as pascal? 11:36:36 you expect that to _simplify_ my task? 11:37:23 no.. just being a smartass.. i apologize 11:37:54 apologise for what 11:38:00 being smartass 11:38:19 i don't see how you were a smartass 11:38:52 by suggesting pascal 11:46:34 -!- zzo38 has joined. 11:47:23 Hello, zzo38 11:48:15 "Once an order is out the door there's not much 11:48:15 we can do short of breaking into the post office in the middle of the night, and they keep a real mean dog in there now." 11:48:43 That sounds familiar 11:49:50 It's from this TopatoCo confirmation email. 11:50:09 Yes, I ordered a shirt from them 11:50:14 It is a nice shirt 11:50:23 But is it as nice as a Homestuck book??? (Answer: Probably.) 11:50:26 (But I got other things too!) 11:50:35 myndzi: I don't really have anything to say about that reply except that it's nonsense in places. The rows B35 and B36 are the same *time*: "UTC at midnight in Manila", and "Midnight in Manila"; they *must* yield equivalent Unix timestamp values. If you convert a Manila local time with toTimestamp to a Unix timestamp, it will not be a Unix timestamp representing that instant in time. (Also if you simply look at B33: Manila local time after "midnight(b8)" is 8am 11:50:35 . No matter how you muddle the waters, you have to subtract eight hours from 8am to end up to a midnight.) 11:51:41 fizzie: My daring counter-prediction came true! 11:53:06 But it's certainly possible the math happens to "work out" in practice. 11:53:18 extract ((Id 1 :*: Id 2) :*: (Id 3 :*: Id 4)) 11:53:19 :: Num a => 11:53:19 (:*:) (Id :*: Id) (Id :*: Id) (Loc ((Id :*: Id) :*: (Id :*: Id)) a) 11:53:27 Fun fun fun. 11:59:19 myndzi: As for the table, "midnight(unixtime+8)" is very much different from "midnight(unixtime)+8". When you do "midnight(unixtime+8)", what you end up doing is basically "convert unixtime to a value that, when converted to humantime assuming local time is UTC, will give Manila local time values; then clamp that to midnight of that day, giving the correct midnight". You'd need to subtract eight hours to get back the actual Unix timestamp representing that inst 11:59:19 ant of local time in Manila, but the rounding to midnight will work in that scenario.) 12:00:00 myndzi: I pointed out that that will work before: "(If it was "today, 01:00am" here, and you wanted to round to local midnight, you could (I'm not sure I would): add two hours to the timestamp, so you'd have a Unix timestamp that'd translate to UTC 01:00am; a different instant in time, yet same in local time. Then clamp to UTC midnight, which would end up subtracting the "proper" one hour. ---" 12:00:20 That was for our UTC+2, but the principle is the same. 12:00:26 Okay, I think that was enough of it. 12:02:48 -!- Patashu has quit (Quit: MSN: Patashu@hotmail.com , Gmail: Patashu0@gmail.com , AIM: Patashu0 , YIM: patashu2 , Skype: patashu0 .). 12:04:33 myndzi: Oh, one final explanation for midnight(unixtime+8) in terms of the document. It's just applying midnight() to the offsettime, so of course humantime() will return the correct-looking time. But it's still an offsettime, not a Unix timestamp representing that Manila local time. If you look at the G, H columns of the table, humantime() takes a Unix timestamp and returns the UTC human time, so the H column values are UTC midnights if you are treating G as a 12:04:33 Unix timestamp. 12:13:44 -!- derrik has joined. 12:13:50 fizzie: All I'm hearing is "SO MANY TYPE ERRORS". 12:17:15 -!- Slereah has joined. 12:17:37 -!- Slereah_ has quit (Ping timeout: 260 seconds). 12:38:09 -!- Ngevd has quit (Ping timeout: 248 seconds). 12:39:11 Under what circumstances is a derivative type a functor/applicative/monad/comonad? 12:46:27 fizzie: Can you summon oerjan? 12:56:25 -!- sebbu has joined. 12:56:25 -!- sebbu has quit (Changing host). 12:56:25 -!- sebbu has joined. 12:59:36 -!- sebbu2 has quit (Ping timeout: 252 seconds). 13:05:38 -!- oerjan has joined. 13:05:39 -!- elliott has quit (Read error: Connection reset by peer). 13:05:48 -!- MSleep has changed nick to MDude. 13:06:22 -!- elliott has joined. 13:16:34 -!- Ngevd has joined. 13:17:57 my cold seems to have got worse again :( 13:18:20 oerjan!!!!! 13:18:27 I've been waiting for hours so I can ask you about 13:18:29 QUAD 13:18:29 TREE 13:18:30 ZIPPERS 13:18:33 i am afraid that the only thing that can save me is the relief of knowing that i will never, ever, have to figure out those damn quadtree zippers. 13:18:40 NOOOOOOOOOOOOOOOoooooooooooooooo 13:18:55 OTHERWISE I WILL DIE 13:19:01 What's a quad tree? 13:19:05 oerjan: Does it help if they're only 1-cursor, not n-cursor, and I already have a formulation of them, and it only has two constructors? 13:20:00 Ngevd: it's a tree where each internal node has 4 branches; moreover they are labelled nw, ne, sw and se and are used to implement 2d maps 13:20:11 elliott: oh hm maybe 13:20:34 oerjan: In fact I daresay it's even elegant(!) 13:20:36 * oerjan _will_ regret this. 13:20:53 THAT'S COMPLETELY IMPOSSIBLE 13:21:21 didn't we discuss the 1-cursor case before going into that n-cursor madness 13:23:59 -!- Vorpal has quit (Quit: ZNC - http://znc.sourceforge.net). 13:24:14 oerjan: the one-cursor case is really easy, it's just 13:24:28 data QuadTree' a = Top | Fork Direction (QuadTree' a) (QuadTree a) (QuadTree a) (QuadTree a) 13:24:30 or in my version 13:24:40 data QuadTree' a = Top | Fork (QuadTree' a) (Four' (QuadTree a)) 13:24:54 you can derive that with the standard derivative rules 13:25:21 I'm struggling to understand this "quad tree" thing 13:25:26 -!- Vorpal has joined. 13:25:50 hi 13:26:12 Mine you, (.) confuses me and list zippers seemed obvious? 13:26:41 Ngevd, what is confusing about (,) ? 13:26:50 (.) 13:26:51 also I presume you meant "Mind you"? 13:26:54 oh right 13:26:59 :t (.) 13:27:00 forall a b (f :: * -> *). (Functor f) => (a -> b) -> f a -> f b 13:27:02 how is composition confusing 13:27:13 Can there be a typeclass for derivative types? 13:27:58 zzo38: http://hackage.haskell.org/packages/archive/functor-combo/0.1.0/doc/html/FunctorCombo-Holey.html 13:28:11 :t (Prelude..) 13:28:12 forall b c a. (b -> c) -> (a -> b) -> a -> c 13:28:19 okay that is the most awkward notation ever 13:29:57 elliott: O, that one uses type families; I suppose that works 13:32:36 -!- Ngevd has quit (Ping timeout: 252 seconds). 13:37:19 -!- Ngevd has joined. 13:38:15 I've just twigged how (->) r is a functor 13:38:17 :D 13:38:26 Haskell competency, here I come! 13:39:42 yay 13:39:51 next: how it is a monad. 13:40:08 I don't know what a monad is yet 13:40:17 ok after next, then 13:40:57 It is actually very simple: fmap = (.); return = const; join f x = f x x; 13:42:14 and each of them is obvious from the types they have to have 13:42:33 oerjan: Yes. 13:43:38 the tricky part is to realize that it could possibly be a monad in the first place 13:44:17 -!- Phantom_Hoover has quit (Ping timeout: 248 seconds). 13:44:20 oerjan: haskell zen 13:44:44 oerjan: please please please become haskell zen master 13:44:53 a, um... 13:45:02 yes 13:45:04 that's the first step 13:45:29 elliott, what is the type of clapping with one hand? 13:45:42 If you cannot get out of the monad, bring what you desire _into_ the monad! 13:45:51 :D 13:46:05 > f >>= (g :: Expr -> Expr -> Expr) \$ x 13:46:06 g (f x) x 13:46:09 (-> IO ()) 13:46:47 oerjan: become the monad you wish to see int he world --buddha 13:47:24 actually introducing the (-> a) monad when Ngevd doesn't really get monads in general yet is probably a bad idea? 13:47:49 there is no (-> a) monad 13:47:52 to the Applicative, the flow of the world is known from the beginning; to the Monad, it changes at every step. 13:48:05 return :: b -> (b -> a) -- impossible to implement 13:48:19 oerjan: you did not succumb to my trolling :( 13:48:35 which trolling? 13:48:41 oerjan: become the monad you wish to see int he world --buddha 13:48:53 elliott: what is the function monad then. 13:49:12 kallisti: ((->) r) 13:49:17 now that _return_ type there is trolling, though. 13:49:21 elliott: ....... -_- 13:49:25 that's what I meant 13:49:28 that's not whaty ou said 13:49:31 (+ a) 13:49:32 ((+) a) 13:49:34 not the same thing 13:49:37 no shit. 13:49:53 If the input type is a monoid then it makes a comonad as well. extract = (\$ mempty); duplicate f x y = f \$ mappend x y; 13:50:01 Only the negative cannot fully operate in the world. 13:50:26 elliott: Well in that case it is commutative but OK 13:50:32 well, yes :P 13:50:36 zzo38: but not necessarily! 13:50:38 Num has no laws. 13:50:59 zzo38: does that mean Writer is a comonad, even without monoid? 13:51:23 hm obviously snd is extract 13:51:32 er 13:51:41 oerjan: Yes. 13:51:43 :t runWriter 13:51:44 forall w a. Writer w a -> (a, w) 13:52:09 zzo38: so there is a sort of duality between Reader/-> and Writer/(,) 13:52:25 :t extract 13:52:26 forall source. (Extract source) => (Int, Int) -> source -> source 13:52:32 :( 13:54:08 Well, you can use the ((,) a) type (which I also made a Monad instance of; I don't particularly like the names "Reader" and "Writer") in which case: extract = snd; duplicate (x, y) = (x, (x, y)); 13:55:08 oerjan: OK yes I suppose so, there is that sort of duality. I didn't realize it at first, but yes that is how it work 13:56:31 oerjan: this is surprising? 13:56:32 it's in the names 13:56:53 zzo38: i think the Reader and Writer names are so that one can use their abstract API without confusing with prelude types 13:56:55 -!- Phantom_Hoover has joined. 13:57:03 which have many other uses 13:58:25 Well, the names are useful for making monad transformers ReaderT and WriterT names 13:59:07 what's the name of the ST transformer? 13:59:08 STT? 13:59:13 there is none 13:59:23 lame. 13:59:35 (The comonad library has the instances for (-> a) and ((,) a) in there; my monoidplus library has the monad instance for ((,) a)) 13:59:38 kallisti: you can't implement it safely without it being really slow. 14:01:15 -!- azaq23 has joined. 14:02:05 return = (,) mempty; join (x, (y, z)) = (mappend x y, z); 14:04:11 hm would state also be a comonad with a monoid restriction? 14:05:58 some join definitions are so much simpler than the corresponding >>= 14:06:00 Bye 14:06:01 -!- Ngevd has quit (Quit: Goodbye). 14:11:17 what is the exact relation between join and >>=? 14:11:46 > [1,2,3] >>= (return.return) 14:11:47 No instance for (GHC.Show.Show (m t)) 14:11:47 arising from a use of `M6416529558... 14:12:01 kallisti: join = (>>= id); 14:12:01 x >>= f = join (fmap f x), join x = (x >>= id) 14:12:25 ah 14:12:40 right that makes sense. 14:13:00 definitely should add join to Monad. 14:13:05 and fmap f x = x >>= return . f, to complete the correspondence 14:13:19 -!- pikhq has quit (Ping timeout: 252 seconds). 14:13:24 -!- pikhq_ has joined. 14:14:07 :t join .: fmap 14:14:08 forall (m :: * -> *) a a1. (Monad m, Functor m) => (a1 -> m a) -> m a1 -> m a 14:15:12 hmmm 14:15:22 kallisti: the thing is you still couldn't make a default for >>= based on join until Monad subclasses Functor 14:15:26 so you could actually automatically define Functors for Monads. 14:15:32 but I'm guessing haskell doesn't do this by default? 14:15:39 nope, hysterical raisins 14:15:58 haskell makes it too hard to rearrange the class hierarchy 14:16:06 @info Monad 14:16:06 Monad 14:16:08 .. 14:16:17 I thought Functor was required for a Monad instance? 14:16:20 kallisti: there isn't actually an @info command, you know 14:16:43 oerjan: but... but I want to believe in lambdabot... 14:16:47 you're just being fooled by spelling correction 14:17:02 @tyep x 14:17:03 Expr 14:17:06 @info do x <- test; return (2*x) 14:17:07 test >>= \ x -> return (2 * x) 14:17:21 ........info = undo??? 14:17:23 how 14:17:41 TOO MUCH LEVENSHTEIN DISTANCE 14:17:51 :D 14:17:56 ....well 14:17:58 not really. 14:18:18 2 much 14:18:23 * elliott awaits oerjan kick. 14:18:30 I actually used a levenshtein-like algorithm in detecting typos with some operations having different weights 14:18:48 * oerjan kicks elliott with the BOOT |__\ 14:18:57 :'( 14:19:50 so substition was 2, insertion was 3, deleting was 2, and swapping two letters was 1. 14:19:51 hm, where is the code for making show on a [Char] pretty print like a string? 14:19:58 :t showList 14:19:59 forall a. (Show a) => [a] -> String -> String 14:20:10 then instance (Show a) => Show [a] where shows = showList 14:20:13 it's a hideous hack 14:20:17 ouch 14:20:18 showList is in the Show class itself 14:20:39 horrible 14:21:03 Vorpal: Better than Erlang. 14:21:04 elliott, so doing something similar for [MyOwnType] would be impossible? 14:21:11 Perfectly possible. 14:21:13 That's what showList is for. 14:21:15 ah 14:21:16 right 14:21:46 what is showsPrec in Show for? 14:21:56 precedence 14:22:04 huh 14:22:31 "pretty print like a string" doesn't Show already do this for [Char]? 14:22:54 > showList "hello" 14:22:55 Overlapping instances for GHC.Show.Show 14:22:55 (GHC.B... 14:23:16 > show 'a' 14:23:17 "'a'" 14:23:20 >_> 14:23:44 :t showList 14:23:45 forall a. (Show a) => [a] -> String -> String 14:23:49 ...oh 14:23:54 elliott, what about doing it for other things than lists? Like, say a "Rope a" type? 14:24:03 (or whatever) 14:24:23 Vorpal: You can't. 14:24:25 ah 14:24:30 > showList "what" "what" 14:24:31 Well. 14:24:31 "\"what\"what" 14:24:35 That's not strictly true. 14:24:40 But it's painful and won't work how you want. 14:24:56 > show "what" 14:24:57 I see 14:24:57 "\"what\"" 14:25:03 what's... different about show and showList here. 14:25:08 so that is the bit that is such a horrible hack then 14:25:13 well, one part of it 14:26:36 * kallisti confused 14:26:49 kallisti: showList is defined in the show instance for a, but is used to define show for [a] 14:26:57 *Show instance 14:27:10 I understand that 14:27:10 but 14:27:14 no you don't 14:27:19 I don't understand what they are accomplishing. 14:27:22 or trying to accomplish 14:27:27 > ['a','b','c'] 14:27:28 "abc" 14:27:30 > [1,2,3] 14:27:31 [1,2,3] 14:27:34 note discrepancy 14:27:35 elliott: I understand what showlist does 14:27:40 read: I understand what showlist does 14:27:43 kallisti: they're accomplishing that Strings can be shown in a different format than other [a]'s 14:27:46 kallisti: incorrect 14:27:49 if you understood 14:27:52 you would not be asking these questions 14:27:54 myndzi: Oh, one final thing: here's example tables of my own for all three of "clamp to midnight, add eight hours", "clamp to midnight, subtract eight hours" and "convert to 'offsettime' by adding eight hours, clamp to midnight, convert back": https://docs.google.com/spreadsheet/ccc?key=0AoJ9OAzXNfZAdG5ESEZ3MzBkWW9nWEJTYXI0NFdaQmc&hl=en_US#gid=0 14:28:02 what does vorpal mean by "pretty printing strings" 14:28:13 and how is it different that what happens in Prelude by default. 14:28:15 fizzie: High hopes, do you? 14:28:17 that is my question. 14:28:19 Have. 14:28:20 For this. 14:28:21 kallisti, > ['a','b','c'] "abc" <-- this is what I mean 14:28:34 kallisti: he is referring to what the Prelude does 14:28:40 elliott: As of now I've seriously, finally, honestly, truly, done. 14:28:40 ..oh 14:28:42 okay. 14:28:49 I thought Vorpal was trying to do something different from what the Prelude does. 14:28:53 nevermind. 14:28:54 fizzie: Even if he disagrees?! 14:28:58 elliott: (Except if I figure out one more way to say the same thing.) 14:29:34 showList could easily be lifted to other typed via a separate typeclass. 14:29:44 *types 14:30:02 kallisti: what? 14:30:13 showSomethingElse :: (GoodNameHere s, Show a) => s a -> String -> String 14:30:20 showList dpends on being in the Show typeclass to work. 14:30:31 *depends 14:30:40 elliott: sometimes you are ridiculously presumptuous about what it is people don't understand... 14:30:51 oerjan: s/people/kallisti/ 14:30:55 kallisti: you could not implement showSomethingElse in any instance 14:31:11 unless GoodNameHere basically makes s a isomorphic to [a]. 14:31:21 in which case it's not very useful 14:31:23 as you could just use showList. 14:32:27 what about a 2-param typeclass with a Show instance? 14:32:33 ...is that a thing you can do? 14:32:42 showList dpends on being in the Show typeclass to work. <-- well you _could_ add (usually empty) instances all over the place for the separate typeclass 14:32:49 what becomes a legal instance when you enable extensions is kind of fuzzy to me. 14:32:56 oerjan: yes. that's not what kallisti is proposing though 14:34:34 i guess OverlappingInstances could also work for this, maybe not without flaws. 14:34:43 that's what I was thinking. 14:35:26 apparently it kind of sort of works 14:35:34 it was proposed for Vector 14:36:03 iiuc the flaw being that you could sometimes not get the specific instance if there wasn't enough information to tell that it applies 14:36:58 Can you use multi-parameters type class? 14:38:47 (insufficiently late resolution, and then choosing the general instance because it's the only one already present) 14:39:53 -!- derrik has quit (Quit: gone). 14:42:15 -!- zzo38 has quit (Remote host closed the connection). 14:43:03 oerjan: at least with the most common case (Char) I don't think that would be an issue though 14:43:50 kallisti: there could be an issue with polymorphic functions 14:44:10 -!- ais523 has joined. 14:45:12 like if you are having f :: Show a => (a, [a]) -> String; f (x, l) = show x ++ ": " ++ show l 14:45:38 and because of the explicit type declaration, you _cannot_ use the specific instance for Show [a] 14:45:49 i think. 14:45:57 i haven't actually tested this stuff :P 14:48:38 huh, weird. 14:49:00 apparently clients don't like it when you disappear for 6 months because of RAPIDLY PILING BACKLOG OF HOMEWORK 14:50:24 :D at today's http://www.mezzacotta.net/postcard/ 14:52:33 the image refuses to load. 14:52:38 :D 14:52:45 XD 14:52:46 oh... 14:52:47 right 14:52:47 :P 14:53:02 elliott: ok you're right, kallisti _is_ special 14:53:25 I assume you can only mean special in a very awesome way. 14:53:32 but of course. 14:53:38 I guess I was just expecting 14:53:41 something funnier? 14:53:46 ;_; 14:54:00 like maybe if I could get the image to load 14:54:02 hi ais523; what do you call a meta-embarrassingly parallel problem 14:54:06 the joke would be funny. 14:54:11 that is, an embarrassingly parallel problem where each unit of work is itself embarrassingly parallel 14:54:30 elliott: parallel embarassment trees 14:54:41 elliott: it's still just ordinary embarassing parallelism, isn't it? 14:55:05 ais523: but now it's _really_ embarrassing! 14:55:35 elliott: but any embarassingly parallel problem with enough elements is two embarassingly parallel problems; the first half, and the second half 14:55:37 etc 14:56:17 -!- Phantom_Hoover has quit (Ping timeout: 248 seconds). 14:56:51 -!- Phantom_Hoover has joined. 14:57:39 elliott: just mergesort and you'll be fine. 14:57:40 >_> 14:57:55 * kallisti good advice 14:58:20 ais523: but this is embarrassingly parallel /squared/! 14:58:45 kallisti: nah, bitonic sort 14:59:04 it's basically the same algo as mergesort, but adapted for parallel implementation 14:59:08 elliott: wow that sounds strangely relevant to your quadtrees! 14:59:24 much the same way as an FFT is one way to do a DFT, a bitonic sort is one way to do a mergesort 14:59:38 14:59:38 --visible text on [[Bitonic sorter]] 14:59:48 lol 14:59:59 let's push it for featured article status. 15:00:27 elliott: that /is/ correct comment syntax in Wikipedia, so presumably someone escaped it, perhaps by accident 15:00:44 ais523: it's in a code block 15:01:34 aha, that probably explains it 15:01:40 http://28.media.tumblr.com/tumblr_lrbca4gZCE1qdtcgvo1_500.jpg 15:01:48 you don't want to know how MediaWiki parses extension tags (such as GeSHi's ```) 15:02:05 and I can easily imagine that it would pass comments literally to the extension without parsing them 15:04:18 ais523: it should, is valid code in many languages 15:04:24 such as HTML 15:04:36 agreed 15:05:00 it's a syntax error in INTERCAL, though 15:06:50 hmm, it's valid, and potentially even useful, brainfuck, though 15:11:25 > let so it = isn't in 1 3 15:11:26 2 15:16:26 oerjan: I'd call that valid but not potentially useful 15:18:58 A lot of au pairs, especially those who are new to the role, don't know what to expect when they get started do the job with a new host household. Even though your principal duty would be to care for the little ones, there are also a array of other household tasks you could be asked to do. The aim of this article is to give you a fast insight into the forms of tasks you might be anticipated or asked to do. 15:19:08 ais523: --> is a perfectly plausible operator name 15:19:19 yep, but ) 15:19:24 parse error (possibly incorrect indentation) 15:19:29 ? 15:19:42 I didn't expect a parse error from that; is it the starting with - that matters? 15:19:50 :t \a b -> a --> b 15:19:52 forall t t1. t -> t1 -> t 15:19:56 that _should_ be legal 15:20:06 :t (--+test) 15:20:08 parse error (possibly incorrect indentation) 15:20:11 yep, and that verifies that there's an --> operator already, which doesn't surprise me 15:20:25 It's just lambdabot failing 15:20:26 :t (-*) 15:20:27 Not in scope: `-*' 15:20:32 … 15:20:35 GHCi handles it correctly 15:20:38 :t (--test) 15:20:39 parse error (possibly incorrect indentation) 15:20:48 :t (-+-test) 15:20:49 Not in scope: `-+-' 15:20:49 Not in scope: `test' 15:21:02 i think it is breaking the comment parsing rules 15:21:15 that _shouldn't_ be a comment 15:21:20 (--test) is supposed to be a parse error 15:21:22 yep, it seems to get confused by -- 15:21:24 (--+test) and (-->) aren't 15:22:14 which given that that's comment syntax, is a plausible thing for it to be confused by 15:22:58 personally, I think that for a language with -- comments, the correct comment introducer should be "-- " with the space 15:23:04 otherwise you get too many clashes 15:23:11 :t (--) 15:23:13 parse error (possibly incorrect indentation) 15:23:19 yep, but ```