[EMAIL PROTECTED] wrote:
Message: 7
Date: Tue, 30 Sep 2008 17:15:53 -0400
From: "Roy A. Crabtree" <[EMAIL PROTECTED]>
Subject: Re: [Jprogramming] p.^:_1
To: "Programming forum" <[email protected]>
Message-ID:
<[EMAIL PROTECTED]>
Content-Type: text/plain; charset=ISO-8859-1
Agreed.
For example,
a) zero divide zero is an eigenstate summary-bound inverse of multiplication
by zero
b) imaginary numbers came about because of an imperfect inverse (roots)
c) *Negative* numbers may be regarded as an imperfect invrse extension to be
able to invert addition.
d) have you tried to invert abs()? Makes for an interesting thoguht
exercise:
abs() and similar functions could be inverted by saving the needed
information in a temporary array. For example:
abs1 =: 3 : 0
tmp =: 1 1 _1 {~ * y
| y
)
abs2 =: 3 : 0
tmp * y
)
abs =: abs1 :. abs2
>: &. abs i: 3
_4 _3 _2 1 2 3 4
to =: <. + i.@(>:&.abs)@-~ NB. Based on Ric Sherlock's verb
3 to _1
3 2 1 0 _1
3 to 3
3
ravel1 =: 3 : 0
tmp =: $ y
, y
)
ravel2 =: 3 : 0
tmp $ y
)
ravel =: ravel1 :. ravel2
3&|. &. ravel i.3 4
3 4 5 6
7 8 9 10
11 0 1 2
sort1 =: 3 : 0
tmp =: /:/: y
/:~ y
)
sort2 =: 3 : 0
tmp { y
)
sort =: sort1 :. sort2
qbf =: ;:'The quick brown fox jumps over the lazy dog'
'123456789'&(,&.>) &. sort qbf
+----+------+------+----+------+-----+----+-----+----+
|1The|8quick|2brown|4fox|5jumps|7over|9the|6lazy|3dog|
+----+------+------+----+------+-----+----+-----+----+
Can the domain of numbers be extended in such a way as to make this a
useful operation,
similar to imaginary/complex numbers?
How about transfinitesimals? Sets? Intervals?
The domain and i/rnage of the object space under consideration,
the functors involved, and the desired applicative domain
(what results make sense for the functor extensions proposed?)
are all important.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm