Hi,
I'm playing with this definition and noticed that if the argument was
scalar (if the term is correct) and more than 2 then it returns
strange result
i 1
┌─┐
│1│
└─┘
i 2
┌2──┐
│1 2│
└───┘
i 3
┌2──┐
│┌2──┐ ┌2──┐│
││1 2│ │1 3││
│└───┘ └───┘│
└∊──┘
i 4
Thanks for bringing this up and for the solution.
It is even more readable:
at ← { ⍵+(⍴⍵)↑(-χ)↑⍺ }
88 at[3 2] s44
Best,
Ala'a
On Thu, May 19, 2016 at 6:04 PM, Juergen Sauermann
wrote:
> Hi Christian,
>
> correct. In GNU APL you cannot use values in defined
Isn't it the same as using reshape instead?
3 0 2 ∘.⍴ 5 1 7
5 5 5 1 1 1 7 7 7
5 51 17 7
Best,
Ala'a
On Sat, May 14, 2016 at 10:31 PM, Xiao-Yong Jin wrote:
>
>> On May 14, 2016, at 7:51 AM, David Tran wrote:
>>
>> Hi,
>>
>>
t; Hi Ala,
>
> the allowed characters in variable names are defined in the ISO standard and
> √ is none of them. Unicode characters can be used inside strings, like in
>
> VAR ← '√'
>
> but not otherwise.
>
> /// Jürgen
>
>
>
> On 05/14/2016 12:27 PM, Ala'a Moham
Hi,
I'm trying to define user functions using some unicode characters, but
gnu-apl complains about the characters used not being from the defined
acceptable set:
√ ← {⍵ ⋆ ÷2}
Unknown APL character: √ (U+221A)
Non-APL character
∛ ← {⍵ ⋆ ÷3}
Unknown APL character: ∛ (U+221B)
Non-APL
TryAPL is powered by Dyalog APL and shows the same results as GNU APL
on the neg one case, as below:
http://tryapl.org/#?a=%28+/%u2364%AF1%293%204%u2374%u2373100
Ala'a
5
conan 4
apl -s -f fhist.apl 8901.96s user 5.78s system 99% cpu 2:28:38.61 total
On Sat, Sep 10, 2016 at 12:02 PM, Ala'a Mohammad <amal...@gmail.com> wrote:
> Thanks to all for the input,
>
> Replacing Find and Each OR with Match helped, now I'm parsing a 159K
>
desc 39 2⍴(⍪u),≢¨⊂⍨x[⍋x←u⍳w]
>
> Jay.
>
> On 12 September 2016 at 18:34, Ala'a Mohammad <amal...@gmail.com> wrote:
>>
>> Thanks for the alternative, I'd tried to run it, but got Rank Error
>>
>> RANK ERROR
>> λ1[1] λ←⍵[⍒⍵[;2];]
>> ^
g the last line with this? It runs in about 1 minute on my
> machine:
>
> desc 39 2⍴(⍪u),≢¨⊂⍨x[⍋x←u⍳w]
>
> Jay.
>
> On 11 September 2016 at 19:23, Ala'a Mohammad <amal...@gmail.com> wrote:
>>
>> Just an update as a reference, I'm now able to parse the big.txt file
>>
ntry 417
> world355
> project 286
> gutenberg262
> laws 233
> sir 176
> series 128
> sure 123
> sherlock 101
> ebook 85
> copyright 69
>
Hi,
I'm trying to create simple spell corrector (Norvig at
http://norvig.com/spell-correct.html) in APL.
I tried but stumbled upon the frequency/count stage and could not move
further. The stopper was either WS Full, or apl process killed. I'm
assuming the main issue is 'lack of experience with
Thanks to all!
Now unique went from 2 min and 36 sec down to 10 sec, in the
spellcheck script.
Ala'a
On Sat, Sep 17, 2016 at 4:43 PM, Juergen Sauermann
wrote:
> Hi Xtian,
>
> thanks, fixed in SVN 796.
>
> /// Jürgen
>
>
> On 09/17/2016 05:12 AM, Christian Robert
Hi,
Some languages support short circuiting evaluation for example in Python
known([word]) or known(edits1(word)) or known(edits2(word)) or [word]
Returns the first part ( 'or' is the delimiter) that return a True
(not False of which is the empty {}, others are None 0 "" () [])
Do I need to
Hi,
I previously had similar cases, but could not understand them. since
they are worknig for functions, but not lambdas, and assumed that is
the case.
Now, after reading "This is normal APL and holds for all niladic
functions and not only for niladic lambdas.", I'm more confused. if
I'm not
On Tue, Oct 18, 2016 at 3:42 PM, Jay Foad wrote:
> ⍋⍋'GNUAPL'
Great! Thanks.
Hi,
Playing with partial enclose (formally enclose with axis) as follows
gave me the following segfault
A←2 3 4⍴⍳24
A
1 2 3 4
5 6 7 8
9 10 11 12
13 14 15 16
17 18 19 20
21 22 23 24
⊂[3 2 2]A
SEGMENTATION FAULT
On Wed, Oct 26, 2016 at 6:55 PM, Juergen Sauermann
wrote:
> ⎕FX 'Z→time' 'Z←⎕TS'
Hi Jurgen,
I assume you meant:
⎕FX 'Z←time' 'Z←⎕TS'
not
⎕FX 'Z→time' 'Z←⎕TS'
which gives value error
Regards,
Ala'a
I was trying to assign order to a word letters for example 'zach' is
312, I got it finally, for example for 'maine'
abc←'abcdefghijklmnopqrstuvwxyz'
1+(⌽⍳5)[(⍋abc⍳'maine')]
4 1 3 5 2
But I got the following failing assertion and wanted to check if
something related to my code or the
X
>
> you might consider using something like
>
> 0 ⌈ 26 ⌊ ¯97 + ⎕UCS XXX
>
> which will decrease your execution time from O((⍴A)×(⍴B)) down to O(⍴B).
>
> /// Jürgen
>
>
>
> On 10/16/2016 04:51 PM, Ala'a Mohammad wrote:
>
> I was trying to assign order
Hi,
I was playing with the sum of the series 1/3, 1/9, 1/27 ..etc
(1÷3⋆⍳x), and found that If I'm using the rationals experimental
feature (⎕ps ← 1 0), then it the following were found:
1)
1÷3⋆⍳5
1÷3 1÷9 1÷27 1÷81 1÷243
+/1÷3⋆⍳39
2026277576509488133÷4052555153018976267
0.67
3×1÷3
1
5×1÷3
1.7
6×1÷3
2
1×1÷2
0.5
2×1÷2
1
Regards,
Ala'a
On Mon, Aug 14, 2017 at 11:12 PM, Ala'a Mohammad <amal...@gmail.com> wrote:
> Hi,
>
> I was playing with the sum of the series 1/3, 1/9, 1/27 ..etc
> (1÷3⋆⍳x), and found
Hi Jürgen,
I was playing with experimental support for rational numbers and found
that result was converted to float while using dyadic maximum,
minimum, even though I did not use the monadic +
(1÷3) ⌈ (3÷4)
0.75
(1÷3) ⌊ (3÷4)
0.33
Is this the intended display?
Also by
Hi Jürgen,
Thanks go to you for the prompt response. I do really appreciate it.
Regards,
Ala'a
On Sat, Aug 12, 2017 at 12:26 AM, Juergen Sauermann
<juergen.sauerm...@t-online.de> wrote:
> Hi Ala'a,
>
> thanks, fixed in SVN 993.
>
> /// Jürgen
>
>
> On 08/11/2017
Hi,
Another two ways, Not as compact or optimized, but generate the same output
1)
G groups, C categories, and S strings
G←(⍴∪C)⍴⊂⍬ ◊ C {G[⍺]←⊂(⊃G[⍺]),⊂⍵}¨S ◊ G
I forgot how to suppress the middle output
or in a function
∇ groups ← categories group items
groups ← (⍴∪categories)⍴⊂⍬
Oops, the second solution should be
(1+c[x]) ⊂ s[x←⍋c]
Ala'a
On Fri, Jul 7, 2017 at 1:38 AM, Ala'a Mohammad <amal...@gmail.com> wrote:
> Hi,
> Another two ways, Not as compact or optimized, but generate the same output
> 1)
> G groups, C categories, and S strings
>
> G
Hi,
Is it possible to control when the interpreter uses the 'E' or display
the number without it? I know of quad print precision, but it did not
affect the printing of notation used for displaying these numbers when
I played with it.
I'm asking this because on one side I understand that this
Hi,
I'm trying to edit a function but got the following trace
==
Assertion failed: items
in Function: at
in file: ../Simple_string.hh:276
Call stack:
-- Stack
for Elias to look into. Seems like some
>> Simple_string is corrupted.
>>
>> /// Jürgen
>>
>>
>> On 07/30/2017 09:40 PM, Ala'a Mohammad wrote:
>>
>> Hi,
>>
>> I'm trying to edit a function but got the following trace
>>
>>
>
Hi,
An example where the display is showing 'neg' when the number is positive.
⎕ps ← 1 0
+/2÷⍳1
¯227306580757051271÷18407405366253039616
⍎⍕+/2÷⍳1
¯0.01234864861
⍝ or
¯227306580757051271÷18407405366253039616
¯0.01234864861
++/2÷⍳1
5.778191391
Hi,
I do not know if this is the same cause, but the assertion seems to be the same
in a new session do the following
- write an incorrect name like 'x.y'
- edit a function like 'z'
- save the function
- edit the z function again, and you get the failed assertion
I'm running the latest APL
do_Assert(char const*, char const*, char const*, int)
SI stack:
==
terminate called after throwing an instance of 'ErrorCode'
Process apl aborted
On Mon, Aug 28, 2017 at 10:10
Using a separate function for rounding (from Dyalog book with re
formatting), thus usable in other contexts.
∇R← N round V;S
⍝ N: number of decimals
⍝ V: value to be rounded
S←10⋆N ⍝ Scale
R←(⌊.5+V×S)÷S ⍝ Result
∇R←gdist M; G;F;S;P
⍝ R: Result
⍝ M: numerical grades
G ← 'ABCDF' ⍝ G:
Hi,
This may be related:
https://www.dyalog.com/blog/2015/01/cholesky-decomposition/
HiH.
Regards,
Ala'a
On Wed, Apr 29, 2020 at 12:24 AM Rowan Cannaday wrote:
> Is anybody familiar with the QR algorithm, or the notation used in Golub &
> Van Loan's book "Matrix Computations"?
>
> I am
plicitly
> performed, some authors, for instance Watkins,[8]
> <https://en.m.wikipedia.org/wiki/QR_algorithm#cite_note-8> suggested
> changing its name to *Francis algorithm"*
>
> *https://en.wikipedia.org/wiki/QR_algorithm
> <https://en.wikipedia.org/wiki/QR_algorith
Hi,
Sorry, I did not dive very deep, but it seems that the Tilde ~ with zero
(0) is the point where it choke. If other values substituted, then it
generate output.
this works
0~⍨?⍳3600
but for example this does not work
0~⍨?⍳3601
HiH
regards,
On Thu, Apr 30, 2020 at 10:41 PM Dr. Jürgen
Hi,
I suspect It has something to do with Zero value.
Kacper example also produce output when Zero is replaced with other values.
HiH
Regards,
On Thu, Apr 30, 2020 at 11:12 PM Kacper Gutowski wrote:
> On Thu, Apr 30, 2020 at 08:14:46PM +0200, Dr. Jürgen Sauermann wrote:
> >Could you please
Hi,
or in other way, not elegant but I assume from the light testing it is
working
∇r←grade marks
code←'FDCCBBAA'
r← code[⌊(4+marks)÷5]
grade 10 10⍴⍳100
FF
FF
FF
FF
FF
FF
FD
CC
BB
AA
HiH
Regards,
Hi there!
You may find something helpful/useful in a previous discussion about the
similar program
https://lists.gnu.org/archive/html/bug-apl/2016-09/msg00026.html
Hope it helps.
Regards,
Ala'a
On Tue, Dec 28, 2021 at 11:09 PM Blake McBride wrote:
> Hi Jürgen,
>
> First, to be sure you know
Wish you full recovery Jürgen!
On Sun, Jan 22, 2023 at 5:07 PM Dr. Jürgen Sauermann <
mail@jürgen-sauermann.de> wrote:
> Gentlemen,
>
> I am sorry for not responding earlier to any emails to bug-apl@gnu.org.
>
> I was unexpectedly taken offline after new year and I am
> now online again,
Hi Garjola,
The people had already mentioned the books and gave suggestions which
are very useful.
I'd like to mention the following tripping points (which I fall for),
to keep in mind which minimize confusion:
- Gnu APL is in implementation of ISO/IEC 13751:2001 (and is neither
APL\360 nor
40 matches
Mail list logo