Re: [Jprogramming] Agenda on different versions ...

2023-12-26 Thread Raul Miller
t if it is unclear. Your description of the operation > is correct. > > Henry Rich > > On 12/26/2023 6:14 PM, Raul Miller wrote: > > I should add that the nuvoc has some examples of implied rank, but I > > can't figure out why a list of 10 numbers from an infinite ranked v > >

Re: [Jprogramming] Index of item in table

2023-12-26 Thread Raul Miller
8 ($@] #: [ I.@:= ,@]) A 1 3 8 (4 $. $.@:= ) A 1 3 Note that both of these results are rank 2. -- Raul On Tue, Dec 26, 2023 at 8:32 PM David Pinchbeck wrote: > > Having trouble finding this in the wiki: I know that we can select from a > table using a boxed pair > > A > > 0 1 2 3 4 > >

Re: [Jprogramming] Agenda on different versions ...

2023-12-26 Thread Raul Miller
ot;_1 on a rank 1 list acts at rank 0 and "_1 on a rank 2 list acts at rank 1. But that doesn't match the text of the description. -- Raul On Tue, Dec 26, 2023 at 6:10 PM Raul Miller wrote: > > It's not clear to me why this is a rank error. > >2&|i.5 > 0 1 0 1 0 >

Re: [Jprogramming] Agenda on different versions ...

2023-12-26 Thread Raul Miller
It's not clear to me why this is a rank error. 2&|i.5 0 1 0 1 0 0:`1:@.0 1 0 1 0 0: 1: 0: 1: 0: (0:`1:@.0 1 0 1 0) i.5 1 That said, this line from nuvoc might be the issue: "The implied rank of m@.v y is the rank of y minus the rank of v y. y is then split into cells of that rank, and

Re: [Jprogramming] testing for J version or later

2023-12-21 Thread Raul Miller
Hmm... only if we're updating stdlib, supporting versions of J back to 4.0.1. A worthwhile effort, though, if someone was actually tackling those issues. Otherwise, I think an idiom would be about as good as it gets. -- Raul On Thu, Dec 21, 2023 at 9:24 PM Ian Clark wrote: > > For those of

Re: [Jprogramming] sorting using verb returing a boolean

2023-12-21 Thread Raul Miller
gt; 0 0 2 3 3 3 6 6 9 9 > ( 1 > > It is unstable, but that is to be expected. And it can be made stable without > comparing for equality by pairing every element with its index. > > On Thu, 21 Dec 2023, Raul Miller wrote: > > > It's probably worth noting here that (for example)

Re: [Jprogramming] sorting using verb returing a boolean

2023-12-21 Thread Raul Miller
It's probably worth noting here that (for example) the quicksort algorithm relies on being able to tell whether items are equal. And a 0 1 result can't distinguish between ordering and equality. Many sorting implementations rely on a _1, 0, 1 result, as a consequence. That said, you could

Re: [Jprogramming] hello and announcement on implementation of web form server system for adding forms to Jconsole function

2023-12-19 Thread Raul Miller
This looks interesting, though it will take some time for me to digest adequately. One thing which occurs to me is that begin_simple_server_or_client_jconsole.ijs and begin_simple_server_or_client_jconsole_wsl.ijs in the making_basic directory could be combined into a single script, though there

Re: [Jprogramming] Horse straggles cart

2023-12-17 Thread Raul Miller
There's actually several issues here, one being the parsing issue Henry has highlighted. Another is a difficulty in reproducing the problem: f=: {{ GLOBAL=: 'global defined here' }} GLOBAL [ f'' |domain error in GLOBAL, executing monad GLOBAL | GLOBAL[f'' GLOBAL [ f'' global

Re: [Jprogramming] j9.5.0-beta9 available

2023-12-14 Thread Raul Miller
The base library is indeed in addons. And, you can edit httpget_jpacman_ to show you the urls it's fetching (and, thus, the url it's failing on). That said, I remember seeing https certificate errors a few days ago, so I expect that jsoftware is experiencing a hosting issue. I hope this helps,

Re: [Jprogramming] Advent of code newbie

2023-12-09 Thread Raul Miller
It does accomplish the same thing, and is more concise (and, thus, for many people (though not all) easier to read). That said, I would keep in mind that the AoC puzzle framework encourages quick solutions and throwaway code, and many of the implementations are going to favor a low investment of

Re: [Jprogramming] A Dot-Graph Rotator

2023-12-07 Thread Raul Miller
Or, more simply 22j10*^j.o.15%180 18.6622j15.3533 That said, you could also use J's notation for entering complex numbers using polar coordinates 22j10*1ad15 18.6622j15.3533 I hope this makes sense, -- Raul On Thu, Dec 7, 2023 at 12:20 PM Henry Rich wrote: > > 22j10 (*

Re: [Jprogramming] String replacement question

2023-12-02 Thread Raul Miller
That approach has a dependence on the user's input text. For example, consider nineightwo That said, another approach I have been told of was putting the digit name before and after the digit in the replacement text. -- Raul On Sat, Dec 2, 2023 at 12:28 PM LdBeth wrote: > > A very clever

Re: [Jprogramming] String replacement question

2023-12-01 Thread Raul Miller
https://code.jsoftware.com/wiki/ShareMyScreen/AdventOfCode/2023/01/Trebuchet/rdm offers one approach. But it could be golfed to be more concise. -- Raul On Fri, Dec 1, 2023 at 9:29 PM David Pinchbeck wrote: > > I'm trying to improve my J using Advent of Code, but am already a bit > stuck on

Re: [Jprogramming] Report of the J wiki group meeting of November 2, 2023

2023-11-13 Thread Raul Miller
two cents > Jan-Pieter > > > On Mon, 13 Nov 2023, 07:09 'robert therriault' via Programming, < > programm...@jsoftware.com> wrote: > > > == Report of Meeting 2023-11-02 == > > > > Present: Ed Gottsman, Raul Miller, and Bob Therriault > > > > Ful

Re: [Jprogramming] (no subject)

2023-10-17 Thread Raul Miller
This sentence gives me an error even without parens. Looking closer, I see six left parentheses and seven right parentheses here: ({:`([:$:0 1&+)@.(9&<@{.)@(([:*/"."0@":@{.),{:))"1(|:@,:1:))50 25 33 22 293 Getting rid of the far right parenthesis gives me the result which you displayed.

Re: [Jprogramming] Issue with dual/under

2023-10-13 Thread Raul Miller
I guess it's true that the obverse of ravel hasn't changed: ,inv i.9 |domain error | ,inv i.9 JVERSION Installer: j602a_win64.exe Engine: j602/2008-03-03/16:45 Library: 6.02.071 -- Raul On Fri, Oct 13, 2023 at 2:38 PM 'Viktor Grigorov' via Programming wrote: > > Hey, > > While

Re: [Jprogramming] Alternating sequences

2023-10-03 Thread Raul Miller
A couple notes here: One is that 0j18":Y will give you 18 places after the decimal point regardless of the magnitude of Y Another is that we can inspect intermediate results in the expression %-/%!2+x:i.x Let's try that here with smaller values for x (and leaving out the x: so that we're using

Re: [Jprogramming] Primes with combination of same digits

2023-09-24 Thread Raul Miller
If anyone wants to beef up the rosetta entry https://www.rosettacode.org/wiki/Circular_primes#J this might be a good opportunity. (That said, note that the site was down for most of yesterday. I have not yet heard what happened, but possibly it was overloaded with visitors.) -- Raul On Sun,

Re: [Jprogramming] wd peculiarity: isigraph issue (addendum to the addendum)

2023-09-21 Thread Raul Miller
(this probably should have been sent to general@ instead of programming@) When I remove the NB. in front of the isigraph line, I still get normal behavior from this on my windows machine. So I am going to guess that there's something about the OSX environment triggering the problem. -- Raul On

Re: [Jprogramming] Using rest API in J

2023-09-20 Thread Raul Miller
On Wed, Sep 20, 2023 at 9:09 AM Michael Dykman wrote: > What you need to do is to add a header to your request. The header name > will be 'Ocp-Apim-Subscription-Key' and the value, whatever key you > received. > > If it's curl under the hood, the option to add a header is '-H >

Re: [Jprogramming] Interesting Quora Problem:

2023-09-11 Thread Raul Miller
On Mon, Sep 11, 2023 at 2:48 AM 'Skip Cave' via Programming wrote: > Raul used a 'chain of dyadic verbs' (x F x F x F y) to solve the problem. I > haven't ever tried this, where right-to-left execution is used to feed the > result of one dyadic verb into the next one on the left. It was a bit >

Re: [Jprogramming] Interesting Quora Problem:

2023-09-11 Thread Raul Miller
Oops, I had N=: N1 when I tested that. Hopefully that was clear enough. -- Raul P.S. Thanks to Brian Schott for testing and informing me of this mistake. On Sun, Sep 10, 2023 at 6:08 PM Raul Miller wrote: > > I guess to simplify it, I would filter the possibilities at each step. >

Re: [Jprogramming] Interesting Quora Problem:

2023-09-10 Thread Raul Miller
I guess to simplify it, I would filter the possibilities at each step. first digit divisible by 1: N1=: 1+i.9 Second digit divisible by 2: N2=: ;(10*N1)+each (<2*1+i.4)-.each N Third digit divisible by 3: digits=:

Re: [Jprogramming] Rank difficulties

2023-09-07 Thread Raul Miller
I believe Henry meant to say: ~.@(, i.@#@$) |: ] For example: $1 2 (~.@(, i.@#@$) |: ]) i. 2 3 5 7 11 3 5 2 7 11 Though, I imagine the typical case identifies only a single dimension in the left argument and a lower dimensional array in the right argument. For example: $ 1 (~.@(,

Re: [Jprogramming] Google Bard question.

2023-08-30 Thread Raul Miller
A problem with LLMs is that they have very little to no "first hand experience". Generally speaking, they don't have a lifetime's experience with a sense of smell, nor even with a sense of vision. They haven't experienced hunger (though they might have experienced sleep). They don't have any

Re: [Jprogramming] integers occur in integers?

2023-08-26 Thread Raul Miller
Yes... using rank 1 0 on the implementation is a good alternative to boxing. Using the approach I had come up with (I have not done any benchmarking here), this could be: 3 2 1((0 = #@-.~)

Re: [Jprogramming] integers occur in integers?

2023-08-26 Thread Raul Miller
I think you should change your description to "I am trying to find out which integers in y contain no other digits than x" I am also going to imagine that Thomas Bulka's proposed result is correct here. Experimenting with this, one of the issues is efficiency and 0 as a digit. Since 0 is used

Re: [Jprogramming] J build fail

2023-08-21 Thread Raul Miller
in the jsource.yml for a specific architecture.) Thanks, -- Raul On Mon, Aug 21, 2023 at 8:46 PM Elijah Stone wrote: > > ? buildga.sh uses make2 > > as for the runtime failure, I have no idea what could cause that > > On Mon, 21 Aug 2023, Raul Miller wrote: > > > As

Re: [Jprogramming] J build fail

2023-08-21 Thread Raul Miller
As I understand it, the make2 directory isn't being maintained for the general case, and at this point is mostly a historical artifact (it assumes you're using the right version of clang, for example). script/buildga.sh has approximately replaced it. (See also script/github_builds.txt) -- Raul

Re: [Jprogramming] Anagram Operator (A.) and Generalized Datatype declaration in function assignments.

2023-08-16 Thread Raul Miller
s evaluated to a name > > > > After the words have been given types and maybe values, they are > > processed right to left according to the parsing rules. During the > > parsing, a name is looked up and replaced by its stored type/value > > (except whe

Re: [Jprogramming] Anagram Operator (A.) and Generalized Datatype declaration in function assignments.

2023-08-15 Thread Raul Miller
verb to do it. > > >> > > >> Henry Rich > > >> > > >> > > >> On 8/14/2023 9:14 PM, Ak O wrote: > > >>> Is there a more simple way of feeding the interpreter? > > >>> > > >>> Meaning, is there

Re: [Jprogramming] Anagram Operator (A.) and Generalized Datatype declaration in function assignments.

2023-08-14 Thread Raul Miller
t; > I must be able to run that track without needing to escape the function. > > > :) > > Ak > > > > On Mon., Aug. 14, 2023, 13:30 Raul Miller, wrote: > > > I think you should re-read Henry's message that you were responding to > > here. > > > >

Re: [Jprogramming] Anagram Operator (A.) and Generalized Datatype declaration in function assignments.

2023-08-14 Thread Raul Miller
I think you should re-read Henry's message that you were responding to here. By the time any J function can run, it's already too late. -- Raul On Mon, Aug 14, 2023 at 12:58 PM Ak O wrote: > > What expression allows a function to recieve an argument 'y' as a literal > without using quotes? >

Re: [Jprogramming] Anagram Operator (A.) and Generalized Datatype declaration in function assignments.

2023-08-11 Thread Raul Miller
The (A.) verb uses whatever argument you pass it. But the language is modular -- parsing of numbers is independent of (happens before) whatever operation(s) they will be used in. So I think you are asking about the conversion table at https://www.jsoftware.com/help/dictionary/dictg.htm One issue

Re: [Jprogramming] Anagram Operator (A.) and Generalized Datatype declaration in function assignments.

2023-08-11 Thread Raul Miller
Use 180548043269214573494164592263168x if you want that sequence of digits to be treated as an extended precision number. Omitting the x would result in the use of fixed with (64 bit) storage, which will lose precision. -- Raul On Fri, Aug 11, 2023 at 2:44 PM Ak O wrote: > > Hi everybody, I

Re: [Jprogramming] Explicit to tacit conversion without repeating verbs

2023-08-10 Thread Raul Miller
1) yes, but it might not be a good idea. (You can form x and y into a sequence which can be passed as a single argument, and then extract arguments from that sequence.) 2) If Q is expensive to compute, I am aware of two other options: (a) use a name to refer to its result (as you have done

Re: [Jprogramming] Advent of Code 2022 in J, as a tutorial

2023-08-09 Thread Raul Miller
After a quick review of these: Some of them look like they would be good for a beginner - especially those which spell out the reasoning that went into building the code. I'm pretty sure it's the thought processes of the J programmer which Henry is after here. Others would be more problematic

Re: [Jprogramming] Advent of Code 2022 in J, as a tutorial

2023-08-04 Thread Raul Miller
On Fri, Aug 4, 2023 at 9:32 AM Jan-Pieter Jacobs wrote: > As a side note: does anyone have code for downloading inputs directly?. I haven't tackled that problem, though I have not ruled out tackling it at some point in the future. (It's not trivial.) That said, you could use launch_jbrowser_

Re: [Jprogramming] Syntax Highlighting: Special Combinations

2023-07-31 Thread Raul Miller
ble at execution time. > > Another type of phrases that might be nice to highlight is things like > possibilities for speeding up by dropping tolerant comparison: While working > on AoC, I recently had a case where using i.!.0 instead of i. for lookup of > rows in a matrix sped up the

Re: [Jprogramming] Syntax Highlighting: Special Combinations

2023-07-30 Thread Raul Miller
In the wiki, we have aka GeSHI. https://www.mediawiki.org/wiki/Extension:SyntaxHighlight https://github.com/GeSHi/geshi-1.0/blob/master/src/geshi/j.php In jqt, we're using QSyntaxHighlighter https://doc.qt.io/qt-5/qsyntaxhighlighter.html

Re: [Jprogramming] Syntax Highlighting: Special Combinations

2023-07-30 Thread Raul Miller
I see two possible ways to implement this sort of functionality. (A) Create a duplicate copy of J's parser, which would run in the highlighting environment, to identify regions corresponding to "special code", or (B) Update J itself to provide a "dry run" mechanism to identify these regions in a

Re: [Jprogramming] Differentiation

2023-07-22 Thread Raul Miller
JVERSION Engine: j807/j64/windows Release-d: commercial/2019-03-18T13:21:35 Library: 8.07.26 Qt IDE: 1.7.10s/5.9.8 Platform: Win 64 Installer: J807 install InstallPath: c:/other/j64-807 Contact: www.jsoftware.com f=: 5&^ - 7&* f d.1 (0) _5.39056 (5&^ - 7&*)d.1(0) _5.39056 g=: f d.1

Re: [Jprogramming] polycubes

2023-07-18 Thread Raul Miller
, -- Raul On Tue, Jul 18, 2023 at 6:22 PM 'Mike Day' via Programming wrote: > > A couple of qs re canon: > why power 2? > why p:? Isn't the I. sufficient? > > Cheers, > > Mike > > Sent from my iPad > > > On 18 Jul 2023, at 22:14, Raul Miller wrote: > > >

Re: [Jprogramming] polycubes

2023-07-18 Thread Raul Miller
ht, down etc for the sub-set of singly > connected > (I think) pc's. > > All for now - got to go out, > > Mike > > On 15/07/2023 22:03, Raul Miller wrote: > > https://en.wikipedia.org/wiki/Polycube > > > > Today, I've been playing with polycubes (which are p

Re: [Jprogramming] JQt startup time - again!

2023-07-16 Thread Raul Miller
I guess I'd start by looking at what process explorer could tell me about that jqt instance. https://learn.microsoft.com/en-us/sysinternals/downloads/process-explorer For example: when you right click on the jqt process, do the windows controls work? Or are they greyed out? Does changing process

[Jprogramming] polycubes

2023-07-15 Thread Raul Miller
https://en.wikipedia.org/wiki/Polycube Today, I've been playing with polycubes (which are polyhedrons formed from adjacent cubes). This requires both a representation -- a rank 3 bit array works nicely, and a mechanism for working with cubic symmetry. For that, I went with: rotx=: |."2@(2 1&|:)

Re: [Jprogramming] Simulations

2023-07-15 Thread Raul Miller
I think the approaches you described are fine. That said, another approach would be to think of your dataset as a table -- one row for each atom, with each column having different significance. coordinate x,y, z; velocity x,y,z; force x,y,z, So, if you had 42 atoms, your data would be a 42 by 9

Re: [Jprogramming] If, else on each element of an array

2023-07-13 Thread Raul Miller
+: is double, < is box (which in this example would throw a type error). Other than that, ... using @. seems to be the way to go. Thanks, -- Raul On Thu, Jul 13, 2023 at 6:01 PM Henry Rich wrote: > > +:`*:@.(1:) i. 20 NB. square the primes, double the nonprimes > 0 2 4 9 8 25 12 49 16

Re: [Jprogramming] jios 903.2 glitch

2023-07-10 Thread Raul Miller
What is gcd2x? -- Raul On Mon, Jul 10, 2023 at 12:49 PM 'Mike Day' via Programming wrote: > > I'm probably missing the blindingly obvious but why does this happen in JIOS > on my iPad but not in J903, J9.4 & J9.5 under Windows? > >JVERSION > Engine: j903/j64/iOS > beta-k:

Re: [Jprogramming] how to apply the same adverb repeatedly ?

2023-06-13 Thread Raul Miller
[I thought I had sent this yesterday, but today I find it in draft status] Note that you can eliminate some of the parenthesis here, and some of the quotation marks (though this does place a burden on the reader's understanding of j syntax): ({{y`:6 nc`''}} ^: 9 +:`'') (`:6) 7 23 or

Re: [Jprogramming] how to apply the same adverb repeatedly ?

2023-06-12 Thread Raul Miller
Note that nc is typically defined as 4!:0 so redefining it might break some code. That said: nc=. 1 : '[: >: u' mnc=: {{ (`(m#<'nc'))(`:6) }} + 9 mnc 7 16 + 9 mnc [: >: [: >: [: >: [: >: [: >: [: >: [: >: [: >: [: >: + 9 mnc (`(nc`nc`nc`nc`nc`nc`nc`nc`nc))(`:6) I hope this makes

Re: [Jprogramming] Fwd: Adverb in parsing table

2023-06-10 Thread Raul Miller
Adverbs are never dyadic. Nor are they monadic in the sense that verbs are monadic. (An adverb takes a single left argument, a monadic verb takes a single right argument.) If the result of the adverb is a verb (which is the case for built-in adverbs, and many user defined adverbs), the resulting

Re: [Jprogramming] Problem with capped fork ?

2023-05-25 Thread Raul Miller
The issue is the rank of the @. derived verb No additional problem is introduced through the use of a hook here. Thanks, -- Raul On Thu, May 25, 2023 at 2:05 PM Martin Kreuzer wrote: > > In addition, I don't understand why > > f=: (1:)`(* [: $: <:) @. * > > shouldn't suffice, compared to

Re: [Jprogramming] Problem with capped fork ?

2023-05-25 Thread Raul Miller
This is odd. According to https://code.jsoftware.com/wiki/Vocabulary/atdot f should have rank 0 (since v is * here). But, when I redefine f as f=: 1:`(] * [: $:&([echo) <:)@.* I see that when (f 2 3 5 7 11) is executed, f is being treated as some other rank. This does not occur for (f 2 3 5

Re: [Jprogramming] J - bootstrapped

2023-05-13 Thread Raul Miller
Possibly Dan Bron's efforts? https://code.jsoftware.com/wiki/User:Dan_Bron/Temp/ParseLexExecute https://code.jsoftware.com/wiki/User:Dan_Bron/JnJ Also https://code.jsoftware.com/wiki/Guides/Parsing I hope this helps, -- Raul On Sat, May 13, 2023 at 7:33 AM Ian Clark wrote: > > The Weston

Re: [Jprogramming] Search

2023-05-10 Thread Raul Miller
I think the issue you are talking about here is the result from (?.) It would be plausibly nice if ?. had a definition which is architecture and version independent. But that has not been the case and probably will not be the case. Already, there's too many variants out there for broad

Re: [Jprogramming] Search

2023-05-10 Thread Raul Miller
ssing out on! > > From: Programming on behalf of > Raul Miller > Sent: Wednesday, May 10, 2023 3:07:54 PM > To: programm...@jsoftware.com > Subject: Re: [Jprogramming] Search > > I don't think that it's actually that simple. > > Aside from the difficulty of retrofitti

Re: [Jprogramming] Search

2023-05-10 Thread Raul Miller
I don't think that it's actually that simple. Aside from the difficulty of retrofitting a new name with high search engine selectivity (e.g. nuvoc) onto existing content so that we could find it with less effort, I think we're ignoring some of the other pressures out there, which interfere with

Re: [Jprogramming] Search

2023-05-09 Thread Raul Miller
exchange.com for "j > programming language" without the quotes. Most of the 1921 results seem to > have the tag "j". > > I am not familiar with the code review aspects, though. > > On Tue, May 9, 2023 at 5:34 PM Raul Miller wrote: > > > I expect

Re: [Jprogramming] Search

2023-05-09 Thread Raul Miller
I expect that the people at jpl.nasa.gov would agree that "jpl" has a nice ring to it. But are our contributions up to their level? Anyways, for now, adding (jlang OR jprogramming OR jsoftware OR site:jsoftware.com) to a search tends to find at least some J content. And, maybe if more

Re: [Jprogramming] GitHub Copilot anyone used this with J?

2023-05-08 Thread Raul Miller
I guess one question is: does the mechanism understand J token formation? For example, can you determine if it understands the difference between +/ .* and +/.* ? If so, can it recognize that + /. * is the same as +/.* ? And, if so, does it recognize that {{ and { { are different while [[ and [

Re: [Jprogramming] J Playground and escaping Typescript

2023-05-05 Thread Raul Miller
2!:0 'document.location.pathname' /j-playground/bin/html2/ FYI, -- Ral On Fri, May 5, 2023 at 4:18 AM Ed Gottsman wrote: > > Greetings. I recently spent some time with the J Playground. I don't know > enough to appreciate everything that must have gone into its implementation > (though I

Re: [Jprogramming] How should the new m. deal with missing reciprocals?

2023-04-27 Thread Raul Miller
Hmm... Looking at this, the domain errors do seem analogous to divide by zero errors. So, in the context of %m.n, if we were being purely symmetric, a 0 result when both the numerator and denominator were effectively 0 would be the way to go, with an infinite result for the remaining cases.

Re: [Jprogramming] J9.5 beta

2023-04-26 Thread Raul Miller
Actually, https://code.jsoftware.com/wiki/System/Installation/J9.5/Zips recommends (in jconsole): load 'pacman' 'install' jpkg '*' exit 0 (Which would also install the qtide.) FYI, -- Raul On Wed, Apr 26, 2023 at 11:07 AM 'Michael Day' via Programming wrote: > > Oh - I forgot that

Re: [Jprogramming] sequential machine and empty word output

2023-04-24 Thread Raul Miller
Parsing csv seems like the motivation here. If so, it would also be good to have a more complete test suite. In particular, csv double quote handling -- https://stackoverflow.com/questions/66096193/having-multiple-double-quotes-inside-quoted-string-csv-file for example -- means that your opcode

Re: [Jprogramming] Peculiarity with gethttp

2023-04-22 Thread Raul Miller
shouldn’t get through to it). However, I found that *not* escaping > them…works. So I don’t. (I guess I never tried that one with gethttp.) > > I don’t fully understand what’s going on, but I’m going to declare victory > until I get a bug report. > > Thank you. > > Ed > > >

Re: [Jprogramming] Peculiarity with gethttp

2023-04-22 Thread Raul Miller
I don't think that's it. I think the issue here is that gethttp runs curl, and on OSX, the & character is a command separator (similar to ; or newline, except that it also specifies that the command to its left is run in the background). So, fetching

Re: [Jprogramming] docs for 11!:n (JWd)?

2023-04-17 Thread Raul Miller
e 0 of the array" > > > f -> a flag of some sort > > > m -> "maximum number of bytes in ravel" > > > t -> the type > > > c -> reference count > > > n -> the length of the data > > > r -> rank > &g

Re: [Jprogramming] can i record audio in jqt?

2023-04-17 Thread Raul Miller
It would need added support in https://github.com/jsoftware/qtide -- right now, jqt doesn't have a control which uses QAudioRecorder. But it seems doable. Thanks, -- Raul On Mon, Apr 17, 2023 at 1:02 PM Michal Wallace wrote: > > I see there is a qtaudio_wasapi.dll and qtaudio_windows.dll...

Re: [Jprogramming] docs for 11!:n (JWd)?

2023-04-15 Thread Raul Miller
/Window_Driver Just wanting to make sure... Thanks, -- Raul On Sat, Apr 15, 2023 at 5:00 PM Raul Miller wrote: > > Jwd sounds like version 6 of J. This predates Jqt. > > There's some docs at > https://www.jsoftware.com/docs/help602/user/win_driver_cmd_ref_overview.htm > &

Re: [Jprogramming] docs for 11!:n (JWd)?

2023-04-15 Thread Raul Miller
Jwd sounds like version 6 of J. This predates Jqt. There's some docs at https://www.jsoftware.com/docs/help602/user/win_driver_cmd_ref_overview.htm I hope this helps, -- Raul On Sat, Apr 15, 2023 at 4:57 PM Michal Wallace wrote: > > Hey all, > > I've been working on JPrez again -- a

Re: [Jprogramming] kadane algorithm vs brute force timing and memory

2023-04-07 Thread Raul Miller
Generally speaking, when thinking about performance, benchmarking is a critical step. There's a *lot* of theoretical issues which are only approximations, at best. That said, in this case, there's also documentation (if you know where to look). For example:

Re: [Jprogramming] what is (or was) 'graph'?

2023-04-07 Thread Raul Miller
I've gone ahead and changed the page to address some functional issues. (Note: I'm using "functional" here in the sense of "working" rather than as a reference to "functional programming style". That said, I have not tested everything on the page, and it's entirely possible that I've overlooked

Re: [Jprogramming] kadane algorithm vs brute force timing and memory

2023-04-07 Thread Raul Miller
ul On Fri, Apr 7, 2023 at 3:47 AM Raul Miller wrote: > > This does't look like O(n^2) > >kad=. >./@:(([ >. +)/\.) >timex 'kad ?1e4#0' > 0.002802 >timex 'kad ?1e5#0' > 0.0142999 >timex 'kad ?1e6#0' > 0.0674812 >timex 'kad ?1e7#0' >

Re: [Jprogramming] kadane algorithm vs brute force timing and memory

2023-04-07 Thread Raul Miller
This does't look like O(n^2) kad=. >./@:(([ >. +)/\.) timex 'kad ?1e4#0' 0.002802 timex 'kad ?1e5#0' 0.0142999 timex 'kad ?1e6#0' 0.0674812 timex 'kad ?1e7#0' 0.57413 timex 'kad ?1e8#0' 5.98958 2 %~/\ 5.98958 0.57413 0.0674812 0.0142999 0.002802 0.0958548 0.117536 0.211909

Re: [Jprogramming] what is (or was) 'graph'?

2023-04-06 Thread Raul Miller
I've been playing with this, and I haven't been able to come up with a working translation of that code fragment. Here's my current best guess, though it still does not work: load 'graph' gdopen''NB. Create drawing surface gdcolor 255 0 0 NB. set the color gdpen 2,

Re: [Jprogramming] lp?

2023-04-05 Thread Raul Miller
variables makes it > bad, continuing to increase that variable will never make it good again. > > On Wed, 5 Apr 2023, Raul Miller wrote: > > > What does monotonicity mean here, for a multivariate expression? > > > > Thanks, > > > > -- > > Raul > &g

Re: [Jprogramming] lp?

2023-04-05 Thread Raul Miller
What does monotonicity mean here, for a multivariate expression? Thanks, -- Raul On Wed, Apr 5, 2023 at 6:44 AM Elijah Stone wrote: > > I know not the first thing about linear programming or numerical optimisation, > but I have a problem which I think is related; can anyone point me in the >

Re: [Jprogramming] distance makes the heart grow fonder

2023-04-01 Thread Raul Miller
It's not really linebreak vs [ -- it's linebreak vs [. or [ depending on context, possibly with parenthesis in certain cases. That said, motivating examples are critical for any language changes, and I don't have any for this. -- Raul On Sat, Apr 1, 2023 at 11:35 AM Henry Rich wrote: > > When

Re: [Jprogramming] distance makes the heart grow fonder

2023-04-01 Thread Raul Miller
Control words also work as line separators. So introducing a no-op control word (perhaps a single letter followed by a dot) would scratch most of that itch. Making control words work outside of explicit definitions (either this single example, or maybe a more complete entourage) would require

Re: [Jprogramming] Strange error

2023-03-30 Thread Raul Miller
The procedure I have to go through, to execute the AIO installer J9.4_win.exe is this: The browser displays the message: "j9.4_win.exe isn't commonly downloaded. Make sure you trust j9.4_win.exe before you open it." And below that line is a "See more" link (or maybe pseudo-link -- it's blue).

Re: [Jprogramming] stdlib read text into boxes

2023-03-27 Thread Raul Miller
I think boxing each line and discarding the unwanted lines is a good approach here. For example: (#~ *@#@-.&(' ',TAB)@>)cutLF d That said, I guess you could do something like this: require'regex' ,d rxfrom~'^.*\S.*$' rxmatches d Or, equivalently: require'regex'

Re: [Jprogramming] Webview, isigraph, core, threads

2023-03-22 Thread Raul Miller
If only it were that simple. Sadly, Qt's design is such that all UI activity must happen on the main thread. https://doc.qt.io/qt-5/thread-basics.html Looking at how the system works, I believe that this was not the original plan, but instead was an organic response to some of the very

Re: [Jprogramming] Atn2 verb

2023-03-21 Thread Raul Miller
Yes. https://en.wikipedia.org/wiki/Atan2 -- Raul On Mon, Mar 20, 2023 at 8:31 PM Clifford Reiter wrote: > > Does atn2 differ from _3 ? > > _3 o. _ > > 1.5708 > > _3 o. __ > > _1.5708 > > _3 o. 0 > > 0 > > > > > On Mon, Mar 20, 2023 at 8:16 PM John Baker wrote: > > > While computing star

Re: [Jprogramming] Atn2 verb

2023-03-21 Thread Raul Miller
0j6 0 0 ":"1/:~(,.~ 12 o. j./"1)0 0-.~>,{,~ wrote: > > While computing star rise, transit and set times I encountered a need for an > atn2 verb. This is basically a tweaked arctan verb that handles ratios like > (arctan a%b) when a and b might be 0. Atn2 is in FORTRAN libraries. I ended > up

Re: [Jprogramming] IDC_* cursor codes

2023-03-20 Thread Raul Miller
open 'ide/qt/gl2' works. I do not know why open 'gl2' silently fails. -- Raul On Mon, Mar 20, 2023 at 5:05 PM Ed Gottsman wrote: > > Hi. If I’m reading the gl2 docs > (https://code.jsoftware.com/wiki/Guides/Window_Driver/gl2_Command_Reference) > correctly, I can review the IDC_ cursor

Re: [Jprogramming] whence 'foo upon thee'?

2023-03-18 Thread Raul Miller
I remember "foo" showing up a lot in some boston related contexts, and a quick web search finds: https://en.wikipedia.org/wiki/Foobar https://en.wikipedia.org/wiki/Ruby_Foo ... both of which sound plausible as influences. -- Raul On Sat, Mar 18, 2023 at 7:46 AM Elijah Stone wrote: > > The

Re: [Jprogramming] J shell scripts

2023-03-11 Thread Raul Miller
touching any part of the system as a whole (since it > is a third-party package manager). Users are expected to update their path > _once_ to include /opt/homebrew/bin, and can then pick up anything they > install through brew without additional effort. > > On Sat, 11 Mar 2023, Raul

Re: [Jprogramming] J shell scripts

2023-03-11 Thread Raul Miller
nstall time. Thanks, -- Raul On Sat, Mar 11, 2023 at 2:41 AM Elijah Stone wrote: > > I don't think anyone has proposed a tool like virtualenv, so I don't see how > that's relevant. And I don't see why we should make impositions on the way > anyone chooses to package j. > >

Re: [Jprogramming] J shell scripts

2023-03-10 Thread Raul Miller
gt; Some scripts developed on linux are distributed that use #!/bin/bash, and this > breaks on BSD systems because there is on bash in /bin; when those scripts use > #!/usr/bin/env bash instead, they work. > > On Fri, 10 Mar 2023, Raul Miller wrote: > > > > > /usr/bin/$name is the earlier

Re: [Jprogramming] J shell scripts

2023-03-10 Thread Raul Miller
In some systems, it is conventional to put binaries that did not > come with the system in /usr/local/bin, or in /opt; whereas, the existence of > /usr/bin/env is mandated by posix. We should not presume any more than we > need to about the way a user's system will be organised. > > On Fri, 10 Mar 2023

Re: [Jprogramming] J shell scripts

2023-03-10 Thread Raul Miller
ame reason). I therefore propose: > > 1. Rename jconsole to something which doesn't collide with anything heretofore > notable > > 2. Use #!/usr/bin/env that-something > > On Fri, 10 Mar 2023, Raul Miller wrote: > > > Perhaps, but I think it would be more useful to have a p

Re: [Jprogramming] J shell scripts

2023-03-10 Thread Raul Miller
l the interpreter to start ignoring the > > first line of a script if it starts with #!... > > > > On Thu, 9 Mar 2023, Raul Miller wrote: > > > >> The recent change in directory naming from j903 to j9.4 introduces an > >> interesting issue for shell scripts

Re: [Jprogramming] J shell scripts

2023-03-10 Thread Raul Miller
o tell the interpreter to start ignoring the first > line of a script if it starts with #!... > > On Thu, 9 Mar 2023, Raul Miller wrote: > > > The recent change in directory naming from j903 to j9.4 introduces an > > interesting issue for shell scripts on unix-like systems. > >

Re: [Jprogramming] J shell scripts

2023-03-10 Thread Raul Miller
under the > user's home folder? > eg. sudo ln -s $HOME/j9.4/bin/jconsole /usr/bin/ijconsole > > > > > > On Fri, Mar 10, 2023 at 1:29 AM Raul Miller wrote: > > > The recent change in directory naming from j903 to j9.4 introduces an > > interesting issue for shell scr

[Jprogramming] J shell scripts

2023-03-09 Thread Raul Miller
The recent change in directory naming from j903 to j9.4 introduces an interesting issue for shell scripts on unix-like systems. In J shell scripts, this works: #!/home/username/j903/bin/jconsole However, this fails with a spelling error: #!/home/username/j9.4/bin/jconsole Or, on OSX, the

Re: [Jprogramming] wd parameter delimiters

2023-03-08 Thread Raul Miller
I think you need to quote the html, either with balanced double quotes or with a leading asterisk (which extends to the end of the wd argument). For example: wd {{)n pc formname closeok; cc wv webview; set wv minwh 100 75; pshow; set wv html *Hello World! }} I hope this helps, --

Re: [Jprogramming] installation trouble

2023-03-03 Thread Raul Miller
The problem is this line of install-usr.sh: update-alternatives --install $BIN/ijconsole ijconsole $BIN/ijconsole-9.4 9.4 That final 9.4 is the priority of the alternative. It should probably be 904. (A higher priority alternative overrides a previous priority, and this script was probably

Re: [Jprogramming] j9.4.1 release is available

2023-03-02 Thread Raul Miller
nce improvement can be a > > game > > >> changer. The hobby horse is now a work horse. > > >> > > >> Improved error messages will be appreciated by new users, bu

  1   2   3   4   5   6   7   8   9   10   >