00:26:42 I found something called "The Online Book Initiative". It seem pretty good. It is at gopher://gopher.std.com 00:44:06 -!- itidus21 has joined. 00:44:56 -!- SteppenwolfVM has joined. 00:45:06 -!- SteppenwolfVM has left ("Oh look.... it's a part!"). 00:54:41 -!- SteppenwolfVM has joined. 00:55:31 -!- SteppenwolfVM has left ("Oh look.... it's a part!"). 01:00:57 -!- GreaseMonkey has quit (Read error: Connection reset by peer). 01:01:41 -!- GreaseMonkey has joined. 01:25:29 -!- Sgeo has quit (Ping timeout: 240 seconds). 01:39:56 -!- Sgeo has joined. 02:10:09 -!- Sgeo has quit (Quit: Leaving). 02:11:58 @hoogle [a] -> ([a], [a]) 02:11:58 Prelude break :: (a -> Bool) -> [a] -> ([a], [a]) 02:11:58 Data.List break :: (a -> Bool) -> [a] -> ([a], [a]) 02:11:58 Prelude span :: (a -> Bool) -> [a] -> ([a], [a]) 02:12:14 also partition 02:12:32 @hoogle+ 02:12:33 Data.List span :: (a -> Bool) -> [a] -> ([a], [a]) 02:12:33 Data.List partition :: (a -> Bool) -> [a] -> ([a], [a]) 02:12:33 Prelude splitAt :: Int -> [a] -> ([a], [a]) 02:12:37 @hoogle+ 02:12:37 Data.List splitAt :: Int -> [a] -> ([a], [a]) 02:12:38 Data.List genericSplitAt :: Integral i => i -> [b] -> ([b], [b]) 02:12:38 System.FilePath.Windows splitDrive :: FilePath -> (FilePath, FilePath) 02:13:05 -!- Sgeo has joined. 02:13:19 * Sgeo decides to use Conduit Sources as his primary model of events 02:13:55 lucky for you elliott is not around, eh? 02:15:46 * oerjan checks in the obvious place to see if he's alive 02:17:43 so? 02:18:09 seen 4 hours ago 02:24:28 -!- zzo38 has left. 02:24:31 -!- zzo38 has joined. 02:27:43 although his rep was a lot lower yesterday than "usual" 02:28:03 type the devil's nick and his taskbar will alert him 02:28:15 hi 02:28:42 itidus21: i did that 14 minutes ago, didn't i 02:29:31 i suspect he's asleep now, anyway 02:29:56 ahh.. hexham sleeps 02:30:52 i'm not sure whether the rest of hexham sleeps has much to do with it. 02:31:12 *whether whether 02:31:22 > break isSpace "" 02:31:23 ("","") 02:31:46 > break undefined "" 02:31:47 ("","") 02:32:36 oerjan: I'm trying to do something really simple 02:32:46 namely, remove all consecutive whitespace 02:32:47 and also 02:32:53 remove whitespace from both ends of the list 02:32:56 at the same time 02:33:02 kallisti: unwords . words hth 02:33:03 unwords . words 02:33:05 yes 02:33:05 while preserving the kind of whitespace (no unwords . words) 02:33:14 bah :D 02:33:27 \v\t: which gets preserved??? 02:33:35 neither 02:33:38 :o 02:33:40 oh 02:33:41 yes 02:33:42 good question 02:33:50 and what about in \r\n 02:33:54 ssshh 02:34:24 worrying about \r\n is too sensible 02:34:46 does anyone even use \v\t? 02:35:11 ok wheres my finnish speakers 02:35:22 sleeping 02:35:35 :( 02:35:44 päimavaar 02:35:50 fizzie! D: 02:35:54 you know perfectly well fizzie is the only op with a sane sleep schedule :P 02:35:59 @tell fizzie msg me plz 02:35:59 Consider it noted. 02:36:19 although ais523's occasionally is 02:36:23 hagb4rd: you speak finnish? 02:36:26 no 02:36:30 o :( 02:36:37 `words --finnish 50 02:36:41 astannettäviltämin eettamatto pallisilmällä autuvautuvistansa paimpänne havoliita kepeimuttelemme sfäärittämä kuolisimpana löyläpikalve takoskivamme uintaanne mustamme vaileviltanne aggressäästä nihatekemistä ryhmimpaa uneen lensa joutumastipa ologisempääsi samistanne tyyliltaan hämälleni soittu 02:36:49 the only word i knew was date 02:36:49 augur: HackEgo can help 02:36:56 no it cant :( 02:37:06 *gasp* 02:37:23 hagb4rd: i suspect you broke vowel harmony by using both ä and a 02:37:34 -!- yiyus has quit (Ping timeout: 255 seconds). 02:37:36 only once? 02:37:41 *phew 02:37:51 yea 02:37:52 also -r is probably not a common word ending in finnish 02:38:29 not common, but right 02:38:33 not? 02:39:02 you know a good dictionary? 02:39:04 -!- yiyus has joined. 02:39:10 for finnish 02:39:35 hagb4rd: you will note that every word HackEgo generated ends with a vowel or -n. i think -t also happens in some case. 02:39:50 no. i don't _actually_ know finnish. 02:40:07 tswett might know. 02:40:11 aw..bad luck then :Pp 02:40:26 (and be awake, unlike the finns) 02:40:29 i thought you were norwegian? 02:40:54 i must have been wrong 02:40:59 i am. norwegian is not related to finnish. 02:41:19 yes, thats y i wonder 02:41:30 wheres oklopol :( 02:41:34 -!- pir^2 has joined. 02:41:37 i'm just somewhat generally interested in linguistics 02:41:49 oerjan: well you're in luck! i'm a linguist! 02:41:56 there's also Deewiant 02:41:58 w00t 02:42:01 a linguist! 02:42:02 i said _somewhat_ 02:42:03 Deewiant isnt a linguist 02:42:11 no, he's finnish 02:42:26 and atehwa 02:43:04 and ineiros 02:43:48 just to nickping all the ones i remember :P 02:44:57 Is there a word for people from Finnmark? 02:45:01 Finnmarkish? 02:45:05 finnmarking 02:45:11 (noun) 02:46:36 normally we'd make the adjective by adding -sk, but that gets awkward when the word already ends in -rk... 02:47:38 Do you live in Finnmark? 02:48:00 (no need to answer...) 02:48:05 I might know! 02:48:29 paimaväär? 02:48:37 like "trøndersk" has 445000 google hits while "finnmarksk" only has 700 or so 02:48:45 no, i live in Trøndelag 02:48:52 (Trondheim) 02:49:22 paimaväär looks like a plausible Finnish word, though, as has been said, I don't think Finnish words commonly end in r. 02:49:58 On the other hand, the Finnish Wikipedia article "Koira" has no words at all ending in r, apart from words in other languages. 02:50:06 So... no. 02:50:14 hm actually checking a couple other counties implies "trøndersk" might be the odd one out 02:50:15 `words 50 02:50:20 Hilighting in the middle of the night. 02:50:21 gen fnh ovepo ffervedransag aga isperi writtr ipnley sual late kossen dia copin lley camatt capple hysia care hem oile pitia ress cour whiteropolle come 02:50:38 Are those supposed to be plausible English words, because... because... 02:50:54 tswett: yep. 02:50:56 umm 02:50:59 english is _weird_, man 02:51:00 `words 50 02:51:06 pard mvl supe frenoy elmakener crealtic yrity seruntla tszew mastop nobwer whltcherline ret sphill ghen geffe coated smatrik orditry toight forgnific ath caffe minaniflb homodynin 02:51:11 What languages can it do? 02:51:13 All of them? 02:51:16 `words --spanish 50 02:51:21 molizaglia yntesione estron debíalen tentrotaliza penio náis jinéis alleión tkopiesestraguay consen cermi fcpcct her bastonj desma plictoria morizacionas evolu hoolimporte prado kosorbelila indisti antate retambell 02:51:32 *+s 02:51:44 `words -- sindarin 50 02:51:44 `words --french 50 02:51:53 `words --sindarin 50 02:51:57 Unknown option: sindarin 02:51:59 Argument "sindarin" isn't numeric in int at /hackenv/bin/words line 147. \ 02:52:08 `words --french 50 02:52:09 -!- Mathnerd314 has quit (Ping timeout: 248 seconds). 02:52:12 ... 02:52:13 burg concart traient albaction lutionstassi eluy massoix fufiel macation abinum aflad dof einetés logîa letaçoo trandas procb voh chus nac frigius trani fbcf mouchi ben 02:52:23 lulz 02:52:29 fbcf? 02:52:48 crock suddi agustympos hydrio rodults shimi agolge appel orèze morosco milauto hidussor perfè charging sitibus aliti tima guère ebate aniershaneguyeri incripteradjes gnatter nappé confeld éluct 02:52:58 Whelp. Some of those Spanish words are more likely than others. 02:53:23 "morizacionas"? Yes, definitely. "fcpcct"? No. 02:54:08 éluct la plè des agustympos 02:54:11 `words --german 50 02:54:15 beschauf eriknm bewer spcne eleidiskaufbauer weibweizki geschachepur megassung folgepube erbaziffenerescher moden zuwachfarbe vollendessfei metaktorschi umredgingenblutur lottelle derin rollia krokalkonverhalthe pres stoff betheitsgestris drowerke türzeugeueren durcenssyrit 02:55:04 it might be improvable 02:56:03 `words --scots 10 02:56:06 Unknown option: scots 02:56:10 }:( 02:58:02 concart? Anything like concat? 02:58:38 `? concart 02:58:41 concart? ¯\(°_o)/¯ 02:59:53 Let's see. Part, supe, mastop, nobwer, ret, sphill, coated, smatrik, orditry, forgnific, ath, late, capple, care, hem, ress, come... 03:00:27 I just asked it for words and it said "guraul gei spokesfo pitte lausgen tbutylike unmiflex guan affympan cereaco vauli consalpa injr fair macaller sumab thrifog petero ghert wholog graz 942124.25 viilplant plum avelli" 03:00:32 One of those words is not like the others. 03:00:43 Please note: In less than 27 hours, 03:00:44 the English Wikipedia will be blacked out globally in protest of SOPA and PIPA. 03:00:46 Learn more 03:01:06 tswett: 942124.25 03:01:18 XD 03:01:24 That is correct! 03:01:44 unmiflex! 03:03:28 im sure there is no words in german ending with -knm or -ki.. there is also no german word with a 'standalone' c (only ck, or ch) 03:03:34 this tool is crap 03:04:38 no 03:04:52 In my opinion it's very traeusal 03:04:59 lol 03:05:32 It's also very imisreent 03:05:44 ...or is that a noun? 03:06:02 Oh my god best word ever: "wapellessly" 03:06:15 :D 03:06:30 It's an O:B-quality word. 03:06:47 hagb4rd: i won't be on the -ki, germans have some fearsome diminutives 03:06:51 *bet 03:07:50 its mostly -ei -er -ig -en 03:08:13 +ending with 03:09:08 "mcgockeleof". That makes me imagine some guy named George McGockelEOF. 03:09:23 (see: Schnappi) 03:09:34 you know schnappi? :) 03:09:41 the crocodile? 03:09:56 and Heidi. i cannot actually recall any german name in -ki, though 03:10:03 oh yes and i 03:10:14 hagb4rd: how could i possibly have avoided Schnappi 03:10:28 hehe 03:10:36 amazing facts 03:11:15 there was a norwegian actor with nickname "Henki" though, is that a german name? 03:11:54 i guess it was short for henrik, though 03:11:59 the i ending is used in cases of belittlement 03:12:03 exactly 03:12:15 its like tom and tommy 03:12:30 know what i mean? 03:12:58 well in english i think tommy is short (um...) for tom, which is short for thomas. 03:13:16 * oerjan recalls there was a hilarious blackadder sketch about this 03:13:24 see also jennifer -> jenny 03:13:42 bob - > bobby 03:13:57 and so on 03:14:58 bob is short for robert 03:15:18 yea.. but you agree that tommy is not "short" for tom 03:15:19 bobby is long for bob 03:15:29 well 03:15:30 won't ya 03:17:20 i'm not sure 'belittlement' is the right translation.. my dict also says: minimization 03:19:49 schnappi would be the minimized form of 'schnapper' 03:20:16 schnappen means to snap 03:20:31 the usual word in english for this sort of construct is "diminutive" 03:20:39 thx 03:20:48 consider it noted :) 03:21:30 kmc, what do you think about exposing events as Sources? 03:21:36 hey i already said that :( 03:21:37 what's a Source 03:21:59 kmc, the Conduit equiv. of Enumerators 03:22:00 source of all evil 03:22:10 oh sorry oerjan 03:22:40 i don't know much about Conduit yet 03:22:43 did you ask #haskell 03:23:04 hask and you shall ell 03:23:13 Yeah, but maybe too casually for anyone to take note? 03:23:46 you have to start out by saying "HASKELL SUX CUZ I CANT IO Int -> Int" 03:23:57 once you have their attention you can tell them what you're really trying to do 03:27:22 yep oerjan..in hindsight everything you said is right 03:29:32 AS ALWAYS 03:30:45 which can get quite embarassing. like that time i foolishly said that Stockholm is the capital of Sweden. 03:32:13 * Sgeo doesn't get it 03:32:32 its not? 03:32:40 hagb4rd: well _now_ it is. 03:33:09 ESOTERIC SUX CUZ I CANT IO Int -> Void 03:33:49 ... 03:39:47 BRAINFUCK SUX CUZ I CANT SOLVE THE HALTING PROBLEM 03:39:48 What do you mean by those things? 03:40:23 zzo38: what? 03:40:35 There is (IO Int -> Int) using unsafePerformIO but you shouldn't use that usually 03:40:53 pir^2: I was mentioning "ESOTERIC SUX CUZ I CANT IO Int -> Void" 03:41:26 http://i.imgur.com/YY3LI.png 03:41:28 if the halting problem is solved it might coincide with the end of the universe 03:41:42 yay 03:42:00 if the universe can end then the halting problem is solved :-? 03:42:40 only practically 03:42:50 Turing machines are theoretical 03:42:52 oh 03:42:56 bummer 03:43:00 well 03:43:03 :P 03:43:05 nobody will care 03:43:16 (unless they're from another universe) 03:43:44 singularity goes a long way 03:43:48 so what is the halting problem again? whether a program will halt? 03:44:33 Write a program to determine whether arbitrary Turing machines halt? 03:46:06 http://esoteric.voxelperfect.net/wiki/Weight_Loss_Clinic_Calgary ... 03:46:30 For more information, please follow me.. Lefebre Calgary Clinics - Medical Diet since 1998.. Welcome to the Lefebre clinic.. Call today.. The clinic is available ZERONA Dr.. Lefebre! . 03:46:30 -!- Zuu has quit (Ping timeout: 252 seconds). 03:46:33 the probelm of course is that if you could do that then you never needed the turing machine 03:46:46 -!- Zuu has joined. 03:48:00 what 03:48:02 hmm 03:48:06 nevermind 03:48:24 ... 03:48:26 ???????????? 03:48:36 "you never needed the turing machine" 03:48:38 finally im confused 03:48:54 lol 03:48:56 so, when programming a turing machine, does the programmer tend to know whether it will halt? 03:49:01 * pir^2 is laughing at "you never needed the turing machine" 03:49:04 yes 03:49:16 XD 03:49:16 kmc: and so, how does he know? 03:49:28 by writing a proof, in some sense 03:49:37 you're asking "when you write a program, how do you know what it does" 03:49:47 yeah 03:49:47 For some turing machines, it's possible for a turing machine to determine whether or not it halts. But no turing machine can say perfectly 100% of the time 03:49:49 i guess so 03:49:57 i am 03:50:03 humans have some capacity to generate proofs 03:50:04 Either it fails to answer sometimes, or gives false positives, or false negatives, or 2 or more of the above 03:50:05 so do computers 03:50:27 all computer programs halt 03:50:36 *in practice 03:51:21 "does it halt" is just one example of the general problem of predicting program behavior 03:51:55 There exist programs for which humans are uncertain about whether they will halt 03:52:26 yeah, like the program that finds counterexamples to 03:53:06 Collatz conjecture? Goldbach conjecture? P vs NP? True? 03:53:18 I just solved True 03:53:28 yeah collatz is a good example 03:54:55 * pir^2 -> HOTPO -> 1 -> 2 -> 1 -> 2... 03:57:45 itidus21, it's easy to generate a proof that some machine halts on some specific input 03:57:52 it's just a trace of the execution of that machine 03:58:09 but if the machine doesn't halt, it's hard to prove that 03:58:54 though in some cases it's easy, for example if it enters the exact same state twice 03:58:58 it may also be hard to prove that a machine halts for *all* inputs 04:00:58 !finnmark bye 04:02:01 -!- pir^2 has quit (Quit: I have discovered a truly marvelous demonstration of this proposition that this quit message is too narrow to contain). 04:02:19 -!- MDude has changed nick to MSleep. 04:02:27 All computer programs halt if your notion of "halting" includes heat death. :P 04:03:04 pikhq_: NOT IN THEORETICAL LAND DAWG 04:04:51 itidus21: You seem utterly confused about the halting problem. :) 04:05:20 hm, so 4,2,1 would make an endless loop? 04:05:37 if not catched? 04:06:27 okay. 04:21:55 the 500 bucks are already mine..muahrhr 04:37:26 seems to me that several guys will solve the halting problem without knowing each other and be super famous for it 50 years later 04:44:43 itidus21: Turing already proved it was impossible. 04:44:56 Unless there's a glaring flaw in his proof, done. 04:45:13 i got confused by " BRAINFUCK SUX CUZ I CANT SOLVE THE HALTING PROBLEM" 04:45:21 or unless we change to different definitions 04:45:26 itidus21, it was an intentionally dumb statement 04:45:57 d'oh 04:46:09 all caps, bad grammar and spelling 04:47:05 i understood that it was a mockery, but i didn't realize that the meaning of it was also wrong 04:47:49 it's very easy to prove the halting problem is impossible 04:48:27 suppose (by contradiction) that you have a function halts(f) = true if f(x) halts for all x, halts(f) = false if f(x) loops for some x 04:49:00 * oerjan swats kmc for misrepresenting the problem -----### 04:49:02 now define the function g(x): if (halts(g)) then { loop forever } else { return } 04:49:13 oh misrepresenting how? 04:49:15 all that matters to me is that it's solved :D 04:49:26 x is supposed to be an argument to halts as well 04:49:49 x is a free variable :P 04:49:58 aren't both problems unsolvable, though 04:50:03 probably. 04:50:27 anyway the only subtlety is that g needs a copy of its own description 04:50:36 by solved i probably mean that we realize it's unsolved 04:50:48 and it's not obvious that you can do this 04:50:50 s/unsolved/unsolvable 04:50:53 but you can 04:51:19 in mathematics this is known as Kleene's recursion theorem 04:51:25 in esoteric programming it is known as writing quines :) 04:51:52 If there are an infinite number of possible inputs, can you make a function that stops if and only if the program you are testing will stop for all inputs? 04:52:01 g(x) = if halts(x,x) then { loop forever } else { return } 04:52:39 Those g(x) stuff have been described in book Godel, Escher, Bach, although using Godel numbering instead of like that. 04:53:34 then ask if halts(g,g) is true or not 04:57:19 yeah, that's better 05:00:22 your version can be reduced to this by defining myhalts(g,x) = yourhalts(\y -> g(x)), i think 05:01:31 (and of course if you want to be really precise, you should not confuse the notation for functions and the strings representing them) 05:02:37 yeah 05:02:58 that reminds me of C#, where lambda is also a quote 05:03:53 "lambda is also a quote"? 05:05:40 istr old lisps also confused lambdas and their list representation; of course lisp is designed to make that almost harmless 05:06:01 Sgeo, if you have a function value that came from a lambda, you can also inspect the syntax tree of its definition 05:06:11 it should be noted that I haven't used C# and just read about this once 05:06:21 (the "almost" is because afaiu it essentially forces dynamical scoping) 05:07:01 similarly if f is a function in CPython, you can use f.func_code to get its bytecode 05:07:02 or well, non-lexical 05:07:53 i think there is other harm 05:08:02 you lose the ability to treat functions as black boxes 05:08:18 you lose abstraction 05:08:40 if i pass a function to some library, that library can care about the implementation details of my function 05:09:06 Picolisp has very not-black-box functions 05:09:10 If you have a newspaper, tell me what the "horoscope" section says (including the dates) and tell me your timezone. I wish to try an experiment with them 05:09:25 "news... paper"? 05:09:40 Yes, a newspaper. Do you have one? 05:33:48 If the newspaper was published in a different timezone as your own, I would like their timezone as well as yours. 05:54:31 -!- NicePants has joined. 06:40:05 Are there any quad precision floating point in Haskell? 06:43:44 http://hackage.haskell.org/packages/archive/Decimal/0.1.0/doc/html/Data-Decimal.html 06:43:45 öfde 06:43:59 precise enough? 06:45:44 that's... not floating point 06:45:52 nope 06:46:09 there's a binding to mpfr but it has hella caveats 06:46:12 http://hackage.haskell.org/package/hmpfr 06:46:16 No; I need logarithms and trigonometry 06:48:42 O, OK, yes hmpfr includes trigonometry. But it says there is errors on it 07:00:44 Do you know if there is any ephemeris softwares for Haskell, or how to make such a things? 07:00:47 -!- Klisz has quit (Quit: SLEEP, GLORIOUS SLEEP). 07:04:09 kmc: Sorry. :-( 07:04:18 what did you do? 07:04:30 or, is that the other kind of "sorry" 07:04:48 Not speaking English to the President. 07:05:02 Oh, I thought you left because of my kmc-blood-pressure joke. 07:05:20 Which I'll admit wasn't a particularly good one. 07:05:39 no, i left because people were saying dumb things and I did not feel like correcting them 07:05:47 which was also probably why you made the joke 07:05:49 i just wonder why there is such a discrepance in the terminology of quad precision between german and english sources. in german quad precision describes any format using 4 'units' of memory, while the english ones determines it to floats..strange 07:07:29 Ah. Fair enough. 07:07:31 bagb4rd: I did specify floating point, at least. 07:07:39 yes 07:14:29 -!- pikhq_ has quit (Ping timeout: 240 seconds). 07:14:31 -!- pikhq has joined. 07:24:06 Is there a way in Haskell to make a Double value with is large or infinite? 07:26:04 > 1 / 0 07:26:04 Infinity 07:28:50 wow SPJ's article on the STG is insane. 07:28:58 I'm afraid I only understand bits and pieces of it. 07:29:18 which one? 07:29:31 the one that someone linked me. 07:29:48 Implementing lazy functional languages on stock hardware: the spineless tagless g-machine 07:29:53 that's a cool paper 07:29:58 yes 07:30:11 if you read that one and also "Typing Haskell in Haskell" then you will have most of the specific knowledge to write a decent Haskell compiler 07:30:22 I understand the general points, some of the implementation bits so far, and the actual STG language itself. 07:30:40 I don't fully understand the in-memory representation 07:30:51 "How to make a fast curry" is another good paper that picks up from where the STG one ends 07:31:06 just that it's always a closure with free variables. 07:31:53 this is mainly because, as of late, my short term memory has been getting even worse than previously. :P 07:32:13 the in-memory representation of closures (including data and thunks) is in "Figure 4: The layout of a closure" on page 46 in my copy 07:32:45 oh I haven't gotten there 07:32:48 I am all the way on page 29 07:33:04 there's a pointer to an "info table", followed by whatever data fields (for constructors) or free variables (for thunks and function closures) 07:33:24 right 07:33:27 yes that's what I meant 07:33:29 the info table is static data; roughly speaking there's one for each lambda in the source, and one for each ADT constructor 07:33:53 yes I was reading about how closures can be reused and such. 07:34:12 and i guess one for each let binding, to implement that thunk 07:34:18 yes 07:34:30 it treats all the lets as "lambda forms" even if they have zero arguments 07:34:55 (which kind of brings some truth to the "zero argument function" claim... I guess at an operational level) 07:35:00 heh 07:35:03 of course mathematically a zero-argument function is meaningless. 07:35:42 looool I love taking the easy way out on easy math homework. 07:36:16 right, it's also meaningless at the level of haskell semantics 07:36:21 kmc: yes 07:36:31 it might be a reasonable way to understand the implementation details of certain haskell compilers 07:36:33 not that I actually know anything about haskell semantics 07:36:41 I just... know that it wouldn't make any sense. intuitively. 07:37:00 we're starting the course with some set theory. One of the questions asks for a subset of the powerset of the integers. I answer with the empty set. :P 07:37:11 likewise GHC implements multi-argument functions as multi-argument functions, even where the semantics say they are curried single-argument functions 07:37:24 haha 07:37:26 of course those "zero argument functions", being thunks, will be overwritten after evaluation 07:37:32 best subset ever 07:37:49 the subsetiest of all 07:37:54 hm i guess that's true of non-zero ones too 07:38:16 a thunk wouldn't ever have arguments 07:38:22 now it wants an element from the powerset of integers 07:38:25 I think I'm gonna have to go with... 07:38:26 empty set. 07:38:28 haha 07:39:00 AAAAAAUGH NOW THERE'S A CARDINALITY RESTRAINT? 07:39:02 WHAT IS THIS SHIT. 07:39:07 I HAVE TO ENUMERATE THINGS? 07:39:08 FUCK THIS 07:39:08 kmc: but if it closes over variables, those will be effectively the arguments to whatever function implements the thunk 07:39:09 * kallisti quites. 07:39:30 oerjan, i guess you can look at it that way 07:39:43 STG makes a distinction between free variables and arguments 07:39:56 ugh so many squiggly brackets on paper, and I'm so bad at writing them. 07:40:01 the code finds them in different places, iirc 07:40:01 kmc: indeed 07:40:31 I found using the closures of data values to implement optimizations an interesting idea. 07:40:36 I'm guessing there's more detail later. 07:40:42 what idea is that? 07:40:44 the paper covers quite a bit of the top-level in the first few pages. 07:41:18 kmc: the paper mentions that you could do things like copy values to registers in a value's closure. 07:41:21 In my program, the types used for floating point are given using type synonyms, so they can be changed later if necessary. 07:41:28 mm 07:41:36 an ADT value? 07:41:46 it didn't really specify very much. 07:42:00 in current GHC you don't enter values in the fast case 07:42:15 oh I see. 07:42:34 I guess it could have just been an idea and not something that GHC actually attempts. 07:42:43 ghc might also do that 07:43:12 in general, you could add any kind of code that you want to be associated with forcing that value, I believe. 07:43:23 then you're not entering a value though 07:43:25 you're entering a thunk 07:43:27 or well, not even forcing it right? just evaluating it. 07:43:41 er... entering it 07:43:41 yes. 07:43:44 what's the distinction between "force" and "evaluate" 07:43:50 I meant enter 07:43:53 that's the terminology used in the paper. 07:44:15 I used "evaluate" incorrectly. :P 07:45:05 i guess if you don't load the fields into registers, then you just return to the caller and they get the values at an offset from the original closure 07:45:12 except they might have to follow an indirection too 07:45:52 anyway current GHC uses the least significant bits to tag a pointer to a closure which is known to be in whnf 07:45:58 so in the best case you don't have to enter it at all 07:45:58 yes it mentions that function arguments are accessed as offsets from the "environment register" which is the pointer to the closure code I believe. 07:46:05 *nod* 07:46:08 I assume the same is true of ADTs? 07:46:18 guess so 07:46:28 it wouldn't make sense for them to be free variables I think. 07:46:34 the fields, I mean. 07:46:45 I GUESS 07:46:45 wait, no 07:46:46 I SHOULD LIKE 07:46:49 READ THIS PAPER 07:46:56 since it starts explaining the ADT part, exactly where I left off. 07:47:00 i'm pretty sure the fields of an ADT value are like free variables 07:47:01 well actually it's explaining unboxed stuff. 07:47:08 they are closed over when the ADT value is construcetd 07:47:16 haha very well 07:47:37 but actually I'm going to write more squiggly brackets for my math class. 07:47:40 they demand more from me. 07:48:02 haha 07:48:06 these ones? {} 07:48:25 yes those are the ones 07:48:28 except mine never look like that. 07:48:39 moustaches 07:48:39 I just make squiggly lines 07:48:54 i had to learn how to write '&' for AP CS back in the day 07:48:55 that was hard 07:49:09 oh yes 07:49:12 I never get that right. 07:49:22 writing Java with a pencil is so..... weird. 07:49:39 it's even more tedious than usual. 07:49:50 hehe 07:49:52 * pikhq mutters 07:50:00 I'm having to take an intro to CS course. 07:50:10 I had somehow gotten exempted from it at a previous university. 07:50:13 Not so here. 07:50:17 I sometimes write computer codes by hand too; I often write Haskell codes by hand. 07:50:17 :/ 07:50:23 kmc: so the update flag has nothing to do with strictness right? 07:50:25 Guess I'm learning Java. 07:50:32 kmc: or do I misunderstand? 07:50:42 kallisti, iirc only thunks are updatable 07:50:45 kmc: it seems like an optimization of lazy evaluation where sharing isn't required. 07:50:47 so it has to do with non-strictness ;P 07:50:52 hmm? 07:50:56 you mean that sharing is not always required? 07:51:03 kmc: yes I haven't gotten to how it implements strict values yet. 07:51:13 i'm not sure what you mean by "strict value" 07:51:25 not thunks. 07:51:27 >_> 07:51:35 meaning algebraic data and functions in whnf? 07:51:42 anyway you'd set the update flag to "no" if you can prove a given thunk is only entered once 07:51:48 yes 07:51:52 that saves you the trouble of updating it 07:51:52 and you do this because 07:51:57 that value isn't being shared. 07:51:58 right? 07:52:03 right 07:52:13 cool 07:52:20 * kallisti is understanding some things. 07:52:29 well the /value/ might subsequently get shared 07:52:37 value = a thing which has been evaluated 07:52:47 that particular lambda is not shared though 07:52:49 but you use it if the thunk /before evaluation/ can't get to multiple places 07:52:55 ah 07:53:04 I see 07:53:52 the update flag is "part" of the sharing 07:53:56 er 07:53:57 I mean 07:54:02 updating the thunk is part of the sharing implementation 07:54:06 yes 07:54:07 and turning it off is an optimization 07:54:37 but the value itself can still be shared by virtue of being a value addressed in memory. :P 07:54:43 >_>? 07:55:51 -!- augur has quit (Read error: Connection reset by peer). 07:56:06 hm 07:56:10 -!- augur has joined. 07:56:12 that's really rather vague though 07:56:27 if you're at a point where you know something is a value (not a thunk), then you are free to duplicate pointers to it, regardless of what the update flag says 07:56:35 yes 07:56:50 is the update flag still there, even? 07:57:02 in GHC i think it's implicit in the closure type 07:57:18 oh right everything has the same representation 07:57:22 http://hackage.haskell.org/trac/ghc/wiki/Commentary/Rts/Storage/HeapObjects 07:57:24 or, so far... that's what I've learned. 07:58:45 note that GHC these days is eval/apply rather than push/enter 07:58:49 oh I see. 07:58:59 some of these closure types don't make sense in the context of the original STG paper you're reading 07:59:15 yes there's some new things. 07:59:29 see "How to make a fast curry" 08:00:03 yes the paper was discussing that the advantages and disadvantages of eval/apply vs. push/enter, so I'm guessing eval/apply wins? 08:00:09 -that 08:00:32 pretty much 08:02:07 so does the "tagless" qualifier also mean that sum types do not have tags on them? or is this simply referring to not having tags on the heap objects. 08:04:06 I'm not sure I can see how you would select on multiple constructors without some kind of tagged union representation. 08:06:12 yeah I guess it obviously does still retain that kind of "tag" 08:06:25 (apologies if I'm not making any sense I'm pretty tired I should probably sleep) 08:07:05 i think one would need to look at what the earlier G-machines were like to understand what that means. unless the paper does a comparison, i don't recall. 08:08:07 oh it explains it 08:08:20 I was asking if it has additional meaning beyond that.... but I guess not. silly question. 08:09:16 a have this vague idea that the spine and tag may have been connected to when these things were thought of as doing explicit reduction on graphs... 08:10:02 it's tagless in that it doesn't branch of a tag to determine what kind of memory representation is being used. 08:10:14 aha 08:10:35 at least in this paper it has a uniform layout. you access values by "entering" them (jumping to their closure code) 08:11:19 but apparently GHC does eval-apply now, not sure how that works in relation to entering date/code. 08:11:23 i think some things in ghc were later changed to _not_ use indirect jumps because it ruins branch prediction 08:11:52 or something like that 08:12:10 branch prediction sounds kind of magical. 08:12:53 well afaik it's something the CPU does 08:13:53 right, i think the "tags" refers to using some bits of a pointer to tell you what's pointed to 08:13:55 guessing which way a branch will go so it can run the pipeline that way - but if it guesses wrong, it has to stop the pipeline 08:14:17 which is something GHC does do now 08:14:22 (and i vaguely recall the guess is mainly "same as last time") 08:14:23 but something they avoid in the original STG paper 08:14:47 oerjan, another common heuristic is that forwards branches are not taken, and backwards branches are taken 08:14:52 aha 08:15:08 the latter often represent loops, which run many times before exiting 08:15:21 makes sense 08:15:24 it's said that common x86 chips correctly predict 99%+ of branches 08:15:29 i don't have a reference on that number though 08:15:53 presumably common compilers do their best to assure they do that :P 08:16:06 yeah 08:16:22 also you can embed hints in the code 08:16:28 and GCC supports this at source level 08:16:40 Linux kernel code is full of stuff like if(unlikely(monkeys_have_escaped)) { ... } 08:17:40 kallisti, for an example of a system using tag bits, see http://repetae.net/computer/jhc/manual.html#the-run-time-system 08:17:46 right, i think the "tags" refers to using some bits of a pointer to tell you what's pointed to <-- um that's about ghc's modern tags, i wasn't sure the "tags" that indirectly named the STG were the same kind 08:17:55 yeah i am not sure either 08:17:57 but i think so 08:18:11 the STG paper goes into some detail about how they know whether a given word is a pointer to a garbage collected object 08:18:18 kmc: so at this point GHC's STG is a bit of a misnomer. 08:18:29 -!- zzo38 has quit (Remote host closed the connection). 08:18:34 it would be ironic if ghc's STG has ended up being neither spineless nor tagless :D 08:18:53 closures and update frames have a layout known from the info table, and the stack is split between a pointer stack and a primitive stack 08:18:56 fortunately the acronym is the same. 08:19:00 spined tagged g-machine 08:19:04 this is all to avoid tagging gc pointers vs. primitives 08:19:06 yay 08:19:06 #define unlikely(x) __builtin_expect(x, 0) 08:19:07 BTW 08:19:11 -!- FireFly has quit (Changing host). 08:19:19 *...* i 08:19:21 right so there are at least two things you can use pointer tagging for 08:19:32 (a) to distinguish pointers the gc must follow from other values 08:19:41 (b) to mark which things are already in whnf 08:19:47 GHC does (b) now but still does not do (a) 08:20:36 aiui, one of the innovations of the STG paper is the idea that even Int should be an algebraic type, with an unboxed value inside 08:20:42 the latter being not a first-class Haskell value 08:21:14 BTW^2, __builtin_expect docs have a nice dig against programmers in general: "In general, you should prefer to use actual profile feedback for this (-fprofile-arcs), as programmers are notoriously bad at predicting how their programs actually perform." 08:21:14 fizzie: You have 1 new message. '/msg lambdabot @messages' to read it. 08:21:15 you push the burden of distinguishing heap pointers into the closure layout and calling convention 08:21:23 haha 08:21:26 it's true 08:22:17 kallisti, this is why the Haskell Report only requires that Int support the range [-2^29 .. 2^29-1] 08:22:25 to allow for 2 tag bits even on 32-bit machines 08:22:39 in GHC this is not an issue because you can always tell Int from Int# statically 08:23:49 fizzie: So, "unless you're a Linux or x264 dev, don't". :P 08:24:37 GCC also has __attribute__ ((hot)) and s/hot/cold/ function attributes, which are completely ignored if you -fprofile-use like you should. 08:24:38 i don't see how they are exempted. 08:25:08 oerjan: They spend a lot of time measuring performance. 08:25:11 Especially x264. 08:27:13 linux also moves supposedly cold functions into separate linker sections 08:28:15 Industry tip: a function flagged as 'cold' which actually is called often, and therefore should be warmer, is called 'hypothermic'. (Not true.) 08:28:31 true facts 08:32:30 is it true that it's true or is it true that it's untrue 08:32:30 help 08:33:00 -!- augur has quit (Read error: Connection reset by peer). 08:33:17 monqy: is it true that help 08:33:27 -!- augur has joined. 08:33:36 always and forever 08:34:13 ⊤ 08:34:40 > sequence . concatMap (\x -> if x `elem` "aeiou" then "aeiou" else [x]) $ "is it true that help" 08:34:41 Couldn't match expected type `m a' 08:34:42 against inferred type `GHC.Types... 08:35:12 > sequence . map (\x -> if x `elem` "aeiou" then "aeiou" else [x]) $ "is it true that help" 08:35:14 ["as at traa that halp","as at traa that help","as at traa that hilp","as a... 08:35:33 > sequence . map (\x -> if x `elem` "aeiou" then "aeiou" else [x]) $ "help" 08:35:34 ["halp","help","hilp","holp","hulp"] 08:35:46 > mapM (\x -> if x `elem` "aeiou" then "aeiou" else [x]) $ "help" 08:35:47 ["halp","help","hilp","holp","hulp"] 08:35:52 monqy: hulp 08:35:54 kmc: oh right 08:36:01 you forgot hlep 08:36:01 that's the thing that M means 08:36:08 , hepl 08:36:15 monqy: no wrong 08:36:16 , ehlp 08:36:18 not forgotten 08:36:22 (++"M") = (sequence .) 08:36:34 i remember when somebody asked for a list function on haskell-cafe 08:36:38 and they golfed it for a while 08:36:44 and then someone realized it was just 'sequence' 08:36:47 hole in one 08:36:53 sequence is the best always. 08:38:18 :t flip 08:38:18 forall (f :: * -> *) a b. (Functor f) => f (a -> b) -> a -> f b 08:38:19 (++"M") = ("(sequence.)"++) only in the boring case. 08:38:31 sequence flips your ordered sequence of possibilities turnways. 08:38:32 Usually M functions have more information than the non-M functions. 08:38:39 sometimes lambdabot's flip is the same as sequence 08:39:13 > flip [succ,pred] 1 08:39:15 [2,0] 08:39:16 > sequence [succ,pred] 1 08:39:17 [2,0] 08:40:11 and that case is frequently useful in golfing 08:40:18 > let (++"M") = (sequence.) in map (\ x -> if x `elem` "aeiou" then "aeiou" else [x]) ++ "M" $ "help" 08:40:19 : Parse error in pattern 08:40:27 cries 08:40:52 kallisti: hint, sequence . map f = mapM f 08:41:16 "Say, do you fellows enjoy the particular game of golf? I've got three lids out in the Hudson and enough Zig-Zag to wipe God's ass and the devil too." 08:41:31 oh wait 08:41:37 @ty sequence . filter ?f 08:41:38 forall (m :: * -> *) a. (Monad m, ?f::m a -> Bool) => [m a] -> m [a] 08:41:39 * oerjan is so late 08:41:58 maybe #esoteric is secretly the real #haskell-in-depth 08:41:59 oerjan: I... yes you're very late 08:42:03 oerjan: you're several months late. 08:42:15 Half the time #esoteric is #haskell-in-shallow 08:42:27 that too 08:42:38 #esoteric is really the secret #haskell-in-depth 08:42:38 And of course, there's @ 08:42:45 But only when elliott is around. 08:42:52 @-in-width 08:42:53 Unknown command, try @list 08:42:55 no it's #haskell-not-lame-totally-awesome 08:43:01 isn't there some way to have an IRC chan that starts with @ 08:43:15 be on a server that supports it 08:43:19 Yes, for values of "@" equal to "#@" 08:43:22 or #haskell-in-breadth 08:43:33 I think I remember what + channels do 08:43:37 but I forget what & channels do 08:43:45 #haskell-in-bread 08:43:46 or did I get those confused 08:43:56 Mmm. Bread. 08:44:01 * shachaf should eat more regularly. 08:44:04 breaded #haskell 08:44:37 https://plus.google.com/103943309878727777440/posts/DCdBqZX3bvQ 08:46:19 no I'd say #esoteric is more like #sometimes-haskell-and-without-human-tutorials 08:47:17 cool now i know how to use google as a qr code generator 08:47:18 what does the tutorialing then 08:47:19 https://www.google.com/chart?cht=qr&chs=276x276&chl=http://example.com&chld=L%7C0 08:48:10 "While we have concluded this particular experiment, we constantly experiment with new and more secure authentication mechanisms." 08:48:14 It was working when I tried it before. 08:48:50 monqy: `? 08:48:58 `? monad 08:49:03 Hahahahaha have you guys seen Colbert's Super PAC's videos http://www.colbertsuperpac.com/episodeiv-anewhope/ 08:49:09 Monads are just monoids in the category of endofunctors. 08:49:09 They're such hilarious parodies of the current primary/political state 08:49:09 `? what is a monads 08:49:13 `? help 08:49:14 what is a monads? ¯\(°_o)/¯ 08:49:25 Patashu: are you suddenly a spam bot? 08:49:27 `? hjälp 08:49:31 hjälp? ¯\(°_o)/¯ 08:49:32 \m/ \m/ 08:49:32 `\o/´ 08:49:33 myndzi: You have 1 new message. '/msg lambdabot @messages' to read it. 08:49:33 | 08:49:33 (_|¯'¯|_) 08:49:40 \m/ \m/ \m/ \m/ 08:49:43 `? \m/ \m/ 08:49:44 `\o/´ 08:49:44 | 08:49:44 /´\ 08:49:44 (_| |_) 08:49:45 8===D 08:49:47 ​\m/ \m/? ¯\(°_o)/¯ 08:50:13 help? ¯\(°_o)/¯ 08:50:20 yeah I'm a spam bot WHAT UP 08:50:24 look at the videos I post :( 08:50:50 "episode IV" sounds like an unpleasant drug-related thing. 08:51:25 achewood claims Hi-Five is slang for HIV 08:59:08 i have a message what 08:59:23 o nice 08:59:25 shachaf: erm it's the official title of a star wars movie 08:59:48 (namely the original one) 09:00:48 i'm guessing shachaf knows that 09:00:59 POSBBILE 09:01:12 also ahem it was originally released as just _Star Wars_ 09:01:22 ASOL POBSSILE 09:02:16 Yeah, calling it Episode IV was the first of many edits. 09:02:47 the _first_? 09:05:49 -!- NicePants has quit (Ping timeout: 240 seconds). 09:06:16 "The opening crawl of the sequels disclosed that they were numbered as "Episode V" and "Episode VI" respectively, though the films were generally advertised solely under their subtitles." 09:06:20 huh. 09:06:36 -!- Zuu has quit (Ping timeout: 252 seconds). 09:06:42 Let me put it this way: the only way to get something even *approximating* the original theatrical release is a Laserdisc rip. 09:07:26 pikhq: yeah i just wasn't aware the prequels were included in the numbering before they were released 09:07:27 (approximating because it uses the somewhat strange stereo mix, not the original mono mix. Just like everything else.) 09:07:45 Ah. Yeah, the prequels were decades in the making. 09:07:53 Thus the disappointment from everyone. 09:08:56 also means people who saw the original trilogy as children were seeing the prequels as jaded adults 09:09:29 I saw the prequels as a child, and even then they were kinda lame. 09:09:48 Much of the annoyance with it came only later, but even then "... Eh." 09:09:56 i found them all to be entertaining enough 09:10:04 but kinda pointless filler 09:10:12 same for the matrix sequels 09:10:34 Yeah, that's just it. Essentially all they were was a couple of plot points, spread out between 3 films. 09:10:49 like if you wanna have fun watching an action movie, you can do a lot worse than _The Matrix Reloaded_ 09:11:02 but it's not special the way the first one was 09:11:10 Why is the first one special? 09:11:30 shachaf: Much less detail gone into the psuedophilosophicalness. 09:11:36 Really? 09:11:49 It sets up an atmosphere very well. 09:11:52 "pseudophilosophy" is the word I was about to use to describe it. 09:11:53 the plot was both more interesting and more sensical 09:12:13 shachaf: The whole series does pseudophilosphy. 09:12:15 it's more fun to watch the scrawny hacker guy become a superhero 09:12:17 Just to varying extents. 09:12:23 less fun to watch him flying around as a superhero 09:12:26 It seemed like it was primarily about violence/action/whatever, and not very interesting from most other perspectives I could think of. 09:12:49 Yeah, it was using that as a neat atmosphere for the fun violence/action. 09:13:15 the philosophy in the first movie was pretty shallow but they didn't try to overextend it 09:13:19 not nearly like the others 09:13:28 -!- Zuu has joined. 09:14:41 I'd say it's a little bit like Valve games. They're not usually huge on plot. (seriously, you can cover the plot of all of their games in 10 minutes, tops) 09:14:50 i generally thought the first half of the movie was more interesting than the second 09:14:56 But they've got setting polished to a mirror shine. 09:15:49 * shachaf wonders what a good movie is. 09:16:05 you want some recommendations for good movies? 09:16:29 "The only good movie is a dead movie." (Old saying of the jungle.) 09:16:29 I was wondering specifically among movies I've seen, but sure. :-) 09:16:45 I saw _Casablanca_ a few days ago. That was pretty well-done. 09:16:49 i don't see enough movies these days 09:16:52 Shame the medium's considered so utterly important. 09:16:59 Honestly, the form is incredibly limited. 09:17:13 -!- myndzi\ has joined. 09:17:20 i definitely have more opinions on which TV shows are good than which films 09:17:24 ~2 hours max? That's more analogous to a freaking short story or a novella. 09:17:38 yeah 09:17:51 I have _Brazil_ on my list of movies to watch. 09:18:29 _The Wire_ tells a novel-size story in about 13 hours 09:18:38 even there, you could probably put multiple seasons into one novel 09:19:41 -!- myndzi has quit (Ping timeout: 240 seconds). 09:19:51 i can't really imagine watching that show one episode per week 09:19:57 but i don't really do that for any shows 09:36:47 -!- zzo38 has joined. 09:36:54 No! 09:37:01 Red! 09:37:21 Black! 09:37:51 Hay! That's *my* name! 09:38:18 -!- oerjan has set topic: No topic Wednesday! | Wait, it's not Friday?? Damn it! | Now in colors! | So, what is blegnian motion, anyway? | http://codu.org/logs/_esoteric/. 09:38:44 zzo38: What's your last name? 09:38:57 Black 09:39:06 Oh. I thought it was your first name. 09:39:12 What's your first name? 09:40:03 Will you figure it out if you look at my Haskell packages? They have my name on it because I uploaded them, and it always has the name of whoever uploaded them 09:41:16 But I don't really like the terms "first name" and "last name", because they are racist; and I don't like "Christian name" either because that is even more racist. 09:42:14 -!- GreaseMonkey has quit (Quit: The Other Game). 09:42:25 kmc: I think zzo38 just outdid you. 09:42:28 you shouldn't care about racism in name order unless you're a hung arian 09:42:52 How about "personal name" and "family name"? 09:43:15 shachaf: Yes I do prefer those. 09:43:35 I can't find any packages of yours on Hackage. 09:44:14 oerjan: I don't really care much; I still prefer freedom of speech. But I still generally prefer to be not racist 09:44:22 shachaf: My name is AaronBlack. Now can you find it? 09:44:42 Ah, yes. 09:45:12 -!- oerjan has quit (Quit: WHEEEEEEEEEEEEEEEEE). 09:46:43 shachaf: Not very culturally universal, sadly. 09:46:54 Not all cultures give surnames. 09:51:12 pikhq: Yes, I know. 09:53:05 -!- monqy has quit (Quit: hello). 09:55:09 Also, "family name" is ambiguous; it might refer to a "generation name". 10:12:29 -!- augur has quit (Ping timeout: 240 seconds). 10:14:29 -!- Patashu has quit (Quit: MSN: Patashu@hotmail.com , Gmail: Patashu0@gmail.com , AIM: Patashu0 , YIM: patashu2 , Skype: patashu0 .). 10:44:07 one might also say, group name vs individual name >:-) 10:45:14 -!- pikhq has quit (Ping timeout: 240 seconds). 10:45:19 -!- pikhq has joined. 11:29:02 -!- myndzi\ has quit (Ping timeout: 255 seconds). 11:33:53 -!- ais523 has joined. 11:36:55 -!- aloril has quit (Ping timeout: 248 seconds). 11:40:26 -!- aloril has joined. 11:43:22 -!- _Slereah has changed nick to Slereah. 11:45:26 -!- Frooxius_ has joined. 11:48:59 -!- Frooxius has quit (Ping timeout: 252 seconds). 11:49:08 -!- Frooxius_ has changed nick to Frooxius. 11:55:27 -!- myndzi has joined. 12:18:07 -!- Vorpal has joined. 12:20:57 -!- zzo38 has quit (Remote host closed the connection). 12:49:28 -!- Phantom_Hoover has joined. 12:54:27 `? monoid 12:54:33 Monoids are just categories with a single object. 12:54:58 `? category 12:55:02 Categories are just categories. 12:55:40 `? monad 12:55:44 Monads are just monoids in the category of endofunctors. 12:55:45 `? endofunctor 12:55:49 endofunctor? ¯\(°_o)/¯ 12:55:51 ^ omission. 12:56:47 Endofunctors are just arrows in the monoidal category? 12:56:55 `? arrow 12:56:58 arrow? ¯\(°_o)/¯ 12:57:34 Arrows are just members of homsets. 12:57:48 Arrows are just bad hombres. 13:01:07 -!- Phantom_Hoover has left ("Leaving"). 13:01:13 -!- Phantom_Hoover has joined. 13:01:22 Wait why did nobody tell me elliott went nuts. 13:04:21 Also paimaväär sounds vaguely Estonian to me. 13:06:53 They tend to do that thing, where Finnish would have a wovel at the end. en:leg = fi:sääri = et:säär, en:ash (tree) = fi:saarni = et:saar. 13:09:09 Päivämäärä, though, is a Finnish word. (Date. As in, "time and date".) 13:09:28 `words --finnish 20 13:09:33 mallenne elpoistäsi saansa urasvat autoviulosaansa lohdistelevaltani ilmästä luonipahoisti vaististamme ruoinne tartisuulet uusistasiatyynimista enneettävinansa epäislaista astaan taisemmalta uuvutta kouluminä ohjakinkö jahtavanisimeroksen 13:25:39 Phantom_Hoover: weren't you there at the time? 13:25:47 ais523, nope. 13:25:57 I'm actually kind-of worried he hasn't returned since 13:26:57 1:38 on Monday morning. I definitely wasn't there. 13:28:42 Translated from your sillytimes, 3:38 on Monday morning; no wonder I wasn't there. 13:29:02 Presumably this is why nobody mentioned it when I asked where he'd gone. 13:32:32 Also isn't that a Sunday? 13:33:13 It... yes. 13:33:38 -!- Phantom__Hoover has joined. 13:39:20 -!- Phantom_Hoover has quit (Remote host closed the connection). 13:46:00 ah thats it fizzie..Päivämäärä 13:48:13 now tell me where is the relation to any other language spoken on this planet 13:48:24 if there is any 13:49:47 Estonian is a relative; "kuupäev" ('moon-day') is their corresponding word, I think. 13:49:51 hard to explain how language developes in such a different way..isnt it? 13:50:27 -!- Frooxius_ has joined. 13:51:24 Language people also always say Hungarian is related, but that's farther away. 13:52:44 -!- Frooxius has quit (Ping timeout: 272 seconds). 13:52:54 -!- Frooxius_ has changed nick to Frooxius. 13:54:54 fizzie: I was in Hungary and they were talking about Hungarian a bit for the benefit of the large contingent of Brits there at the time, then they put a Finnish sentence on the board to see if any of the Hungarians there understood it 13:55:06 and the answer was, no, but they all had "oh, right" moments when it was explained 13:55:19 apparently Hungarian isn't really like any other language, except for Finnish 13:55:30 vocab-wise 13:55:46 is there any historical relation between these counties? 13:56:13 "Linguistic roots common to both branches of the traditional Finno-Ugric language tree (Finno-Permic [i.e. Finnish, Estonian] and Ugric [i.e. Hungarian]) are extremely distant. -- According to philologist Mall Hellam there's only one mutual sentence: “the living fish swims in water.” (Finnish: Elävä kala ui veden alla), (Estonian: Elav kala ujub vee all), (Hungarian: az élő hal vízben úszik)." 13:57:21 heh, the Hungarian only vaguely resembles the other two 13:58:06 wikipedia has "Eleven hal úszik a víz alatt." 13:58:22 sounds like the linguists stuck there too 13:58:35 http://en.wikipedia.org/wiki/Uralic_languages#Example_sentence 13:58:44 Yeah, "they" always mention the relatedness, but it's not really obvious to a "language muggle" (am I using this term right?). 13:59:19 kmc: Heh, the other Hungarian example was also from Wikipedia: http://en.wikipedia.org/wiki/Finno-Ugric (second paragraph). 13:59:27 Inconsistencies? In my Wikipedia? 13:59:50 I suppose it could be just an alternative way of saying it. 14:00:06 One that arranges the words more in the same order. 14:00:14 (I don't know anything about Hungarian at all.) 14:00:44 i wonder y the language did not mix up with the languages in the skandinavian neighbourhood in any way 14:01:02 Calling "Eleven hal úszik a víz alatt" "mutually intelligible" is going a bit far, though. 14:01:29 these people seem to prefer to be on their own in some way 14:01:42 do we have any finnish people here? 14:01:47 btw 14:01:48 hagb4rd, what makes you think it didn't? 14:01:57 "Over the course of many centuries, the Finnish language has borrowed many words from a wide variety of languages, most from neighboring Indo-European languages. Indeed, some estimates put the core Proto-Uralic vocabulary surviving in Finnish at only around 300 word roots." 14:02:23 We've got quite a few loans also from Russian. 14:02:52 Not sure if "borrow" is the right word, we're certainly not going to give any of them back. 14:03:07 hagb4rd, what makes you think it didn't? <- obviously the language 14:03:30 hehe 14:04:30 so you 14:04:36 are a fin fizzieß 14:05:14 ? 14:08:52 Yes. 14:09:01 I am finished. 14:09:42 -!- ais523 has quit (Remote host closed the connection). 14:11:31 fizzie: okay.. one last question: what does this humppa mean? is just like unz unz unz unz? fun? 14:12:01 It's a genre of music. 14:12:11 And I guess also the associated dance. 14:12:19 But informally could be used to refer to any number of things. 14:12:51 like 'jump' ..maybe? 14:13:02 Well, any sort of bouncing around, maybe. 14:13:27 k.. thanks for the infos :) 14:13:53 Also see http://en.wikipedia.org/wiki/Humppa -- that looks to be more or less correct, except it only talks of the official meanings. 14:17:05 bounce? official meanings.. i see :P 14:17:52 do not bounce with my woman dude! 14:20:01 @hoogle Chan a -> Chan a -> Chan a 14:20:02 Control.Applicative (<|>) :: Alternative f => f a -> f a -> f a 14:20:02 Language.Haskell.TH.Syntax qRecover :: Quasi m => m a -> m a -> m a 14:20:02 Control.Monad mplus :: MonadPlus m => m a -> m a -> m a 14:53:36 -!- Phantom___Hoover has joined. 14:54:58 -!- Phantom__Hoover has quit (Ping timeout: 244 seconds). 14:58:00 -!- ais523 has joined. 15:41:30 -!- Phantom___Hoover has quit (Ping timeout: 240 seconds). 15:41:51 -!- Phantom___Hoover has joined. 15:57:11 -!- augur_ has joined. 16:05:06 -!- Mathnerd314 has joined. 16:08:34 -!- MSleep has changed nick to MDude. 16:11:50 -!- hagb4rd has quit (Ping timeout: 240 seconds). 16:22:44 -!- Ngevd has joined. 16:29:29 Hello 16:32:25 What is a comonad? 16:34:02 The categorical dual of a monad. 16:34:13 i.e. a monad with all the ->s swapped. 16:35:04 (>>=) :: m a -> m b ->(a -> m b)? 16:35:22 -!- pikhq_ has joined. 16:35:44 -!- pikhq has quit (Ping timeout: 252 seconds). 16:35:45 It's not that. 16:38:46 Could you explain it better? I really have no idea, I'm afraid 16:40:54 I'm not so hot on them myself. 16:41:02 Hmm... 16:42:26 Ngevd, 16:42:27 http://hackage.haskell.org/package/comonad 16:44:09 -!- Gregor has changed nick to WhatsTheNickLeng. 16:44:27 -!- WhatsTheNickLeng has changed nick to Gregor. 16:44:31 Phantom___Hoover: Wow, you are actually at the limit. 16:44:41 Yes. 16:45:14 Ngevd___________ 16:45:32 Ngevd, extend (dual of bind) :: (w a -> b) -> w a -> b. 16:45:33 -!- Ngevd has changed nick to Ngevd___________. 16:45:39 I hate you all 16:45:40 Hmm 16:45:42 Erm, *w b for that last noe. 16:45:44 *one 16:46:11 Hmmmmmmmmm, the nick 'Gr' hasn't been used in two years. 16:46:17 I could PROBABLY pick it up if I asked nice. 16:46:37 The only caveat being that I don't actually want it. 16:46:41 -!- Ngevd___________ has changed nick to __N__g__e__v__d_. 16:47:04 -!- __N__g__e__v__d_ has changed nick to Ngevdtanebngevd_. 16:51:14 -!- cheater has quit (Ping timeout: 240 seconds). 17:07:00 -!- augur_ has quit (Read error: Connection reset by peer). 17:07:18 -!- augur has joined. 17:26:20 -!- Mathnerd314 has quit (Ping timeout: 252 seconds). 17:42:50 -!- Phantom___Hoover has quit (Ping timeout: 240 seconds). 17:46:24 -!- Ngevdtanebngevd_ has changed nick to Ngevd. 17:55:57 -!- Phantom_Hoover has joined. 17:56:29 -!- Klisz has joined. 17:59:02 -!- Phantom___Hoover has joined. 18:01:13 -!- Phantom_Hoover has quit (Remote host closed the connection). 18:11:07 -!- Mathnerd314 has joined. 18:18:10 -!- Ngevd has quit (Ping timeout: 276 seconds). 18:29:16 C#++'s lambda syntax is strangely similar to STG's 18:29:48 [list of free variables](list of arguments) -> { expression } 18:30:31 -!- Ngevd has joined. 18:36:10 Hello! 18:36:16 hi 18:38:01 @oeis 1, 5, 14, 30, 55 18:38:03 Square pyramidal numbers: 0^2 + 1^2 + 2^2 +...+ n^2 = n*(n+1)*(2*n+1)/6. 18:38:03 [0,1,5,14,30,55,91,140,204,285,385,506,650,819,1015,1240,1496,1785,2109,2470... 18:38:49 kallisti: "C#++"? 18:38:58 > map (sum . concat . tails . enumFromTo) [1..] 18:38:58 Couldn't match expected type `[a]' 18:38:59 against inferred type `a1 -> [a1]' 18:38:59 -!- monqy has joined. 18:39:06 > map (sum . concat . tails . enumFromTo 1) [1..] 18:39:08 [1,5,14,30,55,91,140,204,285,385,506,650,819,1015,1240,1496,1785,2109,2470,... 18:39:51 What would be fun but doable for me to write a program for? 18:40:24 ais523: C++11 :P 18:40:38 I'm even more scatterbrained than usual when I've just woken up. 18:41:00 Ngevd, of what 18:41:01 *? 18:41:15 ... 18:41:23 I'll try rephrasing my question 18:41:32 That was not a response I can parse 18:42:10 Can anyone give me an idea for a program that is fun but doable for me to write? 18:43:23 portal chess server implemenetation 18:43:43 Could you tell me the rules of portal chess? 18:43:49 I assume it is a chess variatio 18:43:50 n 18:43:51 not at the moment. 18:43:53 and yes. 18:43:57 just think of chess but awesome. 18:43:59 should be simple. 18:44:01 to figure out the rest. 18:44:02 :P 18:44:15 but seriously I do need to actually write down the rules 18:45:17 basically the objective is the same and the pieces are in the same positions 18:45:20 but they do different things 18:46:30 another difference is that the primary capturing pieces fire projectiles, that travel in one direction across the board. 18:47:43 another is that some pieces have a component of directionality. your portals for example, are the two bishops, who are facing a particular direction. During each move of a directional piece can choose to move both its direction and its position (either both or just one) 18:47:55 +you 18:48:28 oh look Wikipedia is going down in 11 hours. 18:48:48 I should probably mass-read everything I might want to know for that period of time. 18:49:22 Ngevd: but yeah enumerating all of the pieces will take some time... which I don't have at the moment 18:49:39 as soon as I finish my drink I'm going to be afk. 18:52:36 but to give you the rules for the eponymous piece: the portal has an opening that corresponds to the direction its facing. Any moving pieces or projectiles that attempt to occupy the same square as the portal from that direction will be relocated to the opening of the player's other portal, and will continue traveling as expected. 18:53:07 therefore, it's impossible to capture a portal from the direction it's facing. 18:53:43 Do they face orthagonally or diagonally? 18:53:47 either. 18:53:51 Okay 18:53:54 And projectiles? 18:56:25 projectiles are made by the two rooks. One is called the D-cannon, and is the upside-down rook on the king's side, which can, as its full move, fire a projectile in any diagonal direction. The C-cannon, the normally oriented rook on the queen's side, can fire in cardinal directions. 18:57:49 once a projectile captures a piece it stops traveling forward. 18:57:57 (or once it reaches the end of the board, obviously) 18:58:41 Is castling still possible? 18:58:52 it's not something I've considered. so no 18:58:59 really I haven't play tested it yet. :P 18:59:07 and yet I'm making the implementation. 18:59:15 I'll likely tweak rules as I go 19:00:05 one thing I have noticed 19:00:19 is that white can basically force black's first move 19:00:27 so I'm not sure how balanced it is in that regard. 19:00:34 but chess isn't balanced either. 19:00:42 Hang on 19:00:50 If a portal moves to a piece 19:01:01 ...Nevermind 19:01:05 yes that's a thing 19:01:35 it will appear next to the other portal, on the one square adjacent to the direction it's facing. 19:01:49 portals cannot capture normally. 19:04:12 the portal itself can move to any space within a chebyshev distance of 3, ignoring pieces within its path ("hopping" like a knight) 19:04:30 Which direction are the portals initially facing 19:04:37 I should probably draw a pretty little giagram like this one http://en.wikipedia.org/wiki/File:Chess_x4t45.svg 19:05:02 the opponent. assuming white is on the south side of the board, and black is on the north side. 19:05:08 as in a standard chess diagram. 19:05:37 but the starting direction isn't very important I think. 19:05:44 you'll likely move portals as one of your first moves 19:05:46 and thus reorient it. 19:05:57 oh 19:05:59 that 19:06:02 is a picture of a four 19:06:09 http://en.wikipedia.org/wiki/Chebyshev_distance 19:06:12 Yes, I was wondering about that 19:06:55 Can they move to a distance of three or less, or is it precisely 3? 19:07:16 3 or less 19:07:22 Okay 19:07:27 may adjust it to 2 dunno 19:07:31 that is quite ridiculously mobile. 19:07:47 but then, they need to be able to respond quickly to things that can capture all the way across the board without moving at all. 19:07:48 Hmm 19:08:11 the cannons themselves move slowly however. one square in any direction per turn. 19:08:22 Like Kings? 19:08:24 yes 19:08:32 kings are exactly the same in this game. 19:08:34 in every way. 19:08:45 Except for castling 19:08:48 er, yes. 19:09:05 but I might have an optional castling rule. I want to try out many rule variations 19:09:11 I might tweak individual movement and capturing rules and stuff like that. 19:10:15 chebyshev distance of 3 movement will be interesting 19:10:37 but I think it fits the game well. everything is very extreme. 19:10:55 as far as I can tell the purpose of pawns (which are currently unchanged) is to be meatshields. 19:11:12 What happens if a pawn is promoted to a portal 19:11:19 oh, hmmm. 19:11:28 well.... 19:11:33 uh..... 19:11:37 uh......... 19:12:10 I hadn't really thought about promotion. which means IT'S NOT IN THE GAME YET. 19:12:19 also how the hell are you going to get to the other side of the board. 19:12:27 Carefully placed portals 19:12:28 I guess it's pretty difficult in normal chess too... 19:12:32 oh, yes. 19:12:32 see 19:12:33 hmm 19:12:49 I don't know what effects that have. 19:12:52 *has 19:12:54 erjwejriwjiojweroijweiojtowiejr 19:13:01 currently the rule is 19:13:05 if you capture a portal 19:13:21 the other portal explodes and captures everything adjacent to it and itself. 19:13:33 which is kind of a shitty way to account for the fact that a portal doesn't really do anything if the other one is missing 19:13:36 however 19:13:39 with promotion rules you could get new portals. 19:13:41 That makes saying "check" quite interesting 19:13:46 Ngevd: oh yes. 19:13:50 ::::D 19:13:54 check is kind of ridiculous 19:13:56 in this game. 19:14:12 the same explosion rule exists if the two portals attempt to travel through each other. 19:14:16 which means 19:14:46 if two portals of the same color are within movement distance of one another, the opponents king cannot be adjacent to them 19:15:04 This is crazy! 19:15:06 lol 19:15:25 considering that a portal can more or less move across the whole board in a minimum of 3 turns, and more than likely just 2 19:15:32 this is a pretty frequent state to be in. 19:16:06 but I feel the piece promotion thing would be kind of ridiculous and weird 19:16:15 because you would just shuttle pawns to the other side in the late game. 19:16:21 which I guess makes them more valuable. 19:16:42 that could be an interesting thing... 19:17:01 Ngevd: I suspect the rules as they stand are highly broken. 19:17:08 Wow, you could get the enemy king into checkmate by putting a portal either side of it, both pointing towards it 19:17:10 I just took some elements are thought were interesting 19:17:12 and stuck them together 19:17:17 and then made rules for the consequences. 19:17:40 yes I may very well restrict the movement of portals somehow 19:17:44 perhaps no hopping like knights 19:18:03 still that doesn't change much 19:18:10 there are a shit ton of ways to get to the same square 19:18:14 when going by chevyshev distance 19:18:21 *cheby 19:19:25 Ngevd: you just made me realize another strange corner case..... 19:19:40 which makes me think 19:19:44 perhaps portals should be unable to capture 19:19:49 or rather 19:19:52 transport things by stepping on them. 19:20:12 as interesting as it would be 19:20:14 Hmm, my checkmate scenario is rather a stalemate 19:20:30 imagine you have that same scenario 19:20:31 but with 19:20:32 a pawn 19:20:34 in the middle 19:20:49 now what happens when one of the portals attempts to capture the pawn, and thus transport it 19:20:57 when two portals are adjacent to each other, facing the same direction 19:21:11 it... kind of just disappears 19:21:19 in an infinite loop of rulez 19:21:43 PROBLEM SOLVED 19:21:47 this is how portals capture. :> 19:21:56 THIS VERY UNLIKELY SITUATION 19:21:59 IS HOW YOU CAPTURE THINGS WITH PORTALS. 19:22:02 done. 19:22:03 problem solved. 19:22:52 Perhaps the pawn remains in the portal loop until it can exit the portal safely, at which point you flip a coin and it gets fired out of one of the portals at high speed? 19:23:05 lol 19:23:12 I'm trying to remove any element of chance as much as I can 19:23:19 though there is an existing rule variant that allows chance. 19:23:24 but I don't really like it. 19:24:00 it involves PROJECTILE LOOPS 19:24:06 THAT ARE /BIDIRECTIONAL/ 19:24:07 yes 19:24:14 I've just dropped some Official Portal Chess Terminology. 19:25:23 Possibly the player who controls the portals the piece is trapped in chooses which way the piece gets fired? 19:25:31 yes that's interesting 19:25:33 I may in fact 19:25:35 make this another case 19:25:38 where a number of rule variations can exist. 19:25:53 the other case is the bidirectional projectile loop thing, which I haven't really explained very well 19:26:04 man... this ruleset is going to need several helpful diagrams. 19:26:08 And if one of the portals is destroyed, the piece is obviously destroyed 19:26:57 hm, yes you could go by: 19:27:25 a) chance b) portalling player's choice c) capturing portal ejects always d) moving portal ejects always 19:28:03 e) actually there's about 3 more I can think 19:28:05 of 19:28:07 TOO MANY 19:28:08 RULE 19:28:09 VARIATIONS 19:28:44 the rule variations are basically me not deciding what can happen here, and just picking one I like the best as the "standard" but allowing the other possibilities 19:29:04 I'm afraid by the end there will be so many strange rules that no one will want to play. :P 19:29:05 You could do one by how many turns have taken place? 19:29:15 oh yes that's one 19:29:18 the oscillating rule 19:29:22 like the projectile loop one 19:29:23 that works like that. 19:29:32 that is one of the "3 more I can think of" 19:29:39 The oscillating rule family- you can do many timings 19:29:45 lol, yes. 19:29:50 RULE FAMILIES 19:29:58 "chance" "oscillation" "meh fuck it" 19:30:06 the three rule families 19:30:15 And choice 19:30:30 for those who like gambling, those who like strategic timing, and those who really don't give a fuck. 19:30:37 well the choice one is a bit difficult to work out 19:31:14 in projectile loops the choice for the looping player is, obviously, to capture an opponent's piece, but to allow friendly pieces to interact with the projectile in a way that prevents them from being captured 19:31:33 note that this is only bidirectional loops 19:32:02 for a projectile loop that travels in only one direction there is no ambiguity that needs to be settle by explicit rules. 19:32:40 > let PortalChess == Weird in PortalChess == Weird 19:32:41 : parse error on input `in' 19:32:52 > let "Portal Chess" == "Weird" in PortalChess == Weird 19:32:53 : parse error on input `in' 19:33:01 > let "Portal Chess" == "Weird" = True in PortalChess == Weird 19:33:02 Not in scope: data constructor `PortalChess'Not in scope: data constructor ... 19:33:12 > let "Portal Chess" == "Weird" = True in "PortalChess" == "Weird" 19:33:13 *Exception: :3:4-35: Non-exhaustive patterns in function == 19:33:17 > let "Portal Chess" == "Weird" = True in "Portal Chess" == "Weird" 19:33:18 True 19:33:18 yo dawg I heard you like pattern matching 19:33:23 ... 19:34:08 My Portal Chess program has 15 lines of code, not one of which contains pattern matching 19:34:09 http://sprunge.us/WdIC 19:34:13 It doesn't do much, though 19:34:18 Ngevd: hm? 19:34:29 you've been writing portal chess code? 19:34:34 Yes 19:34:38 While you've been talking 19:34:40 oh 19:34:41 well 19:34:44 you should work on mine instead. :P 19:34:50 -!- jix_ has changed nick to jix. 19:35:29 I'm doing mine a little different 19:35:39 Yours is probably better 19:35:46 Ngevd: I like yours better 19:35:47 > let { infixr 3 <=>; "foo" <=> "bar" = "bar" <=> "foo" } in "foo" <=> "bar" 19:35:47 *Exception: :3:20-52: Non-exhaustive patterns in function <=> 19:35:53 uhm. yeah. 19:36:29 lifthrasiir: write a programming language where this works: 19:36:54 > let { infixr 3 <=>; "foo" <=> "bar" = "bar" <=> "foo"; a <=> b = b <=> a } in "foo" <=> "bar" 19:36:58 mueval-core: Time limit exceeded 19:37:24 Uh, what were you expecting that to do? 19:37:35 > let { infixr 3 <=>; "foo" <=> "bar" = True; a <=> b = b <=> a } in "bar" <=> "foo" 19:37:36 True 19:37:36 Print an error saying <>? 19:37:38 Oh 19:37:49 Wait, why am I saying oh? 19:38:00 abuse of local fixity declaration? 19:38:23 Ngevd: what are you doing differently? :P 19:38:45 I'm doing the board is an Array (Int, Char) Piece 19:38:50 oh 19:38:56 Rather than a list of pieces with coords? 19:39:04 I'm using a Vector. 19:39:23 and I have a Storable instance that converts board squares to 16-bit unsigned integers. 19:41:20 This took me a while: 19:41:23 freshBoard = array ((1,'a')(8,'h')) [((1,'a'), CCannon White),((1,'b'), Knight White),((1,'c'), Portal White North),((1,'d'), King White),((1,'e'), Queen White),((1,'f'), Portal White North),((1,'g'), ((1,'h'), DCannon White) 19:41:23 ,((2,'a'), Pawn White True),((2,'b'), Pawn White True),((2,'c'), Pawn White True),((2,'d'),Pawn White True),((2,'e'),Pawn White True),((2,'f'),Pawn White True),((2,'g'),Pawn White True),((2,'h'),Pawn White True) 19:41:23 ,((3,'a'), Empty),((3,'b'), Empty),((3,'c'), Empty),((3,'d'), Empty),((3,'e'), Empty),((3,'f'), Empty),((3,'g'), Empty),((3,'h'),Empty) 19:41:24 ,((4,'a'), Empty),((3,'b'), Empty),((4,'c'), Empty),((4,'d'), Empty),((4,'e'), Empty),((4,'f'), Empty),((4,'g'), Empty),((4,'h'),Empty) 19:41:26 lol 19:41:29 ,((5,'a'), Empty),((5,'b'), Empty),((5,'c'), Empty),((5,'d'), Empty),((5,'e'), Empty),((5,'f'), Empty),((5,'g'), Empty),((5,'h'),Empty) 19:41:31 ,((6,'a'), Empty),((6,'b'), Empty),((6,'c'), Empty),((6,'d'), Empty),((6,'e'), Empty),((6,'f'), Empty),((6,'g'), Empty),((6,'h'),Empty) 19:41:34 ,((7,'a'), Pawn Black True),((7,'b'), Pawn Black True),((7,'c'), Pawn Black True),((7,'d'),Pawn Black True),((7,'e'),Pawn Black True),((7,'f'),Pawn Black True),((7,'g'),Pawn Black True),((7,'h'),Pawn Black True) 19:41:41 I wrote mine a bit less... tediously. 19:41:43 ,((8,'a'), DCannon Black),((8,'b'), Knight Black),((8,'c'), Portal Black South),((8,'d'), Queen Black),((8,'e'), King Black),((8,'f'), Portal Black South),((8,'g'), ((8,'h'), CCannon Black) 19:41:46 ] 19:41:50 Almost certainly 19:42:10 Sgeo: I was expecting it to change the universe in very subtle ways :p 19:42:22 http://sprunge.us/DfHI 19:42:30 storable instance and some basic functions 19:46:57 hmmm if I took loops out of the board representation I could knock it down to a Word8 representation. 19:47:01 my desktop: http://min.us/mvFG2GySl#1o 19:47:24 since loops are expected to be not very common anyway. 19:47:34 I dunno I'll see how the algorithms work. 19:47:42 and change accordingly 19:47:47 Mathnerd314, you can delete the install file for Skype 19:49:30 -!- Phantom___Hoover has quit (Ping timeout: 240 seconds). 19:50:04 yeah... 19:50:06 Ngevd: so are you ready to implement the most exciting chess variant ever created? :P 19:50:20 Probably not! 19:50:25 But I'll give it a go 19:51:17 -!- Vorpal has quit (Ping timeout: 248 seconds). 19:52:59 -!- Phantom___Hoover has joined. 19:53:30 Ngevd: I think I did a pretty good job structure the "new board" code. 19:53:39 but maybe there's a way to make it better. 19:58:17 kmc: hmm, so as a general, when micro-optimizing, is it better to have many function arguments or many free variables? 19:58:35 when I was optimizing a (rather dumb) factoring algorithm I noticed that arguments seemed to be faster. 20:01:43 based on the way the STG presents its memory model I think function arguments would have slightly faster access times, which could be important for arguments that are accessed rapidly in a tight loop. 20:02:08 but it's likely a minor difference. 20:03:20 Hmm 20:03:37 Would it be possible to do the board as Coord -> Maybe Piece? 20:07:07 I think it would still have to look something up within an array or other structure 20:07:21 hm, well maybe not 20:07:33 -!- Labbekak has joined. 20:08:15 Ngevd: yes that would be possible but probably not very efficient. 20:08:57 each modification of the board would add an additional branch point that has to be executed in order to access anything on the board. 20:09:18 as you continue to layer either guards pattern matches 20:09:40 +or 20:11:35 essentially my at function produces a Coord -> Maybe Piece sort of function 20:11:43 at :: Board -> (File, Rank) -> Square 20:11:47 given the board it produces such a function 20:11:57 where data Square = Square (Maybe Piece) (Maybe Loop) 20:12:43 -!- MDude has quit (Ping timeout: 244 seconds). 20:26:53 kallisti, what are Arrows and Prisms? 20:32:40 Arrows are just members of homsets. 20:33:01 In the context of Portal Chess 20:34:03 Ngevd: arrows are the pieces symbolized by the knight. They have a direction. they're immune to normal projectiles and will redirect the path of a projectile that comes into contact with them, regardless of which player initiated the projectile. 20:34:36 they move like bishops but are unable to capture like bishops, and may also move one space and capture one space in any cardinal direction 20:34:51 (I think. maybe. we'll see) 20:34:52 And how do projectiles work? 20:35:06 well I kind of already explained most of it... 20:35:15 they just travel in the direction they're fired. 20:35:21 Are they coloured? 20:35:24 hm 20:35:28 well, no. 20:35:38 they can capture any piece. 20:35:52 this makes arrows rather valuable defensively. 20:36:09 to block and redirect projectile paths, thus preventing cannons from firing 20:36:25 and also offensively 20:36:42 as an extension to the slow-moving cannons offensive capability. 20:36:47 And how quickly do projectiles move 20:36:52 erm, instantly. 20:37:15 they go away when they've either captured a piece or touch the edge of the board. 20:37:15 If they're slower, you can do taking the bullet? 20:37:27 I have no idea what that mean-- oh yes you could do that. 20:37:32 if they were slower 20:37:38 it would also make them kind of pointless I think 20:37:52 Hmm, yeah 20:37:59 the fact that you can capture things from across the board without moving is kind of what makes portal chess interesting. :P 20:38:21 Can cannons fire through portals? 20:38:23 yes. 20:38:27 they can also capture portals. 20:38:33 based on the rules of how capturing portals works. 20:38:53 cannons cannot capture arrows 20:38:57 however, with the help of a prism, they can. 20:39:17 is anyone actually going to /play/ this 20:39:25 who knows. 20:39:28 also, what if an arrow gets into an infinite loop through portals 20:39:29 Probably just me and kallisti 20:39:36 ais523: yes this is a thing. 20:39:45 I have rules for it. they're slightly complicated. :P 20:40:06 but the basic idea is that it produces a loop, which is a persistent element of the board. 20:40:24 it's just a consequence of the "projectiles disappear when they leave the edge of the board or capture a piece" a rule. 20:40:37 How can a projectile get stuck in a portal? 20:40:48 well, it doesn't get stuck /in/ the portal 20:40:52 it gets stuck in an infinite loop 20:40:55 How? 20:40:56 either by arrows or portals. 20:41:02 so the simplest one is 20:41:04 two arrows facing each other 20:41:13 a cannon fires and the projectile touches one of the arrows 20:41:23 Oooh 20:41:24 I see 20:41:30 then any piece that ever moves through that zone dies? 20:41:34 this is a bidirectional loop. it's not entirely clear which direction the projectile is going. intuitively it goes back and forth between the two arrows. 20:41:39 quintopia: yes, and the projectile goes away. 20:41:48 also 20:42:24 if one of the components of the loop breaks the loop, the projectile will either a) fly off the board b) capture something c) get stuck in a different loop 20:42:25 I was imagining it bouncing off the arrow rather than turning 20:42:35 Ngevd: it just goes in whatever direction the arrow is pointing 20:42:39 Yeah 20:42:55 meh, i think projectiles should move at a finite speed. say eight squares a turn. then the prjectile can cover that area without preventing motion through it 20:43:33 that's difficult to represent on a chess board. admittedly so are several other things (loops, and a specific variation of the loop rules where bidirectional loops oscillate each round of turns) 20:43:34 and bullet dodging is possible 20:43:38 which could be fun 20:43:47 quintopia: eh. 20:43:55 its easy to represent...bullets become pieces 20:44:14 yes that's possible, but the idea was to require only a chess board and a little bit of imagination (in regard to keeping track of loops) 20:44:26 however, I guess a coin or something could be used 20:44:28 something easy to find. 20:44:32 A loop can be: Data Loop = Directedloop [Coord] | Bidirectedloop [Coord]? 20:44:34 already requires too much imagination 20:44:44 Ngevd: I just use a direction 20:44:52 Ngevd: data Loop = Loop LoopKind Direction 20:45:02 data LoopKind = Unidirectional | Bidirectional 20:45:06 but I like your names better 20:45:16 You could use strings if you want to play for real 20:46:13 I don't see how your kind of loop actually represent loops 20:46:25 Unless it's on the board? 20:46:32 Ah yes 20:48:20 kallisti: if you want to make this even more complicated, you could have both cannons and laser cannons. the laser cannons are instantaneous, but arrows act as mirrors for them rather than "go this way" 20:48:37 let the arrow point in the directionof the normal vector to the mirror plane 20:49:10 quintopia: nah my pieces are already pretty filled. 20:49:21 ah well 20:49:58 i was just thinking how amusing itd be if you could reflect a shot straight back at its source. "i will die if i fire right now" 20:50:02 the rules are probably broken anyway 20:50:09 quintopia: yes that's possible. 20:50:10 but i guess its still possible with arrows 20:50:13 so 20:50:16 whaev 20:50:29 one of the possible opening moves involves such a scenario in fact. 20:50:35 which is what I was saying earlier 20:50:41 that white can easily force blacks first move 20:50:52 because white's first move can put black's pieces in danger 20:51:01 that sounds annoying 20:51:03 yes 20:51:07 these are things that need to be fixed. 20:51:19 or not fixed, but improved. 20:51:39 perhaps by giving cannons a finite range. 20:51:48 but this leads to other problems. 20:52:05 Has elliott given up on IRC? 20:52:18 He may be blocked 20:52:23 Banned 20:52:38 Of course, now I've said that, he's going to join and say "No I'm not!" 20:52:46 Oh, huh, he's online. 20:52:52 Or, more likely, "Yes I am" 20:53:12 shachaf, which channels? 20:53:18 No idea. 20:53:54 rearranging the starting positions of pieces could possibly improve the game. 20:55:43 or hmmm 20:56:32 I think the situation could be amended by giving black an extra turn at the beginning of the game. 20:57:31 Just seen an ad for "Megashark vs Crocasaurus" 20:58:43 http://gameknot.com/img/cd/Hs4OjMqrdSD_Tek0dz6AGg.gif 20:58:44 okay so 20:59:11 the best opening move for white is to move g2 to g3 20:59:17 because next turn he would be guaranteed a free capture 20:59:25 -!- Phantom___Hoover has quit (Quit: Leaving). 20:59:48 however, if black is given two moves after white's first move 20:59:56 this negates that opening for white. 21:00:25 however, it's likely just an indication that the game is fundamentally flawed in some way and needs to be revised. :P 21:00:48 Love it for its flaws 21:01:31 but no that doesn't fix anything. :P 21:02:12 it just gives black that opportunity 21:02:14 to take a free piece 21:02:25 aha, I know. 21:02:29 That's what they said to Raul Gomila! 21:02:38 you can give arrows an additional rule 21:02:50 they may push friendly pieces with them, in the direction they're facing. 21:03:20 this gives black the potential to defend white's opening by simply pushing his pawn out of the way and putting his arrow in position to block the projectile. 21:03:50 and also means that if black does the same sort of manuever 21:03:55 white can reply the same way. 21:04:03 and now the beginning of the game is somewhat sane. 21:04:12 can't say that about the rest of the game. :P 21:05:13 kallisti, Ngevd update 21:05:28 Ngevd: could you make sense of my solution? 21:05:41 or even the initial problem? 21:08:03 so in fact a potential opening scenario is this. 21:09:16 white moves g1 to g2, thereby pushing g2 to g3. black can respond by mirroring the move on his side. 21:10:15 and... immediately there's a stripe of "do not enter" going across the main diagonal of the board. :P 21:10:19 Sgeo, ooh 21:11:41 I still think Roxy is an esoteric programmer 21:12:51 this game is so wonky. :P 21:13:20 Is ~ATH an esolang? 21:13:22 I think just having the first move gives you a ridicuous edge over your opponent 21:13:24 Is ^CAKE? 21:13:38 They are fictional languages 21:13:55 ~ATH could make a good esolang 21:13:55 We should unfictionalize them 21:14:05 We haven't seen enough of ^CAKE or DIS* 21:14:16 I forgot about DIS* 21:14:38 for example in the diagonal stripe of death scenario, with the new rules I just creating, white can move b1 to the center of the board, pushing the pawn along with him, and cut the diagonal stripe in half and thereby gain control of it 21:14:44 black can then respond by doing the exact same thing 21:14:55 so I think.... in this scenario, stalemate is very possible 21:15:04 if black just mirrors white. 21:25:05 well, maybe not 21:25:12 there's no way to know except by playing a bunch of games. :P 21:26:59 -!- Labbekak has quit (Quit: Page closed). 21:27:30 does GHC do something more efficient than branch a lot when it encountered a case statement? 21:27:42 eh, premature optimization 21:28:03 basically I've got backward :: Direction -> Direction 21:28:20 and I was wondering if an explicit case statement would be slower or faster than using (to|from)Enum tricks. 21:29:03 Couldn't you do pattern matching? I don't know how that compiles, though 21:29:10 as a case statement 21:29:21 case statements are the pattern matching primitive in Haskell 21:29:32 all the other pattern matching syntax translates to cases. 21:30:16 I'll use Enum tricks for now because it's less tedious 21:32:22 backward d = toEnum . condApp even succ pred . fromEnum $ d 21:32:22 where 21:32:23 condApp p t f x = if p x then t x else f x 21:32:31 condApp seems like it should be something that already exists 21:34:00 @hoogle (a -> Bool) -> (a -> b) -> (a -> b) -> a ->b 21:34:00 No results found 21:34:22 really there's no need for special syntax for if 21:34:28 I think an if function would look better. 21:35:00 -!- Ngevd has quit (Quit: goodnight). 21:38:22 -!- Phantom_Hoover has joined. 21:46:14 presumably GHC has some kind of special case for enumeration types to make them faster. 21:46:59 -!- Patashu has joined. 21:50:38 * kallisti is experimenting with the hundreds of ways to write the same thing. :P 21:52:26 backward :: Direction -> Direction 21:52:26 backward d = let i = fromEnum d 21:52:26 in toEnum $ if even i 21:52:26 then i+1 21:52:27 else i-1 21:52:36 I think I prefer this one over the equivalent where/guard version 21:56:25 I think where is better when longer descriptive names are used 21:57:02 if you've got a long where clause that assigns a bunch of single-letter variable names then you benefit very much from the top-to-bottom presentation 21:57:09 *don't benefit 21:59:18 newBoard = imapBoard fillBoard emptyBoard 21:59:21 where 21:59:23 ... 21:59:39 compare with this: you have long descriptive names, which gives you an idea of the structure of the function beforehand 22:00:24 this is a trivial case that would be readable regardless of format, but when single-letter variables are referred to multiple times you basically are better off skipping to where clause and reading it first. 22:01:33 -!- azaq23 has joined. 22:01:49 -!- azaq23 has quit (Client Quit). 22:07:37 -!- MDude has joined. 22:07:53 -!- Jafet has quit (Quit: Leaving.). 22:25:38 -!- Jafet has joined. 22:28:32 -!- CHeReP has joined. 22:45:07 -!- Mathnerd314_ has joined. 22:49:13 -!- Mathnerd314 has quit (Ping timeout: 276 seconds). 22:50:50 -!- Phantom_Hoover has quit (Ping timeout: 240 seconds). 22:51:30 -!- Mathnerd314_ has quit (Ping timeout: 240 seconds). 22:56:08 kallisti, Nisstyre update 23:03:06 Sgeo: hi 23:03:20 Hi, that was a misupdate 23:03:26 ok 23:03:45 kallisti: I dislike if...else in Haskell 23:03:50 feels all wrong 23:04:49 Nisstyre: eh 23:04:55 I'd prefer an if function, yes. 23:05:42 kallisti: I just use guards or case expressions 23:05:53 or pattern matching when it applies 23:12:03 Nisstyre: I use guards sometimes. 23:12:22 but in this case I thought the usage was clearer than the equivalent guard/where notation 23:52:24 -!- pikhq has joined. 23:54:51 -!- pikhq_ has quit (Ping timeout: 245 seconds). 23:56:45 -!- ais523 has quit (Remote host closed the connection).