00:18 (join) Toyes 00:22 (part) DanBurton 00:41 (part) Toyes 00:51 (join) Reox 00:52 Reox: Afternoon. Is anyone available here? 00:52 mithos28: Reox: yep 00:52 Reox: I would like to seek some help regarding scheme and depth first search. 00:52 mithos28: but not its not afternoon where I am 00:52 mithos28: sure 00:52 Reox: haha 00:53 Reox: Hmm just wondering is there any sample on the web where i can learn DFS? 00:53 Reox: It's part of a homework where I need to calculate the 3 shortest distance from 1 node to another node in a graph 00:54 (join) samth 00:55 mithos28: I'm not very knowledgable about where you would find anything like that 00:56 mithos28: my normal answer for most people looking for intro material is HTDP but it doesn't cover search 00:56 Reox: hmm then would it be possible to seek advice from you on how can I go about implementing this? 00:56 mithos28: sure 00:57 mithos28: are you following the design recipe? 00:57 Reox: hmm, may I know what's that? 00:58 Reox: I am quite new to scheme 00:59 mithos28: never mind, it is a phrase used to describe the methodology for approaching a problem. It is used in the racket books/ courses taught from them 00:59 mithos28: What is your problem description 01:01 (quit) realitygrill: Quit: realitygrill 01:02 Reox: I am suppose to come out with a Train journey planner to suggest travel routes for a given pair of boarding and alighting stations. 01:02 Reox: the train journey planner is to provide 3 shortest distance possible and list the stations out 01:02 Reox: in the sequence of traveling 01:03 mithos28: ok so what format is your input in and what format are you returning your output as 01:05 Reox: My inputs are basically strings eg. boarding station: Beverly rd Alighting station: Kingston Av 01:06 Reox: n then my output suppose to list the stations Beverly Rd -> Church Av -> .... ..... -> Kingston Av 01:08 mithos28: how many inputs will your function have, the number of stations? how are you representing distances between the stations? 01:09 Reox: 2 inputs, boarding and alighting station names. Distance is represented as the number of stations traveled to get to the end point. 01:11 mithos28: how do you know how many stations are between the two boarding and alighting stations, since that doesn't seem to be part of the input. 01:11 (quit) dnolen: Quit: dnolen 01:13 Reox: Ohh, for me, i did a hardcode of the stations available in a subway system using vectors 01:13 Reox: so i would already have defined them in the code 01:13 Reox: I would like to use DFS to go thru the vectors and find 3 possible shortest distance 01:14 mithos28: what data is stored in the vectors? 01:16 (quit) samth: Ping timeout: 240 seconds 01:16 Reox: (vector "current_station" (list "Previous_station" "Next_station)) 01:17 mithos28: ok and you have many of these vectors? 01:17 mithos28: how are all of them stored? 01:18 Reox: as many as the number of stations are available on the subway 01:18 Reox: they are stored in overall in another vector 01:19 mithos28: ok. So what is your first approach? 01:19 Reox: (define listofstations ((vector (vector "C" (list "B" "D")) (vector "D" (list "C" "E)) ) 01:19 Reox: hmm 01:19 Reox: prompt user to enter his boarding station name 01:19 Reox: n his alighting station name 01:30 mithos28: and then? 01:33 Reox: that's where i would like the DFS to go thru the vectors and find the 3 shortest path available 01:33 mithos28: ok so how do you start your DFS? 01:33 Reox: that.... i have no idea. 01:33 Reox: that's why i am hoping to find some help regarding that. 01:34 mithos28: so in words how does DFS work? 01:35 Reox: starting from the root, it will traverse to the first child node 01:40 Reox: n will go deeper until the goal node is found or till no more child node 01:40 mithos28: what happens when it reaches the first child node? 01:40 mithos28: ok so why are you stuck implementing that? 01:42 Reox: I can do it well in java.. but i still have not grasp scheme's coding well enough to understand n implement it 01:42 mithos28: what are you missing from java that is missing in racket? 01:43 Reox: o.o you mean it's possible to derive dfs from a java sample? 01:44 Reox: i didnt realise that >< haha 01:44 mithos28: idiomatic racket will be different, but you can write java like code in racket. 01:45 mithos28: Once you have it implemented you can then try to make it more racket like in small steps 01:45 Reox: oh ok 01:47 Reox: I will try and see how it gpes =) 01:49 Reox: Thanks for the enlightenment 01:49 mithos28: no problem 02:16 (quit) Reox: Quit: Page closed 02:22 (quit) jonrafkind: Ping timeout: 260 seconds 02:53 (join) nosilverbullet 03:15 (quit) nosilverbullet: Ping timeout: 265 seconds 03:27 (quit) rgrinberg: Ping timeout: 260 seconds 03:54 (join) noelw 04:03 (quit) mithos28: Quit: mithos28 04:04 (join) mithos28 04:07 (quit) mithos28: Client Quit 04:11 dingfeng: greetings 04:20 noelw: hi 04:25 (part) noelw 04:25 (join) noelw 05:14 (join) bluezenix 05:32 dingfeng: what's ''0? 05:32 dingfeng: (number? 0) > #t 05:32 dingfeng: (number? '0) > #t 05:32 dingfeng: (number? ''0) > #f 05:33 dingfeng: (symbol? ''0) > #f 05:41 rapacity: '(quote 0) 05:42 rapacity: rudybot: (list? ''0) 05:42 rudybot: rapacity: your sandbox is ready 05:42 rudybot: rapacity: ; Value: #t 05:58 dingfeng: =) 06:13 (quit) dingfeng: Ping timeout: 265 seconds 06:34 (join) sstrickl 06:40 (join) MayDaniel 07:10 (quit) Demosthenes: Ping timeout: 248 seconds 07:11 (join) Demosthenes 07:21 (join) jeapostrophe 07:33 (quit) noelw: Quit: noelw 07:39 (quit) Shviller: Quit: bye 07:47 (join) masm 07:54 (join) samth 08:00 (quit) hyko: Ping timeout: 240 seconds 08:25 (join) shadgregory 08:27 (quit) shadgreg1ry: Ping timeout: 245 seconds 08:39 (join) mceier 08:46 (quit) samth: Ping timeout: 258 seconds 08:52 RacketCommitBot: [racket] plt pushed 3 new commits to master: http://git.io/mrip6Q 08:52 RacketCommitBot: [racket/master] fix contract - Matthew Flatt 08:52 RacketCommitBot: [racket/master] another attempt to fix the build script - Matthew Flatt 08:52 RacketCommitBot: [racket/master] better comment to explain a subtle corner of the expander - Matthew Flatt 09:00 (quit) ohwow: Ping timeout: 258 seconds 09:02 (join) ohwow 09:12 (quit) MayDaniel: Read error: Connection reset by peer 09:35 (quit) jeapostrophe: Ping timeout: 252 seconds 09:47 (join) hyko 09:49 (join) Blkt 09:49 (join) MayDaniel 09:54 (join) MayDaniel_ 09:55 (quit) MayDaniel: Ping timeout: 276 seconds 10:08 (join) jeapostrophe 10:10 (quit) jeapostrophe: Client Quit 10:16 (join) oiiii 10:31 (join) noelw 10:34 (join) jeapostrophe 10:52 (quit) jeapostrophe: Quit: jeapostrophe 11:03 (join) anRch 11:07 (join) realitygrill 11:44 (quit) bluezenix: Read error: Connection reset by peer 11:46 (join) noelw_ 11:48 (quit) noelw: Ping timeout: 276 seconds 11:48 (nick) noelw_ -> noelw 11:57 (quit) anRch: Ping timeout: 248 seconds 12:01 (join) jeapostrophe 12:07 (join) anRch 12:17 (quit) noelw: Quit: noelw 12:19 (nick) samth_away -> samth 12:21 (quit) Blkt: Remote host closed the connection 12:30 (quit) gmcabrita: Max SendQ exceeded 12:31 (join) gmcabrita 12:33 (quit) anRch: Quit: anRch 12:33 (quit) oiiii: Remote host closed the connection 12:50 (join) bluezenix 12:52 (quit) samth: Remote host closed the connection 12:54 (join) samth 13:05 em: is there a way for racket to 'read in' the data from a .tiff ? So that a racket program could analyze an image file? 13:14 (quit) ohwow: Ping timeout: 259 seconds 13:15 (join) jonrafkind 13:16 (quit) MayDaniel_: Read error: Connection reset by peer 13:24 samth: em: i don't think there's a TIFF reader in racket 13:24 samth: but you could use the FFI to link to a C implementation 13:24 (quit) realitygrill: Quit: realitygrill 13:41 (join) mithos28 13:48 em: samth: okay yeah, i'll try to figure that out. 13:49 em: I assume that an image file is in general like a big array of n-tupples with different numbers for things like color, brightness, and whatever for each pixle? 13:50 bremner: em: there is also compression, which complicates things in general (maybe not for tiff) 13:55 em: bremner: i guess you have to first uncompress it then. 13:55 em: tiff readers must do that somehow. 13:55 bremner: em: sure, my point is the on-disk format is not simply an array 13:56 em: oka 13:59 samth: em: the imagemagick ffi example might be useful: https://github.com/plt/racket/blob/master/collects/ffi/examples/magick.rkt 14:00 (join) anRch 14:01 (quit) offby1: Remote host closed the connection 14:01 (join) offby1 14:02 (quit) offby1: Changing host 14:02 (join) offby1 14:21 em: samth: is there any image format that is particularly raw or easy for racket/scheme to work with? maybe i can just convert tiff to that, if there is such a thing. 14:23 mithos28: em: for a really simple image format you can use pnm, but that may be too simple. 14:31 (join) DanBurton 14:38 em: mithos28: when people do stuff like facial recognition that must involve taking an image file and parsing the data of it somehow. 14:40 samth: em: racket supports a bunch of bitmap image formats already; see http://pre.racket-lang.org/docs/html/draw/bitmap_.html?q=load-file#%28meth._%28%28%28lib._racket/draw..rkt%29._bitmap~25%29._load-file%29%29 14:40 rudybot: http://tinyurl.com/64gzqg9 14:41 mithos28: rudybot: doc get-argb-pixels 14:41 rudybot: mithos28: your sandbox is ready 14:41 rudybot: mithos28: not found in any library's documentation: get-argb-pixels 14:42 samth: http://pre.racket-lang.org/docs/html/draw/bitmap_.html?q=get-argb#%28meth._%28%28%28lib._racket/draw..rkt%29._bitmap~25%29._get-argb-pixels%29%29 14:42 rudybot: http://tinyurl.com/3tht3ex 14:49 (join) dnolen 14:52 RacketCommitBot: [racket] plt pushed 2 new commits to master: http://git.io/llT4Sw 14:52 RacketCommitBot: [racket/master] clean up the docs for the Planet Cute images - Robby Findler 14:52 RacketCommitBot: [racket/master] adjust the planet cute images so they cooperate with executable creation better - Robby Findler 14:56 (join) jrslepak_ 14:59 (quit) anRch: Quit: anRch 15:02 (join) realitygrill 15:12 (quit) bluezenix: Quit: Leaving. 15:15 RacketCommitBot: [racket] plt pushed 1 new commit to master: http://git.io/taoMKA 15:15 RacketCommitBot: [racket/master] Avoid spaces and caps in file names. - Eli Barzilay 15:30 (join) bluezenix 15:34 samth: tonyg: you around today? 15:40 (quit) realitygrill: Quit: realitygrill 15:40 (quit) jeapostrophe: Quit: jeapostrophe 15:44 (join) realitygrill 16:03 (join) MayDaniel 16:13 tonyg: samth: hi 16:13 tonyg: samth: I'm at home but, er, telepresent 16:27 (quit) bluezenix: Quit: Leaving. 16:29 (join) bluezenix 16:43 RacketCommitBot: [racket] plt pushed 1 new commit to master: http://git.io/os2jnw 16:43 RacketCommitBot: [racket/master] Fix curried function type parsing without (). - Sam Tobin-Hochstadt 17:04 (quit) realitygrill: Ping timeout: 248 seconds 17:07 (join) realitygrill 17:24 (quit) mceier: Quit: leaving 17:32 (quit) masm: Quit: Leaving. 17:38 (quit) DanBurton: Quit: Leaving 17:43 (quit) realitygrill: Ping timeout: 252 seconds 17:54 (quit) dnolen: Quit: Page closed 18:04 (quit) jonrafkind: Ping timeout: 260 seconds 18:07 (quit) sstrickl: Quit: sstrickl 18:08 (join) jeapostrophe 18:17 (quit) shadgregory: Quit: leaving 18:19 (join) realitygrill 18:27 (quit) jeapostrophe: Quit: jeapostrophe 18:46 (join) dnolen 18:52 (join) jeapostrophe 18:57 (join) samth_ 19:00 (quit) bluezenix: Quit: Leaving. 19:49 (quit) MayDaniel: Read error: Connection reset by peer 20:25 (nick) samth -> samth_away 20:27 (quit) samth_: Ping timeout: 256 seconds 21:01 (quit) dnolen: Quit: dnolen 21:21 (quit) jeapostrophe: Quit: jeapostrophe 22:01 RacketCommitBot: [racket] plt pushed 1 new commit to master: http://git.io/_hiTvg 22:01 RacketCommitBot: [racket/master] fix editor refresh problem when line numbers are shown - Matthew Flatt 22:08 (quit) mithos28: Quit: mithos28 22:15 (join) jeapostrophe 22:21 (quit) jeapostrophe: Quit: jeapostrophe 22:49 (join) jonrafkind