Logs: freenode/#haskell
| 2021-03-17 01:07:12 | <fen> | polynomial [(1.1,[1,2]),(2.2,[3,4])] [5,6] = let x =1.1 * 5**1 * 6**2 in x + polynomial [(2.2,[3,4])] [5,6,x] |
| 2021-03-17 01:07:30 | <fen> | but that messes up the arguments... |
| 2021-03-17 01:07:46 | × | mceier quits (~mceier@89-68-132-187.dynamic.chello.pl) (Ping timeout: 276 seconds) |
| 2021-03-17 01:07:54 | <fen> | they have to grow from the length of the input argument |
| 2021-03-17 01:08:14 | <fen> | polynomial [(1.1,[1,2]),(2.2,[3,4,4.5])] [5,6] = let x =1.1 * 5**1 * 6**2 in x + polynomial [(2.2,[3,4,4.5])] [5,6,x] |
| 2021-03-17 01:08:30 | × | Morrow_ quits (~MorrowM_@147.161.13.246) (Read error: Connection reset by peer) |
| 2021-03-17 01:08:30 | × | MorrowM quits (~MorrowM_@147.161.13.246) (Read error: Connection reset by peer) |
| 2021-03-17 01:09:00 | <fen> | so i thought it would be easier to just buffer at the length of the inputs |
| 2021-03-17 01:09:17 | <fen> | polynomial [(1.1,[1,2]),(2.2,[4,4.5])] [5,6] = let x =1.1 * 5**1 * 6**2 in x + polynomial [(2.2,[4,4.5])] [6,x] |
| 2021-03-17 01:10:00 | → | frozenErebus joins (~frozenEre@37.231.243.22) |
| 2021-03-17 01:10:28 | <spidr> | all of them lol |
| 2021-03-17 01:10:30 | <fen> | to give a thick enough data pipe to transfer information through the stages to the output |
| 2021-03-17 01:10:36 | × | forgottenone quits (~forgotten@176.42.16.24) (Quit: Konversation terminated!) |
| 2021-03-17 01:10:53 | <Gurkenglas> | fen, why restrict the thickness of the pipe? |
| 2021-03-17 01:11:04 | <fen> | to get a regular length for the parameters |
| 2021-03-17 01:11:24 | <Gurkenglas> | Why do you want a regular length for the parameters? |
| 2021-03-17 01:11:36 | <fen> | well at least to know how many of them there are! |
| 2021-03-17 01:12:11 | <Gurkenglas> | you can carry the length around in the type and still increase it by one at each level. |
| 2021-03-17 01:12:26 | <fen> | also, fewer is better, since then it represents something more like a layered net, instead of as it is fully connected to all previous as a kind of diagonal net |
| 2021-03-17 01:12:27 | <Axman6> | spidr: a more helpful answer; I've used Haskell at... 6 different companies now, for everything from financial trading, web services, geospatial data munging, and now again for financial stuff, (though that's technically DAML, not Haskell) |
| 2021-03-17 01:12:36 | <Axman6> | uh, solidus-river, sorry spidr |
| 2021-03-17 01:13:05 | <spidr> | what about simple glue stuff |
| 2021-03-17 01:13:09 | <spidr> | talking to an API |
| 2021-03-17 01:13:14 | <spidr> | a webserver |
| 2021-03-17 01:13:22 | <Axman6> | yeah that too |
| 2021-03-17 01:13:25 | <spidr> | etc |
| 2021-03-17 01:13:26 | <fen> | thinking of the powers to the monomial terms that are over all previous monomial layers |
| 2021-03-17 01:13:38 | <fen> | as weights, along with the monomials weight |
| 2021-03-17 01:13:44 | <Axman6> | "Oh there's a web service, I better make A client for it in Servant) |
| 2021-03-17 01:13:47 | <spidr> | basically is it practical to replace bash/nodejs with |
| 2021-03-17 01:13:49 | <spidr> | haskell lol |
| 2021-03-17 01:14:09 | <spidr> | also perl to haskell |
| 2021-03-17 01:14:24 | <spidr> | a lot of stuff i do for work is glue, making applications talk to each other |
| 2021-03-17 01:14:28 | <spidr> | one api talk to another api |
| 2021-03-17 01:14:28 | <Axman6> | not only practical, but it's usually easy and producer really high performance servers. |
| 2021-03-17 01:14:33 | <spidr> | interesting |
| 2021-03-17 01:14:38 | <fen> | i dont really want the blowup in number of parameters growing with the depth |
| 2021-03-17 01:14:53 | <spidr> | dang now I really want to learn it |
| 2021-03-17 01:15:08 | <spidr> | I've never HAD to read a programming book before haskell |
| 2021-03-17 01:15:09 | × | NinjaTrappeur quits (~ninja@unaffiliated/ninjatrappeur) (Ping timeout: 244 seconds) |
| 2021-03-17 01:15:24 | <Axman6> | I can't remember what I was listening to the toehr day, but they were talking about rewriting PHP services in Haskell, and finding new bugs in their PHP because the PHP was too slow to trigger them, so they had to inject artificial slowdowns to keep everything working happily |
| 2021-03-17 01:15:44 | <spidr> | but I'm getting through Christopher Allen and Julie Moronuki's book |
| 2021-03-17 01:15:46 | <fen> | i guess i need a datastructure that can support both versions as a kind of lengthed list containing lengthed lists |
| 2021-03-17 01:16:17 | <fen> | but it might be difficult to write an evaluation scheme that works for both cases |
| 2021-03-17 01:16:21 | <spidr> | https://haskellbook.com/ |
| 2021-03-17 01:16:21 | <spidr> | this |
| 2021-03-17 01:16:28 | <spidr> | or is there a better resource |
| 2021-03-17 01:17:26 | × | mrchampion quits (~mrchampio@38.18.109.23) (Remote host closed the connection) |
| 2021-03-17 01:17:38 | <Axman6> | I haven't read it but I've heard good things about it. Graham Hutton's Programming in Haskell is what we used in university, and it's since been updated, and is still highly recommended |
| 2021-03-17 01:17:59 | <Axman6> | god, I can't believe Real World Haskell is 12 years old, far out |
| 2021-03-17 01:19:35 | → | DataComputist joins (~lumeng@50.43.26.251) |
| 2021-03-17 01:22:36 | <fen> | https://pastebin.com/raw/M2TJKL5T |
| 2021-03-17 01:22:51 | → | NinjaTrappeur joins (~ninja@unaffiliated/ninjatrappeur) |
| 2021-03-17 01:23:01 | <Axman6> | ConsLOL |
| 2021-03-17 01:23:41 | <fen> | probably could do with some infix sugar |
| 2021-03-17 01:24:09 | → | Stanley00 joins (~stanley00@unaffiliated/stanley00) |
| 2021-03-17 01:24:41 | <fen> | oh yeah, i wanted them growing in length |
| 2021-03-17 01:26:45 | → | mrchampion joins (~mrchampio@38.18.109.23) |
| 2021-03-17 01:26:49 | <fen> | https://pastebin.com/raw/hR2Fs3Yq |
| 2021-03-17 01:27:25 | <Gurkenglas> | @let polynomial instrs init = snd $ mapAccumL go init instrs where go s (c,es) = let x = c * product (zipWith (**) s es) in (tail s ++ [x], x) |
| 2021-03-17 01:27:28 | <lambdabot> | Defined. |
| 2021-03-17 01:27:51 | <fen> | :t polynomial |
| 2021-03-17 01:27:53 | <lambdabot> | (Traversable t, Floating c) => t (c, [c]) -> [c] -> t c |
| 2021-03-17 01:28:02 | × | conal quits (~conal@192.145.118.119) (Quit: Computer has gone to sleep.) |
| 2021-03-17 01:28:11 | <fen> | nice |
| 2021-03-17 01:28:44 | <fen> | so if i can map from this type safe container and apply that, should be done! |
| 2021-03-17 01:29:09 | <Gurkenglas> | or rewrite it to work on the type safe container. |
| 2021-03-17 01:30:12 | <Gurkenglas> | n8 |
| 2021-03-17 01:32:41 | → | manjaroi3 joins (~manjaro-i@183.217.97.244) |
| 2021-03-17 01:32:58 | × | elliott__ quits (~elliott@pool-108-51-101-42.washdc.fios.verizon.net) (Ping timeout: 245 seconds) |
| 2021-03-17 01:33:27 | → | notzmv joins (~zmv@unaffiliated/zmv) |
| 2021-03-17 01:34:13 | × | sMuNiX quits (~sMuNiX@lnsm2-montreal02-142-118-236-120.internet.virginmobile.ca) (Ping timeout: 265 seconds) |
| 2021-03-17 01:34:38 | × | Gurkenglas quits (~Gurkengla@unaffiliated/gurkenglas) (Ping timeout: 245 seconds) |
| 2021-03-17 01:36:55 | travisb | is now known as tabemann |
| 2021-03-17 01:36:56 | × | DTZUZU quits (~DTZUZO@205.ip-149-56-132.net) (Read error: Connection reset by peer) |
| 2021-03-17 01:37:53 | × | acidjnk_new quits (~acidjnk@p200300d0c72b9506e0723511d2830c2e.dip0.t-ipconnect.de) (Ping timeout: 244 seconds) |
| 2021-03-17 01:38:20 | × | theDon quits (~td@94.134.91.58) (Ping timeout: 256 seconds) |
| 2021-03-17 01:39:00 | → | gitgoood joins (~gitgood@80-44-12-129.dynamic.dsl.as9105.com) |
| 2021-03-17 01:40:17 | → | apoc joins (~apoc@49.12.13.193) |
| 2021-03-17 01:41:57 | × | gitgood quits (~gitgood@80-44-12-39.dynamic.dsl.as9105.com) (Ping timeout: 264 seconds) |
| 2021-03-17 01:42:09 | <fen> | seems to work https://pastebin.com/raw/d2MNn6Uj |
| 2021-03-17 01:43:23 | × | acarrico quits (~acarrico@dhcp-68-142-39-249.greenmountainaccess.net) (Ping timeout: 256 seconds) |
| 2021-03-17 01:43:27 | <fen> | wait, is it backwards? |
| 2021-03-17 01:44:06 | <fen> | switching your definition to mapAccumR gives [11.313708498984761,5.656854249492381] |
| 2021-03-17 01:44:16 | <fen> | which seems more like its using the sqrt |
| 2021-03-17 01:44:31 | ← | manjaroi3 parts (~manjaro-i@183.217.97.244) ("leaving") |
| 2021-03-17 01:45:06 | → | manjaroi3 joins (~manjaro-i@183.217.97.244) |
| 2021-03-17 01:45:07 | × | dbmikus quits (~dbmikus@cpe-76-167-86-219.natsow.res.rr.com) (Ping timeout: 244 seconds) |
| 2021-03-17 01:45:35 | → | drbean joins (~drbean@TC210-63-209-44.static.apol.com.tw) |
| 2021-03-17 01:45:56 | <fen> | Gurkenglas: i just read your definition of polynomial, it does tail, does that mean its doing the buffering? |
| 2021-03-17 01:46:09 | <fen> | im not sure if the types on my container match up |
| 2021-03-17 01:49:26 | <fen> | and it should return the sum... |
| 2021-03-17 01:53:03 | manjaroi3 | is now known as InsideBreeze |
| 2021-03-17 01:54:08 | × | z0k quits (~user@115-186-141-88.nayatel.pk) (Quit: WeeChat 3.0) |
| 2021-03-17 01:54:20 | <fen> | this seems ok; https://pastebin.com/raw/mscyUYun |
| 2021-03-17 01:56:53 | → | augnun joins (~augnun@2804:14c:658b:41bb:b8be:cb43:1724:b623) |
| 2021-03-17 01:58:40 | → | ezrakilty joins (~ezrakilty@97-113-58-224.tukw.qwest.net) |
| 2021-03-17 01:58:47 | × | ezrakilty quits (~ezrakilty@97-113-58-224.tukw.qwest.net) (Remote host closed the connection) |
| 2021-03-17 02:02:52 | → | ezrakilt_ joins (~ezrakilty@97-113-58-224.tukw.qwest.net) |
| 2021-03-17 02:10:51 | → | nfd joins (~nfd9001@2601:602:77f:1820:7826:d79f:3033:c241) |
All times are in UTC.