2023-04-06 04:33:49 Now I'm not going to pretend to understand prolog 2023-04-06 06:59:23 : cube dup dup * * : 2023-04-06 06:59:45 veltas: now u can print stuff 2023-04-06 06:59:52 oh: 'haha . 2023-04-06 06:59:53 haha[] 2023-04-06 07:00:19 and its a bit less dangerous as its running on my tablet 2023-04-06 07:01:01 oh:` uname -a` system 2023-04-06 07:01:02 [] 2023-04-06 07:01:15 aah 2023-04-06 07:01:58 Linux localhost 3.10.49-13808168 #1 SMP PREEMPT Mon Jul 23 19:32:17 KST 2018 armv7l GNU/Linux 2023-04-06 07:02:43 oh: : cube dup dup * * ; 2023-04-06 07:02:44 [] 2023-04-06 07:02:50 oh: 24 cube 2023-04-06 07:02:51 [13824] 2023-04-06 07:22:18 oh: bold yellow 'oh . 2023-04-06 07:22:18 oh[] 2023-04-06 07:22:26 xd 2023-04-06 07:25:16 still it does not print errors here and hasbno waybto avoid infinitenloops 2023-04-06 07:48:18 oh: '4hello . 2023-04-06 07:48:18 4hello[] 2023-04-06 07:50:06 oh: '\x68\x69 . 2023-04-06 07:50:06 \x68\x69[] 2023-04-06 07:50:41 oh: 104 emit 2023-04-06 07:50:42 [104] 2023-04-06 07:53:31 Hey - lookie lookie! What a cute little bot. 2023-04-06 07:59:12 So, yesterday I got Linux running on both canisters of one of those new machines. Should be able to knock the other two out fairly quickly this morning; got the process down now. 2023-04-06 08:00:22 It's kind of a pain - the installer won't run all the way through on the serial port. I have to use the serial port to run the initial part of the installer, catch the MAC address of the unit, then set it up in our IP reservation system. Then run again and do the actual installation over the network connection. 2023-04-06 08:00:32 With VNC. 2023-04-06 08:00:53 Not so bad when you know what to do, but figuring it out was a bit tedious. 2023-04-06 08:02:05 I'm installing mosh and a library I know I'm going to need on each one as it comes up, and getting my ssh key in place. But I'm going to wait until I have all four of them running in four console windows and then install my main tools, all in parallel. 2023-04-06 08:03:06 I may see if I can rig my terminal emulator to let me type in all four windows at once. I know terminator will do that; don't know yet whether iTerm2 on the Mac will or not. 2023-04-06 08:03:16 I fixed a bug in zenv yesterday 2023-04-06 08:03:26 But hopefully so - it does seem to be an attempt to clone terminator. 2023-04-06 08:03:32 Oh, what kind? 2023-04-06 08:03:37 I've got some more to fix over weekend probably, since wife is working 2023-04-06 08:03:51 Well +LOOP wasn't compiling correctly 2023-04-06 08:03:55 Yeah - when my wife travels on business I'm usually extra productive. 2023-04-06 08:04:15 I haven't tested it a lot, I was trying my linear regression program and it crashed 2023-04-06 08:04:40 So I've fixed crash, now it runs and quite fast with wrong answer, so need to see if it's my mistake or an issue of lack of precision 2023-04-06 08:05:01 It's an 8-bit forth so cells are 16-bit, doubles are 32-bit 2023-04-06 08:05:14 So I might need to change algorithm a little 2023-04-06 08:05:22 You're using doubles for the calculations? 2023-04-06 08:05:26 Some of them 2023-04-06 08:05:45 There's a numerator and denominator so the denominator probably is only 16-bit, that might be an issue 2023-04-06 08:06:10 Oh, you're doing it as rational numbers? 2023-04-06 08:06:14 I think you have to calculate essentially x-mean/y-mean or something at some point 2023-04-06 08:06:30 M*/ only has so much mileage 2023-04-06 08:06:57 Norman Wildberger would be proud of you. ;-) 2023-04-06 08:07:02 I'm doing fixed point calculations 2023-04-06 08:07:10 He's a big rational number advocate. 2023-04-06 08:07:21 But it is very encouraging how fast it is 2023-04-06 08:07:24 He thinks we should use them, or something of the sort, for everything. 2023-04-06 08:07:33 I'll bet. 2023-04-06 08:07:43 It's being built as a tokenised forth and it's wayyyyyyy faster than ZX Spectrum's built-in BASIC 2023-04-06 08:07:46 In every single regard 2023-04-06 08:09:18 Nice. That sort of calculation is basically equivalent to matrix / vector work, and different values can create different "precisision sensitivity." 2023-04-06 08:09:28 So it might do great on some problems and no so great on others. 2023-04-06 08:09:45 Depends on how the eigenvalues of the matrix are spread around. 2023-04-06 08:10:02 It's actually more obvious to me that it will overflow when looking at it as the calculation it is, rather than as a matrix 2023-04-06 08:10:23 Sure - that makes sense. 2023-04-06 08:10:49 But you could set it up as a matrix calculation if you wanted to, so that sensitivity potential is "in there." 2023-04-06 08:10:50 And it's how I'm used to doing it 2023-04-06 08:11:05 I wasn't meaning to be critical of your method. 2023-04-06 08:11:23 I know everyone assumes C programmers are stupid and don't check for overflow etc but I do all day every day (while I'm programming, anyway) because my code often can't afford to have that kind of failure 2023-04-06 08:11:35 Yeah I know 2023-04-06 08:12:08 As far as I'm concerned, understanding overflow etc is necessary whether you're writing C, C++, Rust, Java, etc 2023-04-06 08:12:09 There are just a lot of weak C programmers in the world. 2023-04-06 08:12:18 Lot of folks dabble without really knowing what they're d oing. 2023-04-06 08:12:32 And sometimes I'm in that group - depends on what the code is doing. 2023-04-06 08:12:49 I've definitely been known to tinker at things I don't totally understand. 2023-04-06 08:12:54 I think I work with the most hated programming language and probably most misunderstood programming language 2023-04-06 08:14:03 I'd even go so far as to say that I don't *really* "know C." I can sling it around, but I'm not really well tuned on the finer points. 2023-04-06 08:14:18 Well a lot of the 'finer points' are truly irrelevant 2023-04-06 08:14:35 True enough. 2023-04-06 08:15:39 I'm interested in this, though - let us know as you figure more out. About this accuracy thing, I mean. 2023-04-06 08:16:10 As I said it's probably the denominator overflowing, I'll see tonight 2023-04-06 08:16:17 Don't have code infront of me at the moment 2023-04-06 08:16:17 Sometimes just the order of calculations can affect that, so you may find some smoking gun in there. 2023-04-06 08:16:50 Unfortunately I already massaged it into the best ordering, so I probably just need to reduce the precision (i.e. multiply by 100 instead of 10000 or something) 2023-04-06 08:16:56 The main place I do integer calculations of things that one would normally use floating point for is in bash. 2023-04-06 08:17:23 I'm going to say it, floating point in forth feels *wrong* 2023-04-06 08:17:28 I don't try to do any really heavy calculation lifting with bas, but sometimes there are small calculations I choose to just do that way instead of adding some other tool. 2023-04-06 08:17:48 I'm not unsympathetic to that. It's certainly how Chuck felt. 2023-04-06 08:17:57 Classic Forth's use of mixed precision is actually really sophisticated and matches the way even x86 works 2023-04-06 08:17:58 It's pretty counter to the whole core philosophy. 2023-04-06 08:18:21 Ultimately floating point is a crutch. 2023-04-06 08:18:53 Well floating point has been a staple of computing for almost as long as electronic computers have existed 2023-04-06 08:19:06 And floating point itself is ancient 2023-04-06 08:19:10 Yes, it's a popular crutch. :-) 2023-04-06 08:19:31 But it's something that was clearly *slow* for microcomputers in the beginning, and is still slow for embedded 2023-04-06 08:19:36 So for Forth it's already alien 2023-04-06 08:19:50 It requires more power, more transistors, etc 2023-04-06 08:19:55 Yep. 2023-04-06 08:20:04 And it's 99% of the time unnecessary 2023-04-06 08:20:13 Yes. 2023-04-06 08:20:31 And it is no magic bullet, most people use floating point but few actually 'understand' it (even though it's not even that hard to understand the proper amount) 2023-04-06 08:20:52 Well, I guess the reason for that is that a float is ultimately just two integers that you could have handled separately, but the way the system handles them has to be general enough to cover all possible cases. 2023-04-06 08:21:04 If you managed the two integers yourself, you could be problem-specific. 2023-04-06 08:22:41 And by the way, if you are a programmer, then as far as I am concerned you *should* understand floating point 2023-04-06 08:23:20 I'm not trying to avoid complicating the necessary knowledge, I think it's unavoidable to need to understand it. I just think it smells in Forth. 2023-04-06 08:29:46 You know what's actually a great feature in C that's totally underrated or even despised? 2023-04-06 08:29:49 Null terminators 2023-04-06 08:30:14 And it sucks that forth doesn't have them, because it would greatly simplify a lot of code 2023-04-06 08:30:27 Well forth can have them, but it's not part of the 'standards' 2023-04-06 08:31:20 I mean for one thing, it takes up the space of a counted string, but allows arbitrary length. 2023-04-06 08:31:57 It means you can parse without checking length, because null is your 'terminator' symbol so just don't accept it unless EOF is allowed 2023-04-06 08:32:15 This property actually speeds up parsing in practice on modern systems because there are less branches 2023-04-06 08:32:45 But among the 'enlightened' of the internet null terminators are "the second biggest mistake of C" etc 2023-04-06 08:33:36 i wonder how much programming those people actually do 2023-04-06 08:41:07 it's interesting how there is a lot of noise out there trying to convince others to avoid certain techniques, behaviours or practises (even outside of programming) and that so many of us choose to buy into their claims without really thinking about it too much 2023-04-06 08:45:06 i think part of the bad reputation that C has got with some, is that most people who end up writing programs in C don't dig deep enough to become aware that the abstract machine they're targetting is not the native machine the program may end up being compiled for. 2023-04-06 09:34:18 brother, have you heard the good word of the two-week agile sprint 2023-04-06 10:21:00 veltas: I do agree re: floating point. It's an unavoidable part of the world. 2023-04-06 10:21:54 My forth uses null terminators. 2023-04-06 10:22:07 But I use counted strings too; depends on the situation. 2023-04-06 10:22:19 In particular WORD delivers a counted string. 2023-04-06 10:26:11 But when I grab a line from the console for interpretation, that comes back as a null-terminated string. 2023-04-06 10:26:59 And I actually do something a lot of folks would probably frown on - I have WORD wired so that it won't move past a null termination in the string it's processing. The null terminates its scan, and if the null is all it sees it returns that null string as the word just parsed. 2023-04-06 10:27:09 And I have that word in my dictionary as an immediate word. 2023-04-06 10:27:23 It's how I terminate the loop in INTERPRET. 2023-04-06 10:27:50 INTERPRET just has the equivalent of a BEGIN ... AGAIN and would never stop on its own. 2023-04-06 10:35:28 KipIngram: Even in standard forth WORD gives a counted string 2023-04-06 10:35:41 Would break too much if they changed that 2023-04-06 10:36:48 Terminating on null I think is a common trick for ending an interpreter 2023-04-06 10:37:01 I think in tokenised forths they use value 0 for EXIT or something 2023-04-06 10:37:39 pretty sure terminate on null was in a brodie book 2023-04-06 11:40:48 Sure, but one could also explicitly code the loop in INTERPRET to look for a null char. 2023-04-06 11:40:55 That would be the way you'd do it in C, for example. 2023-04-06 11:41:21 It's the manner in which it's accomplished that's different in Forth (or can be different), because we can access the return stack and play games with it. 2023-04-06 23:02:29 crc: what's the biggest/most complex program you've written in retro-forth? 2023-04-06 23:03:53 Not a public release; probably the order management tool we use at work. 2023-04-06 23:04:37 :0 2023-04-06 23:05:18 what features did help in making it, and did you miss any feature that might make it easier? 2023-04-06 23:09:14 Helpful: Retro has a pretty good strings vocabulary, which I use a lot in this. Hard to say on the second. It's modular, so I can use other languages and tools for some parts. E.g., I use jq to deal with Jason, selling 2023-04-06 23:09:25 Json not Jason 2023-04-06 23:10:03 I needed some sqlite3 support, so I wrote a vocabulary to deal with that 2023-04-06 23:10:30 Json and the argonauts 2023-04-06 23:16:22 so mainly a db and json 2023-04-06 23:16:23 xD 2023-04-06 23:17:05 and string handling 2023-04-06 23:38:44 (j)uly (a)ugust (s)eptember (o)ctober (n)ovember