RE: [Jgeneral] significant digits

2006-07-02 Thread Miller, Raul D
Randy MacDonald wrote:
> Doesn't sound to me like there's much meat in those kind
> of functions.

Sure, and I think I used the word "trivially" when I 
started talking about this subtopic (rather than "meaty").

My point was that allowing something to be classified as
a function by introducing sufficient arguments to turn it
into a function is a trivial (non-meaty, even -- nice turn
of phrase) approach.

> I'll admit it has some use.

It does.

Then again, it's not what people would normally think is meant,
in discussions about what is a function, and what is not, unless
this aspect of introducing extra parameters was fully specified.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-02 Thread John Randall
Randy MacDonald wrote:
> Hello Raul;
>
> Doesn't sound to me like there's much meat in those kind of functions. It
> looks like "just enough existence to be useful, like the implicit function
> idea in calculus.
>

I agree that implicit functions as encountered in calculus are not very
useful.  The main justification for including them is that they arise as
solutions of separable differential equations.

The implicit function theorem is very important in differential topology,
however: it gives the existence of local coordinates.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-02 Thread Randy MacDonald

Hello Raul;

Doesn't sound to me like there's much meat in those kind of functions. It 
looks like "just enough existence to be useful, like the implicit function 
idea in calculus.


I'll admit it has some use.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.66.82/
-(INTP){ gnat }-

- Original Message - 
From: "Miller, Raul D" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Sunday, July 02, 2006 9:22 AM
Subject: RE: [Jgeneral] significant digits


Randy MacDonald wrote:

I don't see how you say Y is a function of X,Y.


  X]Y
Y


Is it: once you know x in X, and y in Y, you know y?


Yes.

--
Raul


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-07-02 Thread Miller, Raul D
Randy MacDonald wrote:
> I don't see how you say Y is a function of X,Y.

   X]Y
Y

> Is it: once you know x in X, and y in Y, you know y?

Yes.

-- 
Raul


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-02 Thread John Randall
Any relation can be represented as a function, for example as its
characteristic function.  But this function is not the same as the
original relation.

Describing functions as a special case of relations is important in
math, because it shows that functions is no deeper than sets.

Mathematical functions in computer science are sometimes called pure
functions: they always give the same result for the same arguments,
and have no side effects. Knowing a function is a pure function means
that it can be memoized and lazily evaluted.

Functions like ? are not pure functions: they depend on some state
which is hidden in the sense that it does not appear in the function
arguments.  Input functions are even worse unless you assume that the
input is supplied with the program, and so can be regarded as part of
the program state.  This makes sense for batch jobs but not
interactive programs.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread Randy MacDonald

Hello Raul;

I don't see how you say Y is a function of X,Y. Is it: once you know x in 
X, and y in Y, you know y?



|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.170/
-(INTP){ gnat }-

- Original Message - 
From: "Miller, Raul D" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Saturday, July 01, 2006 2:06 PM
Subject: RE: [Jgeneral] significant digits


Randy MacDonald wrote:

Do you have a more detailed version of that statement? I can
see how ?(arg,seed) is a function but I can't, in general,
see how foo(arg,range) would be a function, short of making
the range argument a function of the argument:

foo(arg,bar(arg))

which presupposes bar, which I don't see as a given.


Consider the relationship x,y where x is 0 or 1 and y is
0 or 1.

Then, y is not a function of x, but y is a function of x and y.

Consider the relationship X,Y where x is any real number and
y is any real number.  Then, Y is a function of X,Y, even though
Y is not a function of X.

Etc.

Note that there is no need to have a function bar(x) for this
condition to hold.

If this still does not make sense to you, I challenge you to
come up with an example relationship which cannot be made into
a function using this approach -- I'll describe the trivial
function for you.

--
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-07-01 Thread Miller, Raul D
Randy MacDonald wrote:
> Do you have a more detailed version of that statement? I can
> see how ?(arg,seed) is a function but I can't, in general,
> see how foo(arg,range) would be a function, short of making
> the range argument a function of the argument:
> 
> foo(arg,bar(arg))
> 
> which presupposes bar, which I don't see as a given.

Consider the relationship x,y where x is 0 or 1 and y is
0 or 1.

Then, y is not a function of x, but y is a function of x and y.

Consider the relationship X,Y where x is any real number and
y is any real number.  Then, Y is a function of X,Y, even though
Y is not a function of X.

Etc.

Note that there is no need to have a function bar(x) for this
condition to hold.

If this still does not make sense to you, I challenge you to
come up with an example relationship which cannot be made into
a function using this approach -- I'll describe the trivial
function for you.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread Randy MacDonald

Hello Raul;

Do you have a more detailed version of that statement? I can see how 
?(arg,seed) is a function but I can't, in general, see how foo(arg,range) 
would be a function, short of making the range argument a function of the 
argument:


foo(arg,bar(arg))

which presupposes bar, which I don't see as a given.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.170/
-(INTP){ gnat }-

- Original Message - 
From: "Miller, Raul D" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Saturday, July 01, 2006 12:32 PM
Subject: RE: [Jgeneral] significant digits


Randy MacDonald wrote:

Actually ? _is_ a function. Some of its arguments are hidden.


Then, trivially, all relations are functions -- simply include
the range as a hidden part of the domain.

--
Raul


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-07-01 Thread Miller, Raul D
Donna L.Y. wrote:
> On 30-Jun-06, at 11:47 PM, Miller, Raul D wrote:
> > There, I'm trying to draw a contrast between "function"
> > and "concept".
>
> Can you please explain a little more about your concept of concept  
> and the function of function and the function of concept and the  
> concept of function and could you please define your terms ...

This looks like a reasonable description of what "function" means:
http://www.purplemath.com/modules/fcns.htm

This looks like a reasonable description of what "concept" means:
http://en.wikipedia.org/wiki/Concept

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-07-01 Thread Miller, Raul D
Randy MacDonald wrote:
> Actually ? _is_ a function. Some of its arguments are hidden.

Then, trivially, all relations are functions -- simply include
the range as a hidden part of the domain.

-- 
Raul


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread Randy MacDonald

Hello Donna;

Rest assured, I am not annoyed.

The SPCDH acronym is actually used? I thought I just made that up.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.170/
-(INTP){ gnat }-

- Original Message - 
From: "dly" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Saturday, July 01, 2006 2:26 AM
Subject: Re: [Jgeneral] significant digits


In the appendix of The Ghost in the Machine (1967 Koestler) is a
prediction that academics would say of this thesis — "Mr Koestler, I
am afraid, is flogging a dead horse" and he inferred the existence of
the Society for the Prevention of Cruelty to Dead Horses (SPCDH) who
were on a mission to discourage in depth discussion of fine points
and in general to prevent the flogging of dead horses.

I hope my sometimes facetious commentary brings laughter rather than
annoyance.

Donna
[EMAIL PROTECTED]



On 1-Jul-06, at 3:57 AM, Randy MacDonald wrote:

Personally, I consider beating a dead horse an act of futility  rather 
than cruelty, but I hope you don't consider these forums, a  place for all 
things J, to be an SPCDH


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread Randy MacDonald

Donna;

Surely there's a more concise way to express your point?


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.170/
-(INTP){ gnat }-

- Original Message - 
From: "dly" <[EMAIL PROTECTED]>

To: "dly" <[EMAIL PROTECTED]>
Cc: "General forum" 
Sent: Saturday, July 01, 2006 1:41 AM
Subject: Re: [Jgeneral] significant digits




On 1-Jul-06, at 4:15 AM, dly wrote:

Converted to plain text

On 30-Jun-06, at 11:47 PM, Miller, Raul D wrote:


There, I'm trying to draw a contrast between "function" and
"concept".




Can you please explain a little more about your concept of concept  and 
the function of function and the function of concept and the  concept of 
function and could you please define your terms and the  domains in which 
they apply because I find this ( and I am sure I  could find more):


Words and phrases matching your pattern:
(We're restricting the list to terms we think are related to  function, 
and sorting by relatedness.)


1. functional
2. work
3. office
4. exponential
5. run
6. serve
7. map
8. role
9. officiate
10. operate
11. go
12. use
13. event
14. functioning
15. functionless
16. part
17. routine
18. subprogram
19. functions
20. functioned
21. mathematical function
22. procedure
23. purpose
24. social
25. subroutine
26. act
27. cut
28. secant
29. sine
30. apparatus
31. cosecant
32. cosine
33. cotangent
34. malfunction
35. mapping
36. trigonometric function
37. unit
38. area
39. capacity
40. circular function
41. correspondence
42. derivative
43. differential
44. duty
45. inverse function
46. operator
47. activity
48. argument
49. domain
50. judicial
51. place
52. play
53. range
54. root
55. threshold function
56. transformation
57. wall
58. behave
59. chain rule
60. constitute
61. continuous
62. control
63. exercise
64. exponential function
65. frequency
66. functionalism
67. particle
68. perform
69. presidency
70. sex
71. tangent
72. action
73. biostatics
74. collapse
75. committee
76. defective
77. discharge
78. discontinuous
79. double
80. function word
81. homogeneous
82. make
83. metric
84. official
85. on
86. order
87. preposition
88. psychurgy
89. reaction
90. referee
91. response
92. service
93. special
94. stead
95. substantive
96. through
97. tissue
98. weak
99. -ure
100. act as



Words and phrases matching your pattern:
(We're restricting the list to terms we think are related to concept,  and 
sorting by relatedness.)


1. determination
2. notion
3. abstraction
4. idea
5. abstract
6. conception
7. construct
8. quantity
9. conceptualize
10. category
11. law
12. theory
13. conceptuality
14. conceptualization
15. hypothesis
16. law of nature
17. possibility
18. beau ideal
19. conceit
20. fact
21. imaginary being
22. imaginary creature
23. intention
24. number
25. ontological argument
26. percept
27. reify
28. rule
29. superstructure
30. thought
31. atomic structure
32. attribute
33. benefit album
34. body image
35. conceptualisation
36. dimension
37. divine right of kings
38. division
39. dualism
40. figure-ground
41. fourth dimension
42. generalized other
43. illusion
44. infinity
45. kierkegaard
46. lexicalized concept
47. linguistic rule
48. manifoldness
49. natural law
50. objective
51. part
52. place
53. pluralism
54. prime ideal
55. property
56. regulation
57. section
58. signified
59. teacher
60. tenor
61. tensor
62. transcendent
63. tribute album
64. truth
65. uniformitarianism
66. whole
67. avatar
68. ideogram
69. image
70. notional
71. thing
72. universal
73. analysis
74. coach
75. conceive
76. conceptual
77. dialectic
78. embodiment
79. extension
80. generalization
81. hypostatize
82. incarnation
83. innovation
84. intension
85. more
86. nietzsche
87. passion
88. perception
89. point
90. symbol
91. synthesis
92. zoroastrianism
93. -ing
94. .38 special (band)
95. a passion play
96. abolitionism
97. absolute infinite
98. absolutist
99. abstract noun
100. accounting equation


Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 11:47 PM, Miller, Raul D wrote:



There, I'm trying to draw a contrast between "function" and
"concept".



--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread Don Guinn
Concepts are sometimes difficult to get across and sometimes it is 
necessary to present them in ways that when taken out of context can 
mis-represent or possibly be completely untrue. For example, take the 
first part of the definition of "operator" from Wikipedia.



 Operator


  From Wikipedia, the free encyclopedia

Jump to: navigation , 
search 


   This article is about operators in mathematics
   . For other uses, see
   operator (disambiguation)
   .

In mathematics , an operator 
is a function , 
usually of a special kind depending on the topic.

. . .

Looking at "function" from Wikipedia it says ". . . In mathematics, a 
function relates each of its inputs to exactly one output. . . ."


From MathWorld, "A multivalued function, also known as a 
multiple-valued function (Knopp 1996, part 1 p. 103), is a "function" 
that assumes two or more distinct values in its range 
 for at least one point in its 
domain . While these 
"functions" are not functions 
 in the normal sense of 
being one-to-one  or 
many-to-one , the usage 
is so common that there is no way to dislodge it. When considering 
multivalued functions, it is therefore necessary to refer to usual 
"functions" as single-valued functions 
. . . ."


Do these definitions conflict or not? How can the term"multi-valued 
function" exist if a function can only be single valued? They are both 
are trying to present a concept. Is "square root" single-valued? It 
depends. In the domain of natural numbers it is. In the domain of 
integers it is not.


Gosh! I'm not sure where I'm trying to go with this. But it seems that 
this thread is getting hung up on the specifics of definitions rather 
than trying to grasp the concepts they are trying to convey.


dly wrote:


I am trying to learn J terms

If J terms can actually be used to describe J technically why not use  
them?


There are not enough forums to have special conversations for native  
speakers of APL, C++, Java, Excell Spreadsheet users, Dutch, French,  
Cantonese, Polish, the 820 listed living languages of Papua New  
Guinea, German...


function, operator, relation...

. . .



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread John Randall
dly wrote:
>Why not use the J term VERB?

"To avoid ambiguity due to the two uses of the term operator in
mathematics (for both a function and Heaviside operator) I usually use on
the terms adverb and conjunction, but continue to use either function or
verb, list or vector, and table or matrix, as seems appropriate."

Ken Iverson, A Personal View of APL

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-07-01 Thread Björn Helgason

Flogging a dead horse means doing something that will not get you anything -
completely pointless

Contrasting to flogging a horse might get it to move and preferably in the
the right direction and/or do what you want it to do

2006/7/1, dly <[EMAIL PROTECTED]>:


In the appendix of The Ghost in the Machine (1967 Koestler) is a
prediction that academics would say of this thesis — "Mr Koestler, I
am afraid, is flogging a dead horse" and he inferred the existence of
the Society for the Prevention of Cruelty to Dead Horses (SPCDH) who
were on a mission to discourage in depth discussion of fine points
and in general to prevent the flogging of dead horses.

I hope my sometimes facetious commentary brings laughter rather than
annoyance.

Donna
[EMAIL PROTECTED]



On 1-Jul-06, at 3:57 AM, Randy MacDonald wrote:

> Personally, I consider beating a dead horse an act of futility
> rather than cruelty, but I hope you don't consider these forums, a
> place for all things J, to be an SPCDH

--
For information about J forums see http://www.jsoftware.com/forums.htm





--
Björn Helgason, Verkfræðingur
Fugl&Fiskur ehf, Þerneyjarsund 23,
Skype: gosiminn, gsm: +3546985532
801 Grímsnes ,t-póst: [EMAIL PROTECTED]
Landslags og skrúðgarðagerð, gröfuþjónusta
http://groups.google.com/group/J-Programming


Tæknikunnátta höndlar hið flókna, sköpunargáfa er meistari einfaldleikans

góður kennari getur stigið á tær án þess að glansinn fari af skónum
 /|_  .---.
,'  .\  /  | Með léttri lund verður|
,--'_,'   | Dagurinn í dag |
   /   /   | Enn betri en gærdagurinn  |
  (   -.  |`---'
  | ) |(\_ _/)
 (`-.  '--.)   (='.'=)
  `. )'(")_(")
--
For information about J forums see http://www.jsoftware.com/forums.htm

Re: [Jgeneral] significant digits

2006-06-30 Thread dly
In the appendix of The Ghost in the Machine (1967 Koestler) is a  
prediction that academics would say of this thesis — "Mr Koestler, I  
am afraid, is flogging a dead horse" and he inferred the existence of  
the Society for the Prevention of Cruelty to Dead Horses (SPCDH) who  
were on a mission to discourage in depth discussion of fine points  
and in general to prevent the flogging of dead horses.


I hope my sometimes facetious commentary brings laughter rather than  
annoyance.


Donna
[EMAIL PROTECTED]



On 1-Jul-06, at 3:57 AM, Randy MacDonald wrote:

Personally, I consider beating a dead horse an act of futility  
rather than cruelty, but I hope you don't consider these forums, a  
place for all things J, to be an SPCDH


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Bill Harris
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

dly <[EMAIL PROTECTED]> writes:

> If J terms can actually be used to describe J technically why not use
> them?

Donna, that's a good question.  Some (e.g., Roger) seem to do that more
than others.  When I first learned a bit of APL, it was from Heller's
book on digital systems design.  As a result, I used APL for a couple of
years after college as my digital design language, even though I didn't
ever use an APL interpreter until over 10 years later.

I think J would be an excellent tool for doing the same thing.  I
suspect part of the problem is that J seems more complex than the APL of
1970, and so there's more risk for someone at my level to write nonsense
in J unless I verify it on a computer.  Having thought about that for
some time, though, I have begun to use J as a note-taking language when
it seems appropriate.

Thanks for bringing it up!

Bill
- -- 
Bill Harris  http://facilitatedsystems.com/weblog/
Facilitated Systems  Everett, WA 98208 USA
http://facilitatedsystems.com/  phone: +1 425 337-5541
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.3 (MingW32)
Comment: For more information, see http://www.gnupg.org

iD8DBQFEpf0H3J3HaQTDvd8RAjxFAKCEdGhlpVMsbpgB+RUpPd+to+6Z2gCfb7AG
QfqLLU+CPRxenK+u6GTl3PE=
=ddHU
-END PGP SIGNATURE-

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly


On 1-Jul-06, at 4:15 AM, dly wrote:

Converted to plain text

On 30-Jun-06, at 11:47 PM, Miller, Raul D wrote:


There, I'm trying to draw a contrast between "function" and
"concept".




Can you please explain a little more about your concept of concept  
and the function of function and the function of concept and the  
concept of function and could you please define your terms and the  
domains in which they apply because I find this ( and I am sure I  
could find more):


Words and phrases matching your pattern:
(We're restricting the list to terms we think are related to  
function, and sorting by relatedness.)


1. functional
2. work
3. office
4. exponential
5. run
6. serve
7. map
8. role
9. officiate
10. operate
11. go
12. use
13. event
14. functioning
15. functionless
16. part
17. routine
18. subprogram
19. functions
20. functioned
21. mathematical function
22. procedure
23. purpose
24. social
25. subroutine
26. act
27. cut
28. secant
29. sine
30. apparatus
31. cosecant
32. cosine
33. cotangent
34. malfunction
35. mapping
36. trigonometric function
37. unit
38. area
39. capacity
40. circular function
41. correspondence
42. derivative
43. differential
44. duty
45. inverse function
46. operator
47. activity
48. argument
49. domain
50. judicial
51. place
52. play
53. range
54. root
55. threshold function
56. transformation
57. wall
58. behave
59. chain rule
60. constitute
61. continuous
62. control
63. exercise
64. exponential function
65. frequency
66. functionalism
67. particle
68. perform
69. presidency
70. sex
71. tangent
72. action
73. biostatics
74. collapse
75. committee
76. defective
77. discharge
78. discontinuous
79. double
80. function word
81. homogeneous
82. make
83. metric
84. official
85. on
86. order
87. preposition
88. psychurgy
89. reaction
90. referee
91. response
92. service
93. special
94. stead
95. substantive
96. through
97. tissue
98. weak
99. -ure
100. act as



Words and phrases matching your pattern:
(We're restricting the list to terms we think are related to concept,  
and sorting by relatedness.)


1. determination
2. notion
3. abstraction
4. idea
5. abstract
6. conception
7. construct
8. quantity
9. conceptualize
10. category
11. law
12. theory
13. conceptuality
14. conceptualization
15. hypothesis
16. law of nature
17. possibility
18. beau ideal
19. conceit
20. fact
21. imaginary being
22. imaginary creature
23. intention
24. number
25. ontological argument
26. percept
27. reify
28. rule
29. superstructure
30. thought
31. atomic structure
32. attribute
33. benefit album
34. body image
35. conceptualisation
36. dimension
37. divine right of kings
38. division
39. dualism
40. figure-ground
41. fourth dimension
42. generalized other
43. illusion
44. infinity
45. kierkegaard
46. lexicalized concept
47. linguistic rule
48. manifoldness
49. natural law
50. objective
51. part
52. place
53. pluralism
54. prime ideal
55. property
56. regulation
57. section
58. signified
59. teacher
60. tenor
61. tensor
62. transcendent
63. tribute album
64. truth
65. uniformitarianism
66. whole
67. avatar
68. ideogram
69. image
70. notional
71. thing
72. universal
73. analysis
74. coach
75. conceive
76. conceptual
77. dialectic
78. embodiment
79. extension
80. generalization
81. hypostatize
82. incarnation
83. innovation
84. intension
85. more
86. nietzsche
87. passion
88. perception
89. point
90. symbol
91. synthesis
92. zoroastrianism
93. -ing
94. .38 special (band)
95. a passion play
96. abolitionism
97. absolute infinite
98. absolutist
99. abstract noun
100. accounting equation


Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 11:47 PM, Miller, Raul D wrote:



There, I'm trying to draw a contrast between "function" and
"concept".



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly
The special characters are available to me in a character palette  
with MAC Mail.  I am not sure what MS or other mail might have let  
alone hotmail if you just use it on the Web.  Sometimes the  
characters seem to make it into plain text and other time not.  I  
have a global setting on my computer for Canadian English and I am  
not sure if that is why I get odd characters (glyphs) sometimes.  In  
your signature box for example I see



|\/|
I am not sure how this maps back for you but I get a symbol that  
looks like a deleted W


This is where Roy complained of a Thorn I think

I hope you don't think I omitted to think of Icelandic speakers, they  
where covered under the...


Donna
[EMAIL PROTECTED]



On 1-Jul-06, at 4:08 AM, Randy MacDonald wrote:


Hi Donna;

There seems to be room for Icelandic speakers.

I find that the vagaries of English et al, can be remedied by  
phrasing things directly in J, much like having a piano present can  
facilitate a discussion of a musical subject.


One question: how did you get that single symbol for <- , or those  
Greek characters from an earlier post?


-- 
--

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're  
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP) 
{ gnat }-


- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Saturday, July 01, 2006 12:44 AM
Subject: Re: [Jgeneral] significant digits


I am trying to learn J terms

If J terms can actually be used to describe J technically why not use
them?

There are not enough forums to have special conversations for native
speakers of APL, C++, Java, Excell Spreadsheet users, Dutch, French,
Cantonese, Polish, the 820 listed living languages of Papua New
Guinea, German...

function, operator, relation...

Users/sid/j504/system/extras/help/primer/terminology.htm
. . . One problem it deals with is the plethora of related, but
subtly different, uses of traditional terms in math and numerous
programming languages. For example: function, subfunction, operator,
program, routine, and subroutine are all used in slightly different
ways in different programming languages. Rather than inherit this
confusion, J adopts its own terms, and defines them precisely within
its context.

Donna
[EMAIL PROTECTED]




On 1-Jul-06, at 3:22 AM, Randy MacDonald wrote:


Hello Donna;


Why not use the J term VERB?


I suspect it is a first-language-APL thing. function/verb are  
interchangeable to me. To insist on one term over another is a bit  
"Academie Française" to me.


many

Why not...


I'm seeing this is as you saying "this also works" my first   
impression was in error. Never mind.
- 
- --

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what  
you're  doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP)  
{ gnat }-



- 
-
For information about J forums see http://www.jsoftware.com/ 
forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Randy MacDonald

Hi Donna;

There seems to be room for Icelandic speakers.

I find that the vagaries of English et al, can be remedied by phrasing 
things directly in J, much like having a piano present can facilitate a 
discussion of a musical subject.


One question: how did you get that single symbol for <- , or those Greek 
characters from an earlier post?



|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP){ gnat }-

- Original Message - 
From: "dly" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Saturday, July 01, 2006 12:44 AM
Subject: Re: [Jgeneral] significant digits


I am trying to learn J terms

If J terms can actually be used to describe J technically why not use
them?

There are not enough forums to have special conversations for native
speakers of APL, C++, Java, Excell Spreadsheet users, Dutch, French,
Cantonese, Polish, the 820 listed living languages of Papua New
Guinea, German...

function, operator, relation...

Users/sid/j504/system/extras/help/primer/terminology.htm
. . . One problem it deals with is the plethora of related, but
subtly different, uses of traditional terms in math and numerous
programming languages. For example: function, subfunction, operator,
program, routine, and subroutine are all used in slightly different
ways in different programming languages. Rather than inherit this
confusion, J adopts its own terms, and defines them precisely within
its context.

Donna
[EMAIL PROTECTED]




On 1-Jul-06, at 3:22 AM, Randy MacDonald wrote:


Hello Donna;


Why not use the J term VERB?


I suspect it is a first-language-APL thing. function/verb are 
interchangeable to me. To insist on one term over another is a bit 
"Academie Française" to me.


many

Why not...


I'm seeing this is as you saying "this also works" my first  impression 
was in error. Never mind.
-- 
--

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're  doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP) 
{ gnat }-



--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Randy MacDonald

Hello Raul;

Actually ? _is_ a function. Some of its arguments are hidden.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP){ gnat }-

- Original Message - 
From: "Miller, Raul D" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Friday, June 30, 2006 8:47 PM
Subject: RE: [Jgeneral] significant digits


Donna L.Y. wrote:

On 30-Jun-06, at 6:28 PM, Miller, Raul D wrote:
> J's %: is a function, it's not the concept "square root".

Why not use the J term VERB?


Because that describes a different concept.

J's roll (?) is an example of a verb that is not a function:
  ?9
0
  ?9
5

Also, if it matters, adverbs and conjunctions can be functions,
even though they are not verbs.


Why does the definition of monadic %: say Square Root but you say
 it is not the concept of "square route"?


There, I'm trying to draw a contrast between "function" and
"concept".


Why not include the result


That ground had already been covered.

--
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Randy MacDonald

Hello Donna;

Personally, I consider beating a dead horse an act of futility rather than 
cruelty, but I hope you don't consider these forums, a place for all things 
J, to be an SPCDH, nor gang-up-on-Donna forums. I hope you are not finding a 
snobbish towards beginners attitude (like I have found in the beginning-perl 
Yahoo group)


There is nothing in your posts that the reader assuming you have the best 
intentions doesn't fix. I mentioned this in a previous post about your 
prefixing sentences "Why not..."


Sometimes making that assumption is hard work, and the power of J has made 
hard work a stranger in thes parts.  I, for one, look forward to reading 
your posts. Please continue at your pleasure.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP){ gnat }-

- Original Message - 
From: "dly" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Friday, June 30, 2006 8:20 PM
Subject: Re: [Jgeneral] significant digits


Perhaps I am unaware of the actual purpose of the J forums and  Jgeneral 
in particular.  Can someone fill me in?


After each post I seem to be reprimanded for what I have said.

I started this subject--significant digits to explore some of the  ways 
precision was reflected in J


Now I am told, if I don't understand the post thats too bad for me.

Sometimes it feels like conversing with the society for the  prevention of 
cruelty to dead horses.


Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 10:43 PM, Eldon Eller wrote:


so maybe I am beating a dead horse.


--
For information about J forums see http://www.jsoftware.com/forums.htm 



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly

I am trying to learn J terms

If J terms can actually be used to describe J technically why not use  
them?


There are not enough forums to have special conversations for native  
speakers of APL, C++, Java, Excell Spreadsheet users, Dutch, French,  
Cantonese, Polish, the 820 listed living languages of Papua New  
Guinea, German...


function, operator, relation...

Users/sid/j504/system/extras/help/primer/terminology.htm
. . . One problem it deals with is the plethora of related, but  
subtly different, uses of traditional terms in math and numerous  
programming languages. For example: function, subfunction, operator,  
program, routine, and subroutine are all used in slightly different  
ways in different programming languages. Rather than inherit this  
confusion, J adopts its own terms, and defines them precisely within  
its context.


Donna
[EMAIL PROTECTED]




On 1-Jul-06, at 3:22 AM, Randy MacDonald wrote:


Hello Donna;


Why not use the J term VERB?


I suspect it is a first-language-APL thing. function/verb are  
interchangeable to me. To insist on one term over another is a bit  
"Academie Française" to me.


many

Why not...


I'm seeing this is as you saying "this also works" my first  
impression was in error. Never mind.
-- 
--

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're  
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP) 
{ gnat }-



--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Randy MacDonald

Hello Donna;


Why not use the J term VERB?


I suspect it is a first-language-APL thing. function/verb are 
interchangeable to me. To insist on one term over another is a bit "Academie 
Française" to me.


many

Why not...


I'm seeing this is as you saying "this also works" my first impression was 
in error. Never mind.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP){ gnat }-


--
For information about J forums see http://www.jsoftware.com/forums.htm



RE: [Jgeneral] significant digits

2006-06-30 Thread Miller, Raul D
Donna L.Y. wrote:
> Perhaps I am unaware of the actual purpose of the J forums and
> Jgeneral in particular.  Can someone fill me in?

http://www.jsoftware.com/forums.htm

> After each post I seem to be reprimanded for what I have said.

Seem to be?  How odd.

Most of your posts to J's General list, in response to John Randall
seem to be in response to messages which were not posted to the
list.  Politeness suggests that you respond off-list when you are
responding to a message which was not sent to a list.  Either that,
or something is wrong at my end.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-30 Thread Miller, Raul D
Donna L.Y. wrote:
> On 30-Jun-06, at 6:28 PM, Miller, Raul D wrote:
> > J's %: is a function, it's not the concept "square root".
>
> Why not use the J term VERB?

Because that describes a different concept.

J's roll (?) is an example of a verb that is not a function:
   ?9
0
   ?9
5

Also, if it matters, adverbs and conjunctions can be functions,
even though they are not verbs.

> Why does the definition of monadic %: say Square Root but you say
>  it is not the concept of "square route"?

There, I'm trying to draw a contrast between "function" and
"concept".

> Why not include the result

That ground had already been covered.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly
Perhaps I am unaware of the actual purpose of the J forums and  
Jgeneral in particular.  Can someone fill me in?


After each post I seem to be reprimanded for what I have said.

I started this subject--significant digits to explore some of the  
ways precision was reflected in J


Now I am told, if I don't understand the post thats too bad for me.

Sometimes it feels like conversing with the society for the  
prevention of cruelty to dead horses.


Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 10:43 PM, Eldon Eller wrote:


so maybe I am beating a dead horse.


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Eldon Eller
Actually I was thinking of plain trig, cartesian coordinates, where the 
tangent of an angle is the ratio of the x coordinate to the y 
coordinate, both real. Of course in an expression like 1j2, 1 and 2 are 
both real, so maybe I am beating a dead horse. It might be nice if j 
were to return atan2 when asked for the arctangent of a rational, but it 
is of but small moment to me.


Randy MacDonald wrote:


Hello Eldon;

So, the "r" should be a "j" ... I'm not so confused.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP){ gnat }-

- Original Message - From: "Eldon Eller" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Friday, June 30, 2006 12:21 AM
Subject: Re: [Jgeneral] significant digits



What I mean is:

  (-1,1)
  * |
 \   |
   \ |
---
 | \
 |   \
 |*
(1,-1)
Randy MacDonald wrote:


Hello Eldon;

Do you mean:

  _3 o. _1r1
_0.785398
  _3 o. 1r_1
_0.785398

  (_3 o. 1r_1) = _3 o. _1r1
1

I must be missing something, or reading the vocabulary pages 
incorrectly.
 


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're 
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.73.214/
-(INTP){ 
gnat }-


- Original Message - From: "Eldon Eller" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Thursday, June 29, 2006 3:14 PM
Subject: Re: [Jgeneral] significant digits



The arc tangent of _1r1 is different from the arc tangent of 1r_1.

Randy MacDonald wrote:


Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

all I can say is they produce the same result when evaluated, but 
each use a different number of keystrokes.


If your question was something else, I apologize for my lack of 
proper attention.


I'm thinking this is different in the case of 1 and 1.1-.1, where

1 = 1.1 - .1
but
([]dr 1){ne}[]dr 1.1-.1

NB. Excuse the APL, I'm being lazy in not looking up the foreign 
for data representation.


(J-note)
 1.1-.1
1.1

was something I had to think about for a bit. Definitely a gotcha.
 



|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're 
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.130/
-----(INTP){ 
gnat }-


- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Wednesday, June 28, 2006 6:54 PM
Subject: Re: [Jgeneral] significant digits


Yes I do not see how my statement that I do not expect J to 
resolve these problems differs from your statement that it is a 
programming issue and not a language issue.


I merely observe that when one person considered something noise, 
it may not actually meet the definition of noise and may actually 
represent a loss of information.  Obviously it is information not 
interesting to everyone.


I do not grasp why you do not see why I am interested in knowing 
the precision of J before I use it because I think it is somewhat 
analogous to you needing to know the precision of a program I 
produced before you called on it as a subroutine.


What is and is not built in varies by language.  There is much 
built in to J that was not built in to APL.  There may or not be 
other languages that have things built in to them that are not 
built in to J.  This is all that I am trying to discover.


In my experience such a process of discovery could be aided by 
others who are expert with the language one is trying to explore 
rather than deferring to such time as you my or may not become an 
expert yourself and such information can be used in decision 
making.  In some cases however there may

Re: [Jgeneral] significant digits

2006-06-30 Thread John Randall
dly wrote:
> Sorry, I did not mean you were not clear to each other.  Just that a
> few comments can help follow.
>
> Like:
>
> The connection between ¸ and arctan is that arctan (1) is ¸ divided by 4
>
> arctan=:_3&o.
>
> arctan 1
> 0.785398
>
>
> 1p1%4
> 0.785398
>

Donna:

We are not writing high-school essays here.  You (and anyone who knows
what arctan is) can easily supply these sorts of examples.  Plus it is
covered under
> For real y, arctan y is the angle between _1r2p1 and 1r2p1 whose
>> tangent
>> is y.
There are many other connections between arctan and 1p1.

It's kind of pointless to say "you should have said ".  I didn't. 
If you want to say something, say it.  Maybe I will see the error of my
ways.  In this case I don't.

The point of my post was to draw out the distinction between arctan and
its 2-argument form, normally called something like atan2, and implemented
in J as 12&o., with the additional complication that J puts two real
arguments into a complex number.  I believe I succeeded.  If you have a
better explanation, please post it.  But simply complaining that I should
have said something different does not get us anywhere.

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread John Randall
dly wrote:
> Can you demonstrate this function with some arguments?

>>> angle =:12&o.
>
  angle=:12&o.
  roots=:[:^ 0j2p1&% * i. NB. roots of unity
  roots 8
1 0.707107j0.707107 0j1 _0.707107j0.707107 _1 _0.707107j_0.707107 0j_1
0.707107j_0.707107
   +. roots 8
1 0
 0.707107  0.707107
0 1
_0.707107  0.707107
   _1 0
_0.707107 _0.707107
0_1
 0.707107 _0.707107
   angle roots 8
0 0.785398 1.5708 2.35619 3.14159 _2.35619 _1.5708 _0.785398
   (angle roots 8)%2p1
0 0.125 0.25 0.375 0.5 _0.375 _0.25 _0.125

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread John Randall
dly wrote:
> FTOOT (for the out of date)
>
> In J terminology does verb correspond to this old fashion view of
> function or the newer view so that a verb must be a one to one relation?
>

J verbs are like mathematical functions, not relations.  They are not
necessarily 1-1 (e.g. *: (square)).

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly

my 2 cents worth in extra comments
Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 6:28 PM, Miller, Raul D wrote:


Dan Bron wrote:

Can you now explain why I was taught, in elementary math, to express
%:4  as  (+,-)2  instead of just  2  ?


because the square root of a positive number can be positive or negative


You were being taught about the relationship between the set 2 _2,
the concept of "square root" and the number 4.

J's %: is a function, it's not the concept "square root".


Why not use the J term VERB?
Why does the definition of monadic %: say Square Root but you say it  
is not the concept of "square route"?

Square Root
%:  0 0 0
Root

%: y is the square root of y . If y is negative, the result is an  
imaginary number. For example, %:-4 ↔ 0j2 .



x %: y is the x root of y . Thus, 3%:8 is 2, and 2%:y is %:y . In  
general, x %: y ↔ y^%x .






Of course, if you want both of the values which are valid square
roots, J allows you to express this unambiguously:
  (,-)@%: 4


Why not include the result

 (,-)@%: 4
2 _2

Why not show this too

(,-)@%: 1j1
1.09868j0.45509 _1.09868j_0.45509

(+,-)%:1j1
1.09868j_0.45509 _1.09868j_0.45509

and this

(,-)@%: 0j1
0.707107j0.707107 _0.707107j_0.707107





But note that (+,-)%: is not quite right.  Consider
   *:(+,-)%:1j1
1j_1 1j1


*:%:1j1
1j1

*:%:1j_1
1j_1


Then again, in most contexts it's far more useful to have
a result with exactly the same shape as the argument than it
is to have two values (one of which is trivially derived from
the other) mixed together.


If I have to write  (%:4) = (+,-)2   why do I not have to write
  (^._1) = 0 j. 1p1 * 1 + 2 * i: _  ?  Is it because  the former
has only 2 elements, but the latter infinitely many?

If I have to write the square root of 4 is plus or minus 2
why do I not need to write  (I am not sure what the balance means  
either)


^._1
1j_1





I do not understand the above question.  In my opinion, you do
not have to write (%:4) = (+,-)2 so the rest of the question
makes no sense to me.


By the way, I'm pretty sure  0 j. 1p1 * 1 + 2 * i: N
(scalar positive integer  N )  is the right expression for
generating for the logs of  _1  but J doesn't agree:


   ^0 j. 1p1*1+2*i:3
_1 _1 _1 _1 _1 _1 _1

Looks right to me.


0 j.3.14159*1+2*i:3
15.708 9.42477 3.14159 3.14159 9.42477 15.708 21.9911




Of course, for large values of N, you start running into the
limits of precision expressible using floating point numbers,
so you get numbers which are "nearly 1, but not quite".

--
Raul



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly

Can you demonstrate this function with some arguments?
Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 7:46 PM, dly wrote:


angle =:12&o.


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly

FTOOT (for the out of date)

In J terminology does verb correspond to this old fashion view of  
function or the newer view so that a verb must be a one to one relation?


Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 5:43 PM, John Randall wrote:

Mathematicians used to have a more inclusive idea of function,  
including
"multivalued functions", which are now called "relations" (the  
terminology

being most obvious in relational databases).

...

Multivalued functions are not functions in
modern terminology, and they are systematically eliminated from  
calculus

curricula, except in implicit differentiation.

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly
Sorry, I did not mean you were not clear to each other.  Just that a  
few comments can help follow.


Like:

The connection between ∏ and arctan is that arctan (1) is ∏ divided by 4

arctan=:_3&o.

   arctan 1
0.785398


   1p1%4
0.785398





Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 7:05 PM, John Randall wrote:


dly wrote:

It is just clearer when you know what arc tan is and then why it  
relates



just briefly in between the J


Donna:

I thought this explanation was pretty clear:
[snip]
arctan=:_3&o.
angle =:12&o.

For real y, arctan y is the angle between _1r2p1 and 1r2p1 whose  
tangent

is y.

For real x and y, angle x+j.y is the angle from the x-axis to (x,y),
between _1p1 and 1p1.

If x>0, arctan y%x is the same as angle x+j.y, but not if x<:0.
[/snip]

There is some J in it, but then this is a J group.  Someone who  
uses J's
o. functions can be assumed to know something about complex numbers  
and

their representation as the Argand diagram.  I know what orthogonal
vectors are: I just did not think it relevant to mention them, and  
I have

to assume some context.

Again, please feel free to write up something if you think this is  
unclear

or presuming too much.

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread John Randall
dly wrote:

> It is just clearer when you know what arc tan is and then why it relates

> just briefly in between the J

Donna:

I thought this explanation was pretty clear:
[snip]
arctan=:_3&o.
angle =:12&o.

For real y, arctan y is the angle between _1r2p1 and 1r2p1 whose tangent
is y.

For real x and y, angle x+j.y is the angle from the x-axis to (x,y),
between _1p1 and 1p1.

If x>0, arctan y%x is the same as angle x+j.y, but not if x<:0.
[/snip]

There is some J in it, but then this is a J group.  Someone who uses J's
o. functions can be assumed to know something about complex numbers and
their representation as the Argand diagram.  I know what orthogonal
vectors are: I just did not think it relevant to mention them, and I have
to assume some context.

Again, please feel free to write up something if you think this is unclear
or presuming too much.

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly

I am not yet up to speed

It is just clearer when you know what arc tan is and then why it relates

just briefly in between the J

Not a lot of philosophy

orthogonal vectors briefly:

i,j,k are orthogonal and can be represented as [1 0 0],[0 1 0],[0 0  
1] or represent the x,y,z where z is imaginary or you can exclude  
imaginary and talk about x and y as orthogonal.  These vectors are at  
right angles.  etc.


I can look up more and try to catch a thread of what you are  
comparing and provide some narrative.



Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 6:27 PM, John Randall wrote:


dly wrote:

I think all these inter-relationships would be much clearer if you
talked about polar notation, orthogonal vectors, complex numbers and
what trigonometric functions actually are.



I think that trigonometric functions are best defined by solutions to
initial value problems, for example, cos is the unique solution to  
the IVP


y''+y=0, y(0)=1, y'(0)=0requires more preliminaries

or equivalently as a series.

Measuring a length along a curve (as in the unit circle definition)  
has

some serious difficulties that are glossed over in elementary courses.
I'll leave the question of the trigonometric functions actually are  
to the

philosophers.

I was using polar notation for complex numbers in my discussion of  
^. _1:
this was so that you could get the roots using Euler's formula.   
Obviously
complex numbers can be viewed in many ways.  Where do orthogonal  
vectors

come in here?

If you have a clearer explanation, please post it.  I am just  
explaining

it the way I understand it.


Best wishes,

John




--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-30 Thread Miller, Raul D
Dan Bron wrote:
> Can you now explain why I was taught, in elementary math, to express
> %:4  as  (+,-)2  instead of just  2  ?

You were being taught about the relationship between the set 2 _2,
the concept of "square root" and the number 4.

J's %: is a function, it's not the concept "square root".

Of course, if you want both of the values which are valid square
roots, J allows you to express this unambiguously:
  (,-)@%: 4

But note that (+,-)%: is not quite right.  Consider
   *:(+,-)%:1j1
1j_1 1j1

Then again, in most contexts it's far more useful to have
a result with exactly the same shape as the argument than it
is to have two values (one of which is trivially derived from
the other) mixed together.

> If I have to write  (%:4) = (+,-)2   why do I not have to write
>   (^._1) = 0 j. 1p1 * 1 + 2 * i: _  ?  Is it because  the former
> has only 2 elements, but the latter infinitely many? 

I do not understand the above question.  In my opinion, you do
not have to write (%:4) = (+,-)2 so the rest of the question
makes no sense to me.

> By the way, I'm pretty sure  0 j. 1p1 * 1 + 2 * i: N 
> (scalar positive integer  N )  is the right expression for
> generating for the logs of  _1  but J doesn't agree:

   ^0 j. 1p1*1+2*i:3
_1 _1 _1 _1 _1 _1 _1

Looks right to me.

Of course, for large values of N, you start running into the
limits of precision expressible using floating point numbers,
so you get numbers which are "nearly 1, but not quite".

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread John Randall
dly wrote:
> I think all these inter-relationships would be much clearer if you
> talked about polar notation, orthogonal vectors, complex numbers and
> what trigonometric functions actually are.
>

I think that trigonometric functions are best defined by solutions to
initial value problems, for example, cos is the unique solution to the IVP

y''+y=0, y(0)=1, y'(0)=0requires more preliminaries

or equivalently as a series.

Measuring a length along a curve (as in the unit circle definition) has
some serious difficulties that are glossed over in elementary courses. 
I'll leave the question of the trigonometric functions actually are to the
philosophers.

I was using polar notation for complex numbers in my discussion of ^. _1:
this was so that you could get the roots using Euler's formula.  Obviously
complex numbers can be viewed in many ways.  Where do orthogonal vectors
come in here?

If you have a clearer explanation, please post it.  I am just explaining
it the way I understand it.


Best wishes,

John




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread dly
I think all these inter-relationships would be much clearer if you  
talked about polar notation, orthogonal vectors, complex numbers and  
what trigonometric functions actually are.


Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 5:43 PM, John Randall wrote:


Dan Bron wrote:

Can you now explain why I was taught, in elementary math, to  
express  %:4

as  (+,-)2  instead of just  2  ?  If I have to write  (%:4) = (+,-)2
why do I not have to write  (^._1) = 0 j. 1p1 * 1 + 2 * i: _  ?   
Is it
because  the former has only 2 elements, but the latter infinitely  
many?


By the way, I'm pretty sure  0 j. 1p1 * 1 + 2 * i: N  (scalar  
positive
integer  N )  is the right expression for generating for the logs  
of  _1

but J doesn't agree:



Henry's non-mathematician's response is right on the money.

Mathematicians used to have a more inclusive idea of function,  
including
"multivalued functions", which are now called "relations" (the  
terminology

being most obvious in relational databases). Square root is the first
obvious example of a multivalued function, and it may be treated  
this way

in elementary curricula.  Multivalued functions are not functions in
modern terminology, and they are systematically eliminated from  
calculus

curricula, except in implicit differentiation.

You are absolutely correct that the complex numbers z such that ^z  
is _1
are given by odd multiples of j.1p1 . This can be seen easily from  
Euler's
formula.  J is using a principal domain that is something like the  
complex
numbers r*^j.x where r>0 and x is a real number in the interval  
(_1p1,1p1)
(with possibly one end closed).  The complex log is then (^.r) 
+j.x .  As
Henry points out, if x is very close to 1p1 (where the cut in the  
complex

plane is made), it may go either way.

Best wishes,

John



--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread John Randall
Dan Bron wrote:

> Can you now explain why I was taught, in elementary math, to express  %:4
> as  (+,-)2  instead of just  2  ?  If I have to write  (%:4) = (+,-)2
> why do I not have to write  (^._1) = 0 j. 1p1 * 1 + 2 * i: _  ?  Is it
> because  the former has only 2 elements, but the latter infinitely many?
>
> By the way, I'm pretty sure  0 j. 1p1 * 1 + 2 * i: N  (scalar positive
> integer  N )  is the right expression for generating for the logs of  _1
> but J doesn't agree:
>

Henry's non-mathematician's response is right on the money.

Mathematicians used to have a more inclusive idea of function, including
"multivalued functions", which are now called "relations" (the terminology
being most obvious in relational databases). Square root is the first
obvious example of a multivalued function, and it may be treated this way
in elementary curricula.  Multivalued functions are not functions in
modern terminology, and they are systematically eliminated from calculus
curricula, except in implicit differentiation.

You are absolutely correct that the complex numbers z such that ^z is _1
are given by odd multiples of j.1p1 . This can be seen easily from Euler's
formula.  J is using a principal domain that is something like the complex
numbers r*^j.x where r>0 and x is a real number in the interval (_1p1,1p1)
(with possibly one end closed).  The complex log is then (^.r)+j.x .  As
Henry points out, if x is very close to 1p1 (where the cut in the complex
plane is made), it may go either way.

Best wishes,

John



--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-30 Thread Henry Rich
Maybe a non-mathematician's answer will help.

If you want to find all the numbers that solve the
equation

x^2 = 4

you had better remember both square roots.

Similarly, if you want all the numbers that solve

sin(x) = 0 

there are an infinite number, 0, 2p1, 4p1, etc.

Likewise there are an infinite number of solutions for

^x = _1

as you have seen.

For that matter, there are an infinite number of solutions for

^x = 1

(try 0 j. 2p1  etc.)


Lots of times you don't want all the answers, and it's easier if
you get just one, so you can have an invertible fnction.  So you
define a function that gives only one, the way ^ and ^. (and %:)
are defined in J.

That leaves it up to you to figure out what to do if you really
need all the answers to a problem like ^x = 1 .

When you learned elementary math, they wanted you to find all the
answers to quadratic equations.




   ^  0 j. 1p1 * 1 + 2 * _10 _9 _8
_1j_3.43025e_15 _1j3.67517e_15 _1j_3.43025e_15

You are getting numbers close to _1j0 but not exactly it, and
taking the log gives you either 1 j. pi or 1 j. -pi depending
on the sign of the garbage, because you are right around the
discontinuity in the log function.


Henry Rich


> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Dan Bron
> Sent: Friday, June 30, 2006 10:32 AM
> To: General forum
> Subject: Re: [Jgeneral] significant digits
> 
> Henry Rich wrote:
> >  ^ doesn't have an inverse (unless you make some restrictions).  
> >  So, the flaw in your argument was when you said that ^ and ^. 
> >  cancel each other out.
> 
> John Randall wrote:
> > The problem here is that a function f has an inverse function 
> > only if f is 1-1.
> 
> Thanks, guys.  I knew there was a reason I put the word 
> "proof" in quotes :)
> 
> Can you now explain why I was taught, in elementary math, to 
> express  %:4  as  (+,-)2  instead of just  2  ?  If I have to 
> write  (%:4) = (+,-)2   why do I not have to write  (^._1) = 
> 0 j. 1p1 * 1 + 2 * i: _  ?  Is it because  the former has 
> only 2 elements, but the latter infinitely many? 
> 
> By the way, I'm pretty sure  0 j. 1p1 * 1 + 2 * i: N  (scalar 
> positive integer  N )  is the right expression for generating 
> for the logs of  _1  but J doesn't agree:
> 
>  10 {. ^.  ^  0 j. 1p1 * 1 + 2 * i: N =: 10
>   0j_3.14159 0j3.14159 0j_3.14159 0j3.14159 0j_3.14159 
> 0j3.14159 0j3.14159 0j3.14159 0j3.14159 0j3.14159
> 
>  ~.^.  ^  0 j. 1p1 * 1 + 2 * i: N =: 10
>   0j_3.14159 0j3.14159
> 
>  10 {. q=. M #~ 0j1p1 ~: !.(2^_34) ^.  ^  0 j. 1p1 * 
> M =: 1 + 2 * i: N =: 1000
>   _1995 _1993 _1989 _1987 _1985 _1981 _1979 _1973 _1971 _1967
> 
>  25 {. }. +/\^:_1  q
>   2 4 2 2 4 2 6 2 4 2 2 4 2 6 2 4 2 2 4 2 6 2 4 2 6
>  
> 
> Have I got it wrong?  What's the right expression?  What I am 
> really generating with my expression?  What's with the odd 
> gaps between successive  0j1p1 ?  I don't see the pattern.  
> Or maybe this is just an implementation issue?
> 
> -Dan
> 
> 
> 
> 
> --
> For information about J forums see 
> http://www.jsoftware.com/forums.htm

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Dan Bron
Henry Rich wrote:
>  ^ doesn't have an inverse (unless you make some restrictions).  
>  So, the flaw in your argument was when you said that ^ and ^. 
>  cancel each other out.

John Randall wrote:
> The problem here is that a function f has an inverse function 
> only if f is 1-1.

Thanks, guys.  I knew there was a reason I put the word "proof" in quotes :)

Can you now explain why I was taught, in elementary math, to express  %:4  as  
(+,-)2  instead of just  2  ?  If I have to write  (%:4) = (+,-)2   why do I 
not have to write  (^._1) = 0 j. 1p1 * 1 + 2 * i: _  ?  Is it because  the 
former has only 2 elements, but the latter infinitely many? 

By the way, I'm pretty sure  0 j. 1p1 * 1 + 2 * i: N  (scalar positive integer  
N )  is the right expression for generating for the logs of  _1  but J doesn't 
agree:

   10 {. ^.  ^  0 j. 1p1 * 1 + 2 * i: N =: 10
0j_3.14159 0j3.14159 0j_3.14159 0j3.14159 0j_3.14159 0j3.14159 
0j3.14159 0j3.14159 0j3.14159 0j3.14159

   ~.^.  ^  0 j. 1p1 * 1 + 2 * i: N =: 10
0j_3.14159 0j3.14159

   10 {. q=. M #~ 0j1p1 ~: !.(2^_34) ^.  ^  0 j. 1p1 * M =: 1 + 2 * i: 
N =: 1000
_1995 _1993 _1989 _1987 _1985 _1981 _1979 _1973 _1971 _1967

   25 {. }. +/\^:_1  q
2 4 2 2 4 2 6 2 4 2 2 4 2 6 2 4 2 2 4 2 6 2 4 2 6
   

Have I got it wrong?  What's the right expression?  What I am really generating 
with my expression?  What's with the odd gaps between successive  0j1p1 ?  I 
don't see the pattern.  Or maybe this is just an implementation issue?

-Dan




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-30 Thread Randy MacDonald

Hello Eldon;

So, the "r" should be a "j" ... I'm not so confused.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.82.232/
-(INTP){ gnat }-

- Original Message - 
From: "Eldon Eller" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Friday, June 30, 2006 12:21 AM
Subject: Re: [Jgeneral] significant digits



What I mean is:

  (-1,1)
  * |
 \   |
   \ |
---
 | \
 |   \
 |*
(1,-1)
Randy MacDonald wrote:


Hello Eldon;

Do you mean:

  _3 o. _1r1
_0.785398
  _3 o. 1r_1
_0.785398

  (_3 o. 1r_1) = _3 o. _1r1
1

I must be missing something, or reading the vocabulary pages incorrectly.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.73.214/
-(INTP){ gnat }-

- Original Message - From: "Eldon Eller" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Thursday, June 29, 2006 3:14 PM
Subject: Re: [Jgeneral] significant digits



The arc tangent of _1r1 is different from the arc tangent of 1r_1.

Randy MacDonald wrote:


Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

all I can say is they produce the same result when evaluated, but each 
use a different number of keystrokes.


If your question was something else, I apologize for my lack of proper 
attention.


I'm thinking this is different in the case of 1 and 1.1-.1, where

1 = 1.1 - .1
but
([]dr 1){ne}[]dr 1.1-.1

NB. Excuse the APL, I'm being lazy in not looking up the foreign for 
data representation.


(J-note)
 1.1-.1
1.1

was something I had to think about for a bit. Definitely a gotcha.


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're 
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.130/
-----(INTP){ 
gnat }-


- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Wednesday, June 28, 2006 6:54 PM
Subject: Re: [Jgeneral] significant digits


Yes I do not see how my statement that I do not expect J to resolve 
these problems differs from your statement that it is a programming 
issue and not a language issue.


I merely observe that when one person considered something noise, it 
may not actually meet the definition of noise and may actually 
represent a loss of information.  Obviously it is information not 
interesting to everyone.


I do not grasp why you do not see why I am interested in knowing the 
precision of J before I use it because I think it is somewhat 
analogous to you needing to know the precision of a program I 
produced before you called on it as a subroutine.


What is and is not built in varies by language.  There is much built 
in to J that was not built in to APL.  There may or not be other 
languages that have things built in to them that are not built in to 
J.  This is all that I am trying to discover.


In my experience such a process of discovery could be aided by others 
who are expert with the language one is trying to explore rather than 
deferring to such time as you my or may not become an expert yourself 
and such information can be used in decision making.  In some cases 
however there may be no one with the time or inclination to share 
such information.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:39 PM, John Randall wrote:


dly wrote:


I am not expecting J to resolve these problems I a merely trying to
ascertain how J has improved from APL and to know its limitations
before thinking of applying it to some problems.



Donna:

In my opinion, what you are getting at is a program

Re: [Jgeneral] significant digits

2006-06-29 Thread Eldon Eller

What I mean is:

  (-1,1)
  * |
 \   |
   \ |
---
 | \
 |   \
 |*
(1,-1)
Randy MacDonald wrote:


Hello Eldon;

Do you mean:

  _3 o. _1r1
_0.785398
  _3 o. 1r_1
_0.785398

  (_3 o. 1r_1) = _3 o. _1r1
1

I must be missing something, or reading the vocabulary pages incorrectly.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.73.214/
-(INTP){ gnat }-

- Original Message - From: "Eldon Eller" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Thursday, June 29, 2006 3:14 PM
Subject: Re: [Jgeneral] significant digits



The arc tangent of _1r1 is different from the arc tangent of 1r_1.

Randy MacDonald wrote:


Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

all I can say is they produce the same result when evaluated, but 
each use a different number of keystrokes.


If your question was something else, I apologize for my lack of 
proper attention.


I'm thinking this is different in the case of 1 and 1.1-.1, where

1 = 1.1 - .1
but
([]dr 1){ne}[]dr 1.1-.1

NB. Excuse the APL, I'm being lazy in not looking up the foreign for 
data representation.


(J-note)
 1.1-.1
1.1

was something I had to think about for a bit. Definitely a gotcha.
 


|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're 
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.130/
-(INTP){ 
gnat }-


- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Wednesday, June 28, 2006 6:54 PM
Subject: Re: [Jgeneral] significant digits


Yes I do not see how my statement that I do not expect J to resolve 
these problems differs from your statement that it is a programming 
issue and not a language issue.


I merely observe that when one person considered something noise, 
it may not actually meet the definition of noise and may actually 
represent a loss of information.  Obviously it is information not 
interesting to everyone.


I do not grasp why you do not see why I am interested in knowing 
the precision of J before I use it because I think it is somewhat  
analogous to you needing to know the precision of a program I  
produced before you called on it as a subroutine.


What is and is not built in varies by language.  There is much 
built  in to J that was not built in to APL.  There may or not be 
other  languages that have things built in to them that are not 
built in to  J.  This is all that I am trying to discover.


In my experience such a process of discovery could be aided by 
others who are expert with the language one is trying to explore 
rather than deferring to such time as you my or may not become an 
expert yourself and such information can be used in decision 
making.  In some cases however there may be no one with the time or 
inclination to share  such information.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:39 PM, John Randall wrote:


dly wrote:


I am not expecting J to resolve these problems I a merely trying to
ascertain how J has improved from APL and to know its limitations
before thinking of applying it to some problems.



Donna:

In my opinion, what you are getting at is a programming issue, not a
language issue.

All languages can easily represent rational numbers as  
canonicalized pairs
of integers: J happens to have them built-in.  If you need to deal 
with
non canonicalized pairs, it is easy to do that too, although this  
is not

built-in in J.

The matrix similarity questions I mentioned needs the programmer 
to keep
in mind the ring over which the similarity is being constructed.  
I  do not

see how the language is going to do that for you.

Best wishes,

John

-- 

For information about J forums see 
http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm




--

RE: [Jgeneral] significant digits

2006-06-29 Thread John Randall
Henry Rich wrote:
> More than one post in this thread has conflated 1r_1 with 1j_1
> and I wonder if everyone who is interested (which doesn't
> include me) is getting the right meaning out of it.
>

The conflation is encouraged by the easiest way to get the angle to (x,y)
(or equivalently atan2) in J.

arctan=:_3&o.
angle =:12&o.

For real y, arctan y is the angle between _1r2p1 and 1r2p1 whose tangent
is y.

For real x and y, angle x+j.y is the angle from the x-axis to (x,y),
between _1p1 and 1p1.

If x>0, arctan y%x is the same as angle x+j.y, but not if x<:0.

When Eldon talks about arctan _1r1 he means angle _1j1.   This really has
nothing to do with rational numbers, adding to the confusion.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Henry Rich
Numbers are recognized by the word-former (aka lexical analyzer,
tokenizer) and follow some well-defined rules that you can
find in the Dictionary.  1jo. 1  or 1jo.1 is matched as
number(s), as you can see by the results of

   ;: '1jo. 1'
or
   ;: '1jo.1'

but the numbers don't follow the rules, so they get error.

Anything starting with a digit must be a number that follows the
rules.

   1j o. 1

is recognized as 3 words (as you can check), but 1j is not a valid
number so you get an error there too.

Henry Rich

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of dly
> Sent: Thursday, June 29, 2006 9:16 PM
> To: General forum
> Subject: Re: [Jgeneral] significant digits
> 
> Still playing with these but some help would help
> 
> also why can you use
> 
> 0j1p1
> 0j3.14159
> 
> but not
> 
> o.1
> 3.14159
> 0jo.1
> |ill-formed number
> 
> 
> 
> Donna
> [EMAIL PROTECTED]
> 
> 
> 
> On 30-Jun-06, at 1:05 AM, Henry Rich wrote:
> 
> > More than one post in this thread has conflated 1r_1 with 1j_1
> > and I wonder if everyone who is interested (which doesn't
> > include me) is getting the right meaning out of it.
> >
> > Henry Rich
> >
> >>
> >> Eldon's point, and my code on arctan _1r1, were concerned with  
> >> variant
> >> defintions of arctan.  Arctan is normally defined by 
> restricting the
> >> domain of tangent to the open interval (-1r2p1, 1r2p1), so it
> >> always gives
> >> an angle in the first or fourth quadrant.  In many
> >> applications, you want
> >> the angle from the x-axis to the point (x,y), which can be in any
> >> quadrant.  This is basically arctan y%x, except it takes sign into
> >> account.  Library functions called atan2 usually do this, and
> >> J does it
> >> via angle (12&o.).  Then arctan _1 is _1r4p1 (in the fourth  
> >> quadrant),
> >> same as the angle to (1,_1), but different from the angle 
> to (_1,1).
> >>
> >> Best wishes,
> >>
> >> John
> >>
> >>
> >> 
> - 
> >> -
> >> For information about J forums see
> >> http://www.jsoftware.com/forums.htm
> >
> > 
> --
> > For information about J forums see 
> http://www.jsoftware.com/forums.htm
> 
> --
> For information about J forums see 
> http://www.jsoftware.com/forums.htm

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly

Still playing with these but some help would help

also why can you use

0j1p1
0j3.14159

but not

o.1
3.14159
   0jo.1
|ill-formed number



Donna
[EMAIL PROTECTED]



On 30-Jun-06, at 1:05 AM, Henry Rich wrote:


More than one post in this thread has conflated 1r_1 with 1j_1
and I wonder if everyone who is interested (which doesn't
include me) is getting the right meaning out of it.

Henry Rich



Eldon's point, and my code on arctan _1r1, were concerned with  
variant

defintions of arctan.  Arctan is normally defined by restricting the
domain of tangent to the open interval (-1r2p1, 1r2p1), so it
always gives
an angle in the first or fourth quadrant.  In many
applications, you want
the angle from the x-axis to the point (x,y), which can be in any
quadrant.  This is basically arctan y%x, except it takes sign into
account.  Library functions called atan2 usually do this, and
J does it
via angle (12&o.).  Then arctan _1 is _1r4p1 (in the fourth  
quadrant),

same as the angle to (1,_1), but different from the angle to (_1,1).

Best wishes,

John


- 
-

For information about J forums see
http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Henry Rich
More than one post in this thread has conflated 1r_1 with 1j_1
and I wonder if everyone who is interested (which doesn't
include me) is getting the right meaning out of it.

Henry Rich 

> 
> Eldon's point, and my code on arctan _1r1, were concerned with variant
> defintions of arctan.  Arctan is normally defined by restricting the
> domain of tangent to the open interval (-1r2p1, 1r2p1), so it 
> always gives
> an angle in the first or fourth quadrant.  In many 
> applications, you want
> the angle from the x-axis to the point (x,y), which can be in any
> quadrant.  This is basically arctan y%x, except it takes sign into
> account.  Library functions called atan2 usually do this, and 
> J does it
> via angle (12&o.).  Then arctan _1 is _1r4p1 (in the fourth quadrant),
> same as the angle to (1,_1), but different from the angle to (_1,1).
> 
> Best wishes,
> 
> John
> 
> 
> --
> For information about J forums see 
> http://www.jsoftware.com/forums.htm

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
Dan Bron wrote:

> PS:
>
> I'm not a mathematician, but it seems to me that the right solution is to
> express  ^._1  as  0 j. (+,-) 1p1  .  But no one does.  At least not in
> front of me.

The problem here is that a function f has an inverse function only if f is
1-1.  It always has an inverse relation.

If f is not 1-1, and we want an inverse function, we restrict its domain
to give a new function g hich is 1-1, and then take the inverse of that. 
The simplest example is f(x)=x^2, which is not 1-1 (e.g. f(-1)=f(1)=1). 
We restrict its domain to give the new function g(x)=x^2, x>:0, and call
the inverse of g the square root.

The choice of restriction is somehat arbitrary, but there are established
conventions for trigonometric functions, giving arcsin, arccos, etc.

It's a bit more complicated for ^ and ^.  For real values, ^ is 1-1 on the
nose, so no restriction is needed to define ^.  For y real, ^ j. y is
defined by Euler's formula as  (cos y)+j.(sin y).  This has period 2p1, so
to make it 1-1 you cannot include 0j1p1 and 0j_1p1 in the domain of the
restriction.  This is why ^. _1 is never expressed as as  0 j. (+,-) 1p1 .

Complex log defined via a specific restriction is not really so useful a
function.  What is important is that complex exponential has a local
inverse.

Eldon's point, and my code on arctan _1r1, were concerned with variant
defintions of arctan.  Arctan is normally defined by restricting the
domain of tangent to the open interval (-1r2p1, 1r2p1), so it always gives
an angle in the first or fourth quadrant.  In many applications, you want
the angle from the x-axis to the point (x,y), which can be in any
quadrant.  This is basically arctan y%x, except it takes sign into
account.  Library functions called atan2 usually do this, and J does it
via angle (12&o.).  Then arctan _1 is _1r4p1 (in the fourth quadrant),
same as the angle to (1,_1), but different from the angle to (_1,1).

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread Randy MacDonald

That seems to prove that

  (arctan 1j_1) notequal (arctan _1j1)

correct?

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.73.214/
-(INTP){ gnat }-

- Original Message - 
From: "John Randall" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Thursday, June 29, 2006 6:34 PM
Subject: Re: [Jgeneral] significant digits



Eldon Eller wrote:

The arc tangent of _1r1 is different from the arc tangent of 1r_1.



   atan=:_3&o.@:%~
   atan2=:angle@:j.
   (?0) (atan-atan2) (?0)
_1.11022e_16
   1 (atan-atan2) _1
0
  _1 (atan-atan2) 1
_3.14159

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Miller, Raul D
Dan Bron wrote:
> operation to reveal the difference, because no difference exists.
> So, despite my little "proof":
>
>  (^._1)  -: 0 j.-1p1
>   0

   _1 -: ^ 0 j.-1p1
1
   (^._1) -: (^.^ 0 j.-1p1)
1

> I'm not a mathematician, but it seems to me that the right solution
> is to express  ^._1  as  0 j. (+,-) 1p1  .  But no one does. 

That approach gets into infinitely fat results in many common cases.
This, all too easily, can lead to a variety of obscure errors.

Simple is good.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
John Randall meant:

angle=:12&.o.
atan=:_3&o.@:%~
atan2=:angle@:j.
(?0) (atan-atan2) (?0)
_1.11022e_16
1 (atan-atan2) _1
0
   _1 (atan-atan2) 1
_3.14159


Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
Eldon Eller wrote:
> The arc tangent of _1r1 is different from the arc tangent of 1r_1.
>

atan=:_3&o.@:%~
atan2=:angle@:j.
(?0) (atan-atan2) (?0)
_1.11022e_16
1 (atan-atan2) _1
0
   _1 (atan-atan2) 1
_3.14159

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread Dan Bron
From: "Eldon Eller" <[EMAIL PROTECTED]>
> The arc tangent of _1r1 is different from the arc tangent of 1r_1.

From: "Randy MacDonald" <[EMAIL PROTECTED]>
>   (_3 o. 1r_1) = _3 o. _1r1
>1

I believe Eldon means it in a mathematical sense.  Probably in the same way  
111r333  can differ from  1r3  (which neither J nor I can fathom).  To J,  1r_1 
 and  _1r1  are the same quantity:

   _1r1
_1
   1r_1
_1
   _1r1 -: 1r_1
1
   _1r1 -:&:(3!:3) 1r_1  NB.  Identical to the last bit, even in 
internal rep
1

So of course any operation on these quantities is going to produce the same 
output: they're the same input.  In fact, I shouldn't say "these quantities", I 
should say "this quantity".

None the less, there are ways of looking at the two quantities where they'll 
differ.  For example, when I was in college, I always saw  ^._1  defined to be  
0 j. 1p1  .  But that bugged me, because:

   _1 -: % _1   NB.  (A) The important part.
   _1 -:   ^ 0 j.   1p1 NB.  (B) Euler
   _1 -: % ^ 0 j.   1p1 NB.  (C) Substitute (B) into (A)
   _1 -: ^   0 j. - 1p1 NB.  (D) (%x^y) <==> (x^-y)

With (D), it becomes clear that  ^._1  is also equivalent to  ^.(^ 0 j.-1p1) .  
And  ^.  and  ^  are an inverse pair -- they cancel out.  So that leaves us 
with  (^._1)  -: 0 j.-1p1  .  So it matters whether you think of  _1  as  _1r1  
or as  1r_1  (i.e.  %_1 ). See postscript.   

Again, keep in mind,  J  cannot see the "differences" in these quantities.  In 
J's internals, they're represented identically.  It is impossible for an 
operation to reveal the difference, because no difference exists.  So, despite 
my little "proof":

   (^._1)  -: 0 j.-1p1
0

-Dan

PS:

I'm not a mathematician, but it seems to me that the right solution is to 
express  ^._1  as  0 j. (+,-) 1p1  .  But no one does.  At least not in front 
of me.

Not that such would present a solution for J.  If there are multiple solutions 
to a mathematical operation, J picks one.  Think of  0%0  or  %:y  :

4 -: *: _2  NB.  Yep
1
   _2 -: %:  4  NB.  Nope
0


I wonder if Perl6 will leverage its fancy new junctions to produce answers like 
 (+,-)2 
--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Miller, Raul D
Eldon Eller wrote:
> The arc tangent of _1r1 is different from the arc tangent of 1r_1.

   _1r1 1r_1
_1 _1

Maybe you were thinking of _1j1 and 1j_1?

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread Randy MacDonald

Hello Eldon;

Do you mean:

  _3 o. _1r1
_0.785398
  _3 o. 1r_1
_0.785398

  (_3 o. 1r_1) = _3 o. _1r1
1

I must be missing something, or reading the vocabulary pages incorrectly.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.73.214/
-(INTP){ gnat }-

- Original Message - 
From: "Eldon Eller" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Thursday, June 29, 2006 3:14 PM
Subject: Re: [Jgeneral] significant digits



The arc tangent of _1r1 is different from the arc tangent of 1r_1.

Randy MacDonald wrote:


Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

all I can say is they produce the same result when evaluated, but each 
use a different number of keystrokes.


If your question was something else, I apologize for my lack of proper 
attention.


I'm thinking this is different in the case of 1 and 1.1-.1, where

1 = 1.1 - .1
but
([]dr 1){ne}[]dr 1.1-.1

NB. Excuse the APL, I'm being lazy in not looking up the foreign for data 
representation.


(J-note)
 1.1-.1
1.1

was something I had to think about for a bit. Definitely a gotcha.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.130/
-(INTP){ gnat }-

- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Wednesday, June 28, 2006 6:54 PM
Subject: Re: [Jgeneral] significant digits


Yes I do not see how my statement that I do not expect J to resolve 
these problems differs from your statement that it is a programming 
issue and not a language issue.


I merely observe that when one person considered something noise, it 
may not actually meet the definition of noise and may actually 
represent a loss of information.  Obviously it is information not 
interesting to everyone.


I do not grasp why you do not see why I am interested in knowing the 
precision of J before I use it because I think it is somewhat  analogous 
to you needing to know the precision of a program I  produced before you 
called on it as a subroutine.


What is and is not built in varies by language.  There is much built  in 
to J that was not built in to APL.  There may or not be other  languages 
that have things built in to them that are not built in to  J.  This is 
all that I am trying to discover.


In my experience such a process of discovery could be aided by others 
who are expert with the language one is trying to explore rather than 
deferring to such time as you my or may not become an expert yourself 
and such information can be used in decision making.  In some cases 
however there may be no one with the time or inclination to share  such 
information.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:39 PM, John Randall wrote:


dly wrote:


I am not expecting J to resolve these problems I a merely trying to
ascertain how J has improved from APL and to know its limitations
before thinking of applying it to some problems.



Donna:

In my opinion, what you are getting at is a programming issue, not a
language issue.

All languages can easily represent rational numbers as  canonicalized 
pairs
of integers: J happens to have them built-in.  If you need to deal 
with
non canonicalized pairs, it is easy to do that too, although this  is 
not

built-in in J.

The matrix similarity questions I mentioned needs the programmer to 
keep
in mind the ring over which the similarity is being constructed.  I  do 
not

see how the language is going to do that for you.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm



--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm




-

Re: [Jgeneral] significant digits

2006-06-29 Thread dly

On 29-Jun-06, at 6:38 PM, John Randall wrote:

dly wrote:

Yes thank you this is why I prefaced this with IMD (in my dreams)
other than with here are all the other great languages that do this


What great languages do this?  While Maple and Mathematica do symbolic
calculations: they are subject to the same problems concerning loss of
signficance when it comes to evaluation.  Plus you pay a huge  
performance

penalty.

The fact is that you can obtain accurate answers without  
significant digit
arithmetic, as I have pointed out many times.  However, you need  
something

different from a naive algorithm.

Bst wishes,

John




Sorry John!

You are reading my quote out of context

I meant

Yes. I have also not seen this built into a language.

and Thus the preface IMD (in my dreams)

and NOT the preface "here are other great languages..."

and  "why can't you put this into J"

Which I specifically stated I did not request at least not for my  
benefit alone.





Yes thank you this is why I prefaced this with IMD (in my dreams)  
other than with here are all the other great languages that do this  
and why can't you put this into J


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 6:26 PM, Miller, Raul D wrote:



Randy MacDonald wrote:


Personally I've never seen significant digit aritmetic (which
is only meaningful for display of numbers) built in to a language.



Where the number of significant digits is some [usually easily
determined] constant, facilities such as 9!:11, etc. are sufficient.
Of course, that's not really significant digit arithmetic.

Where significant digits are not constant, usually it's important
to deal with the issue, and most of the techniques (standard
deviation/variance, interval arithmetic, checking the results
using some form of test, or whatever else) aren't really
significant digit arithmetic.

...which might count as an explanation of what you've seen
(or not seen).



Donna
[EMAIL PROTECTED]





--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
dly wrote:
> Yes thank you this is why I prefaced this with IMD (in my dreams)
> other than with here are all the other great languages that do this

What great languages do this?  While Maple and Mathematica do symbolic
calculations: they are subject to the same problems concerning loss of
signficance when it comes to evaluation.  Plus you pay a huge performance
penalty.

The fact is that you can obtain accurate answers without significant digit
arithmetic, as I have pointed out many times.  However, you need something
different from a naive algorithm.

Bst wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly
Yes thank you this is why I prefaced this with IMD (in my dreams)  
other than with here are all the other great languages that do this  
and why can't you put this into J


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 6:26 PM, Miller, Raul D wrote:


Randy MacDonald wrote:

Personally I've never seen significant digit aritmetic (which
is only meaningful for display of numbers) built in to a language.


Where the number of significant digits is some [usually easily
determined] constant, facilities such as 9!:11, etc. are sufficient.
Of course, that's not really significant digit arithmetic.

Where significant digits are not constant, usually it's important
to deal with the issue, and most of the techniques (standard
deviation/variance, interval arithmetic, checking the results
using some form of test, or whatever else) aren't really
significant digit arithmetic.

...which might count as an explanation of what you've seen
(or not seen).

--
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Miller, Raul D
Randy MacDonald wrote:
> Personally I've never seen significant digit aritmetic (which
> is only meaningful for display of numbers) built in to a language.

Where the number of significant digits is some [usually easily
determined] constant, facilities such as 9!:11, etc. are sufficient.
Of course, that's not really significant digit arithmetic.

Where significant digits are not constant, usually it's important
to deal with the issue, and most of the techniques (standard
deviation/variance, interval arithmetic, checking the results 
using some form of test, or whatever else) aren't really 
significant digit arithmetic.

...which might count as an explanation of what you've seen
(or not seen).

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread Randy MacDonald

Donna;

Personally I've never seen significant digit aritmetic (which is only 
meningful for display of numbers) built in to a language. I have never used 
Mathematica, MatLab nor Maple, so I could just be sheltered.  I could posit 
building utilities to handle it:


  '12.3' plusSD '.0012'
12
  '12.3' timesSD '45.6'
561

so, it's doable, and the maintainers of one database we resold swore by it, 
but no one seriosly wanted to pay for it as a feature.  I never saw much 
consideration for it beyond first-year science labs.


YMMV, of course.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.73.214/
-(INTP){ gnat }-

- Original Message - 
From: "dly" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Thursday, June 29, 2006 11:08 AM
Subject: Re: [Jgeneral] significant digits



Now this was my original point!

I wanted to know the SIGNIFICANT digits. (oddly enough the subject of  my 
post) and I wanted this to be reflected no matter what the for of  display 
or internal storage.


see my IMD (in my dreams) post


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 12:22 PM, Don Guinn wrote:

I remember something about a convention which has been lost with  the 
advent of computers of writing a number, say "2.5" implied that  the 
measurement was good to a tenth, where "2.500" implied it was  good to a 
thousant.




--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread Eldon Eller

The arc tangent of _1r1 is different from the arc tangent of 1r_1.

Randy MacDonald wrote:


Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

all I can say is they produce the same result when evaluated, but each 
use a different number of keystrokes.


If your question was something else, I apologize for my lack of proper 
attention.


I'm thinking this is different in the case of 1 and 1.1-.1, where

1 = 1.1 - .1
but
([]dr 1){ne}[]dr 1.1-.1

NB. Excuse the APL, I'm being lazy in not looking up the foreign for 
data representation.


(J-note)
 1.1-.1
1.1

was something I had to think about for a bit. Definitely a gotcha.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.130/
-(INTP){ gnat }-

- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Wednesday, June 28, 2006 6:54 PM
Subject: Re: [Jgeneral] significant digits


Yes I do not see how my statement that I do not expect J to resolve  
these problems differs from your statement that it is a programming  
issue and not a language issue.


I merely observe that when one person considered something noise, it  
may not actually meet the definition of noise and may actually  
represent a loss of information.  Obviously it is information not  
interesting to everyone.


I do not grasp why you do not see why I am interested in knowing the 
precision of J before I use it because I think it is somewhat  
analogous to you needing to know the precision of a program I  
produced before you called on it as a subroutine.


What is and is not built in varies by language.  There is much built  
in to J that was not built in to APL.  There may or not be other  
languages that have things built in to them that are not built in to  
J.  This is all that I am trying to discover.


In my experience such a process of discovery could be aided by 
others  who are expert with the language one is trying to explore 
rather than deferring to such time as you my or may not become an 
expert yourself  and such information can be used in decision 
making.  In some cases  however there may be no one with the time or 
inclination to share  such information.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:39 PM, John Randall wrote:


dly wrote:


I am not expecting J to resolve these problems I a merely trying to
ascertain how J has improved from APL and to know its limitations
before thinking of applying it to some problems.



Donna:

In my opinion, what you are getting at is a programming issue, not a
language issue.

All languages can easily represent rational numbers as  
canonicalized pairs
of integers: J happens to have them built-in.  If you need to deal  
with
non canonicalized pairs, it is easy to do that too, although this  
is not

built-in in J.

The matrix similarity questions I mentioned needs the programmer to  
keep
in mind the ring over which the similarity is being constructed.  I  
do not

see how the language is going to do that for you.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm



--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
dly wrote:

> I was unable to execute the phrase you provided for []CT comparison
> tolerance

On 32-bit J, default settings:

   9!:18 ''  NB. get comparison tolerance
5.68434e_14
   2^_44
5.68434e_14
   9!:19 (2^_36)  NB. set it to something else

   9!:18 ''
1.45519e_11
   2^_36
1.45519e_11

Documented at

http://www.jsoftware.com/books/help/dictionary/dx009.htm

or in your local installation.

Best wishes,

John



--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Miller, Raul D
Donna L.Y. wrote:
> If you have a further reference about the internal representation of  
> various numbers and constants such as 1p1 I would be greatful if you  
> send me a link.

http://www.jsoftware.com/books/help/dictionary/dx003.htm

   i2hex=:3!:3
   i2hex 1p1
e100
0800
0100

182d4454
fb210940

-- 
Raul


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly

Dear John et al

The quote from Raul below is the sort of information I am seeking  
whether in documentation or in phrases of J that I can use.


I was unable to execute the phrase you provided for []CT comparison  
tolerance


I have not yet tried the phrase someone else provided to correct this

As I mentioned in an earlier post some of your answers will make  
sense to me as I try them which I am doing.


Thanks for your attention to these questions.

If you have a further reference about the internal representation of  
various numbers and constants such as 1p1 I would be greatful if you  
send me a link.  Otherwise I will ask a question with a new subject  
as it arises.


Thanks
Donna



On 28-Jun-06, at 9:47 PM, Miller, Raul D wrote:


After all, internally, the number 1r3 is represented as something
analogous to (<(,1);,3), and the number 11r37 is represented
as something analogous to (<111 111;333 337).  If J can do that
internally, is there some reason why application code can't resort
to similar measures?




Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 2:35 PM, John Randall wrote:


dly wrote:

Now this was my original point!

I wanted to know the SIGNIFICANT digits. (oddly enough the subject of
my post) and I wanted this to be reflected no matter what the for of
display or internal storage.

see my IMD (in my dreams) post




Donna:

I understand your concern about significant digits.  I thought I'd
addressed it in

http://www.jsoftware.com/pipermail/general/2006-June/027472.html

Was there something there that was not clear?

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly
I think that when precision is lost, then accuracy is lost and one  
should not exaggerate  precision or accuracy by advertising what seem  
to be significant digits that are actually not significant


Thus whether you are rounding up the hardness of pencil leads or  
storing a single precision number in a double precision format, you  
should not overstate how significant the digits are.


An integer 1 could be 1.000...
but if you are only 99.99 % sure you might say 1. but no more.   
If you say 1.00 you are overstating your case.


Accuracy will often be lost but by denoting the significance of the  
result it can be evaluated.


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 3:36 PM, Miller, Raul D wrote:


Donna L.Y. wrote;

I wanted to know the SIGNIFICANT digits. (oddly enough the
subject of my post) and I wanted this to be reflected no matter
what the for of display or internal storage.


Significant for accuracy?  Or significant for precision?

In other words: this is indeed a very important issue, but the
relevant details depend on context.

J has a number of features aimed at letting the programmer
express concepts of significant digits, ranging from 9!:11
to dyadic ": and 8!:x

It WOULD be convenient if J could just read my intentions and
intuit what kind of significance is relevant to the problem
I'm trying to address.  In J6, however, I have to express
my intentions in code.

--
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly

Thank you for this reference.

I did not find anything that contradicted my statements but feel free  
to point out the error of anything I say or have said.  I have always  
found error to be an important teacher.



...Aristotle says

... to enjoy error
and to learn
from the juxtaposition of what is and what is not the case

from Men in the Off Hours, by Anne Carson




Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 3:00 PM, John Randall wrote:


Donna:

An integer linear programming reference for you:

http://www-unix.mcs.anl.gov/otc/Guide/faq/linear-programming- 
faq.html#Q3


Best wishes,

John



--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-29 Thread Miller, Raul D
Donna L.Y. wrote;
> I wanted to know the SIGNIFICANT digits. (oddly enough the
> subject of my post) and I wanted this to be reflected no matter
> what the for of display or internal storage.

Significant for accuracy?  Or significant for precision?

In other words: this is indeed a very important issue, but the
relevant details depend on context.

J has a number of features aimed at letting the programmer
express concepts of significant digits, ranging from 9!:11
to dyadic ": and 8!:x

It WOULD be convenient if J could just read my intentions and
intuit what kind of significance is relevant to the problem
I'm trying to address.  In J6, however, I have to express
my intentions in code.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
Donna:

An integer linear programming reference for you:

http://www-unix.mcs.anl.gov/otc/Guide/faq/linear-programming-faq.html#Q3

Best wishes,

John



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 12:29 PM, John Randall wrote:

If you are interested in linear programming (I'm not sure if you  
are, or
whether you were just citing an example), you might want to take a  
look at


I think it is clear what I am interested in.


http://www.jsoftware.com/jwiki/Stories/RichardBrown

which contains an annotated description of using the simplex  
algorithm in J.


Too bad I did not have the time yet to read the entire wiki else I  
could have saved myself the trouble of trying to explain many things  
you alredy knew of and have found a lexicon with which you seem more  
comfortable as well as the J expressions I am not yet able to produce  
quickly enough to include in a reply


so in summary

Dr Brown discusses the simplex method.


On 28-Jun-06, at 2:24 PM, dly wrote:
Unlike the case for general LP problems which are almost  
universally solved by one algorithm


By the magic of modern mathematics it can be shown that the one  
algorithm referred to by dly is the simplex method discussed by Dr Brown


Dr Brown says:

However, there is a catch: if the denominator is zero or negative  
then the constraint should be ignored.


On 28-Jun-06, at 2:24 PM, dly wrote:
there are (were?) large numbers of Integer LP algorithms none of  
which were universally successful in solving LARGE problems.  The  
primary limitation is the number of integer variables so if there  
are more than few hundred variables they cannot be solved except in  
special cases.


Anyway, some methods to approach such problems involve building a  
simplex plateau as for general problems but with only integer  
elements and this property must be maintained at each iteration.   
INTEGER not RATIONAL, but if you are forced at some step to say  
divide 111 by 333 you might want to keep the result as 111r333 and  
go on until a later step where you can get back into an Integer.   
You are best to consult the literature as this is getting quite  
long and I don't seem to be making it clear.




For INTEGER LP problems there is one other catch 22 because you don't  
just have to keep it real or try to be positive you have to keep it  
wholesome


And wouldn't it be nice if there were a convenient notation which  
would help you do this when the result did not turn out to be an  
integer such as 1r3 and wouldn't it be like dreaming in colour if  
better than this it could tell you it was actually 111r333 because  
that would be the cat's meow


QED



More generally, you will probably learn more from trying a solve a
familiar problem in J than from any amount of discussion here.


Au contraire.

Who would have thought that 18 years after the fact I would get to  
continue my discussion with Dr Brown--I am elated.  (Of course,  
subject to debate and I might also be wrong because you see I'm no  
expert.


Thank you very very much!

Donna
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
dly wrote:
> Now this was my original point!
>
> I wanted to know the SIGNIFICANT digits. (oddly enough the subject of
> my post) and I wanted this to be reflected no matter what the for of
> display or internal storage.
>
> see my IMD (in my dreams) post
>


Donna:

I understand your concern about significant digits.  I thought I'd
addressed it in

http://www.jsoftware.com/pipermail/general/2006-June/027472.html

Was there something there that was not clear?

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly

Now this was my original point!

I wanted to know the SIGNIFICANT digits. (oddly enough the subject of  
my post) and I wanted this to be reflected no matter what the for of  
display or internal storage.


see my IMD (in my dreams) post


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 12:22 PM, Don Guinn wrote:

I remember something about a convention which has been lost with  
the advent of computers of writing a number, say "2.5" implied that  
the measurement was good to a tenth, where "2.500" implied it was  
good to a thousant.




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
Don Guinn wrote:

> When in the forth or fifth grade my teacher was trying to explain the
> difference between pencil leads "2 1/2" verses those rated at "2.5". It
> went something like this: Pencils with a lead of "2 1/2" meant that the
> hardness was somewhere between "2 1/4" and "2 3/4", where a hardness of
> "2.5" meant it was between "2.45" and "2.55". I seem to remember seeing
> some pencils with a hardness of "2 2/4" also. I couldn't tell any
> difference on how the pencils worked.
>
> I remember something about a convention which has been lost with the
> advent of computers of writing a number, say "2.5" implied that the
> measurement was good to a tenth, where "2.500" implied it was good to a
> thousant.
>

I recall this convention too.  You see a variant in old science fiction
books, where accuracy is stated in terms like "nine nines".

I believe the difference in pencil designations, while a good
illustration, is a way of avoiding trademark issues.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread John Randall
Donna:

Let me try to summarize some of this discussion and suggest a direction to
move forward.

Any computer can represent only finitely many numbers.  Whether they be
integer, floating point, or rational, there are infinitely many quantities
than cannot be represented exactly.  There is nothing special about J in
this regard: any language has similar expressiveness and limitations,
although the details will vary.  As a side issue, a programmer can
represent a rational number as a numerator/denominator pair without
canonicalization: this is an implementation decision, and has nothing to
do with the language.   Questions about representations of numbers can be
answered through reference to any familiar language.

There are techniques that can be used to obtain accurate results despite
these limitations: this is what numerical analysis is about.

If you are interested in linear programming (I'm not sure if you are, or
whether you were just citing an example), you might want to take a look at

http://www.jsoftware.com/jwiki/Stories/RichardBrown

which contains an annotated description of using the simplex algorithm in J.

More generally, you will probably learn more from trying a solve a
familiar problem in J than from any amount of discussion here.  Otherwise
it is like trying to understand swimming by talking about it rather than
getting your feet wet.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread Don Guinn

Randy MacDonald wrote:


Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

. . .


When in the forth or fifth grade my teacher was trying to explain the 
difference between pencil leads "2 1/2" verses those rated at "2.5". It 
went something like this: Pencils with a lead of "2 1/2" meant that the 
hardness was somewhere between "2 1/4" and "2 3/4", where a hardness of 
"2.5" meant it was between "2.45" and "2.55". I seem to remember seeing 
some pencils with a hardness of "2 2/4" also. I couldn't tell any 
difference on how the pencils worked.


I remember something about a convention which has been lost with the 
advent of computers of writing a number, say "2.5" implied that the 
measurement was good to a tenth, where "2.500" implied it was good to a 
thousant.


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-29 Thread dly


Donna
[EMAIL PROTECTED]



On 29-Jun-06, at 4:43 AM, Randy MacDonald wrote:

If your question was something else, I apologize for my lack of  
proper attention.




Your apology is accepted.

On 29-Jun-06, at 4:43 AM, Randy MacDonald wrote:

If your original question was:

What is the difference between
  1r3
and
  111r333


This was not my question at all but a point raised by Gerry Lowry.  I  
merely offered the Integer LP problem as an example of how knowing  
the difference had application.


By the way the profitability of adding or omitting features in J  
could be evaluated as a LP problem.


Following the discussion is better viewed by Subject but here is  
where 111%333 was originally introduced.


On 26-Jun-06, at 7:18 AM, GerryLowry1(905)825-9582 
{AbilityBusinessComputerServices} wrote:

   111 % 333x
1r3
   111x % 333x
1r3
   111x % 333
1r3
   (111 % 333)x
|syntax error
|   (111%333)x
   111 % 333
0.33

(a) 111 divided by 333 reduces to 1 divided by 3
but is not 1 divided by 3 ... hence
   111 % 333x
111r333NB. non reduced representation

(b) x could give something like
   111 % 333x
0....

g.


- Original Message -
From: "Dan Bron" <[EMAIL PROTECTED]>
Sent: Friday, June 23, 2006 9:34 AM


Am I a prodigy?

   365365365365365365x^2
133491850208566925016658299941583225


On 26-Jun-06, at 7:04 AM, GerryLowry1(905)825-9582 
{AbilityBusinessComputerServices} wrote:

Obviously, one can not expect J or any other tool
to express infinite decimal results, however,
it is not unfair to expect some form of common convention, for  
example:


   111 % 333
0.33...

I think J has directives, although I am too much of a novice
to know them ... nevertheless, I would like to see some
non cryptic directives, example:

NOSCIENTIFIC
   111 % 333 * 1
....

regards,
gerry








--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread Randy MacDonald

Donna;

Your posts, while articulate, seem to be veering off into meta-land.

If your original question was:

What is the difference between
  1r3
and
  111r333

all I can say is they produce the same result when evaluated, but each use a 
different number of keystrokes.


If your question was something else, I apologize for my lack of proper 
attention.


I'm thinking this is different in the case of 1 and 1.1-.1, where

1 = 1.1 - .1
but
([]dr 1){ne}[]dr 1.1-.1

NB. Excuse the APL, I'm being lazy in not looking up the foreign for data 
representation.


(J-note)
 1.1-.1
1.1

was something I had to think about for a bit. Definitely a gotcha.

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're doing.
Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.71.130/
-(INTP){ gnat }-

- Original Message - 
From: "dly" <[EMAIL PROTECTED]>

To: "General forum" 
Sent: Wednesday, June 28, 2006 6:54 PM
Subject: Re: [Jgeneral] significant digits


Yes I do not see how my statement that I do not expect J to resolve  these 
problems differs from your statement that it is a programming  issue and 
not a language issue.


I merely observe that when one person considered something noise, it  may 
not actually meet the definition of noise and may actually  represent a 
loss of information.  Obviously it is information not  interesting to 
everyone.


I do not grasp why you do not see why I am interested in knowing the 
precision of J before I use it because I think it is somewhat  analogous 
to you needing to know the precision of a program I  produced before you 
called on it as a subroutine.


What is and is not built in varies by language.  There is much built  in 
to J that was not built in to APL.  There may or not be other  languages 
that have things built in to them that are not built in to  J.  This is 
all that I am trying to discover.


In my experience such a process of discovery could be aided by others  who 
are expert with the language one is trying to explore rather than 
deferring to such time as you my or may not become an expert yourself  and 
such information can be used in decision making.  In some cases  however 
there may be no one with the time or inclination to share  such 
information.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:39 PM, John Randall wrote:


dly wrote:

I am not expecting J to resolve these problems I a merely trying to
ascertain how J has improved from APL and to know its limitations
before thinking of applying it to some problems.



Donna:

In my opinion, what you are getting at is a programming issue, not a
language issue.

All languages can easily represent rational numbers as  canonicalized 
pairs

of integers: J happens to have them built-in.  If you need to deal  with
non canonicalized pairs, it is easy to do that too, although this  is not
built-in in J.

The matrix similarity questions I mentioned needs the programmer to  keep
in mind the ring over which the similarity is being constructed.  I  do 
not

see how the language is going to do that for you.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm




--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread dly


Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:47 PM, Miller, Raul D wrote:


Donna L.Y. wrote:

Here are some examples of the class of problems that I am referring
to when I concurred that it might be interesting to know the
difference between 1r3 and 111r333: ...


Why do you phrase this issue that way?


sorry if is the source of confusion.  What I might want is to know if  
the result is an integer and if if is not, what were the integers  
involved.


yes I know this is not J's problem to resolve.  But before J  
introduced 1r3, that was not J's problem (solution) either




Why not phrase it as, for example, the difference between the ratio
represented by 1 3 and the ratio represented by 111 333.  Or, as
the difference between the expression '1%3' and the expression
'111%333'.  Or append the letter 'x' to those expressions.  Or,
I am not looking at differences where there are in fact no  
differences--I am trying to make sure for example that I don't have a  
solution that cuts a human being into thirds after which they don't  
function very well



...

?

After all, internally, the number 1r3 is represented as something
analogous to (<(,1);,3), and the number 11r37 is represented
as something analogous to (<111 111;333 337).  If J can do that
internally, is there some reason why application code can't resort
to similar measures?

P.S. in your earlier message, where you wrote:

Max μ = α,χ


notation, notation, notation

this means in plain english (as well as I can manage it)
Maximize the arbitrarily named μ which could be named Z or  
Rumplestilskin




you did not define μ.  Perhaps you mean that μ is an n element
vector where the ith element of μ is either the ith element of
α or the ith element of χ, whichever is larger.  But the notation
I'm familiar with would have expressed that as μ = Max α,χ, and
that still would not indicate the relevance of μ to the problem.
(And, yes, I could probably look this up, but I'm not very
energetic at the moment.)

Apparently I enjoy wasting my energy



Anyways... clarification needed...


Sorry for tongue in check answers--it would be better if they made  
you laugh or you otherwise ignored the whole thing as no reply is  
required.  I will simply keep trying to discover what I need and you  
can keep doing whatever


Thanks for your contribution most especially in letting me know how  
my post could be misinterpreted which is very helpful to me.


--
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread dly
Yes I do not see how my statement that I do not expect J to resolve  
these problems differs from your statement that it is a programming  
issue and not a language issue.


I merely observe that when one person considered something noise, it  
may not actually meet the definition of noise and may actually  
represent a loss of information.  Obviously it is information not  
interesting to everyone.


I do not grasp why you do not see why I am interested in knowing the  
precision of J before I use it because I think it is somewhat  
analogous to you needing to know the precision of a program I  
produced before you called on it as a subroutine.


What is and is not built in varies by language.  There is much built  
in to J that was not built in to APL.  There may or not be other  
languages that have things built in to them that are not built in to  
J.  This is all that I am trying to discover.


In my experience such a process of discovery could be aided by others  
who are expert with the language one is trying to explore rather than  
deferring to such time as you my or may not become an expert yourself  
and such information can be used in decision making.  In some cases  
however there may be no one with the time or inclination to share  
such information.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 9:39 PM, John Randall wrote:


dly wrote:

I am not expecting J to resolve these problems I a merely trying to
ascertain how J has improved from APL and to know its limitations
before thinking of applying it to some problems.



Donna:

In my opinion, what you are getting at is a programming issue, not a
language issue.

All languages can easily represent rational numbers as  
canonicalized pairs
of integers: J happens to have them built-in.  If you need to deal  
with
non canonicalized pairs, it is easy to do that too, although this  
is not

built-in in J.

The matrix similarity questions I mentioned needs the programmer to  
keep
in mind the ring over which the similarity is being constructed.  I  
do not

see how the language is going to do that for you.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-28 Thread Miller, Raul D
Donna L.Y. wrote:
> Here are some examples of the class of problems that I am referring  
> to when I concurred that it might be interesting to know the  
> difference between 1r3 and 111r333: ...

Why do you phrase this issue that way?

Why not phrase it as, for example, the difference between the ratio
represented by 1 3 and the ratio represented by 111 333.  Or, as
the difference between the expression '1%3' and the expression
'111%333'.  Or append the letter 'x' to those expressions.  Or,
...

?

After all, internally, the number 1r3 is represented as something
analogous to (<(,1);,3), and the number 11r37 is represented
as something analogous to (<111 111;333 337).  If J can do that
internally, is there some reason why application code can't resort
to similar measures?

P.S. in your earlier message, where you wrote:

Max μ = α,χ

you did not define μ.  Perhaps you mean that μ is an n element
vector where the ith element of μ is either the ith element of
α or the ith element of χ, whichever is larger.  But the notation
I'm familiar with would have expressed that as μ = Max α,χ, and
that still would not indicate the relevance of μ to the problem.
(And, yes, I could probably look this up, but I'm not very
energetic at the moment.)

Anyways... clarification needed...

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread John Randall
dly wrote:
> I am not expecting J to resolve these problems I a merely trying to
> ascertain how J has improved from APL and to know its limitations
> before thinking of applying it to some problems.
>

Donna:

In my opinion, what you are getting at is a programming issue, not a
language issue.

All languages can easily represent rational numbers as canonicalized pairs
of integers: J happens to have them built-in.  If you need to deal with
non canonicalized pairs, it is easy to do that too, although this is not
built-in in J.

The matrix similarity questions I mentioned needs the programmer to keep
in mind the ring over which the similarity is being constructed.  I do not
see how the language is going to do that for you.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread dly
I am not expecting J to resolve these problems I a merely trying to  
ascertain how J has improved from APL and to know its limitations  
before thinking of applying it to some problems.


I will need to look up your terminology to understand you.  I also  
seem to be missing part of the thread of the conversation.


Here are some examples of the class of problems that I am referring  
to when I concurred that it might be interesting to know the  
difference between 1r3 and 111r333:


The work of Gomory and Hu dates from the 1960’s when they studied a  
minimum network creation problem.   They modeled a network with a  
single commodity that had asynchronous flow requirements.  The  
problem is to assign sufficient capacity on each edge of the network  
to accommodate the flow requirements one at a time, at the minimum  
possible cost.  They used a special case of uniform costs and ignored  
complicated constraints which would make the problem much harder to  
solve.


A more complicated example is a network loading problem seeking to  
meet point to point demand between paired nodes with capacity at the  
edges and with demands to be met simultaneously.  There is interest  
in for example in finding bottlenecks or in case of failure,  
rerouting over subnetworks and other types of sensitivity analysis.


Initial steps can aim to find feasible solutions and then various  
methods are used to optimize even if an optimal solution cannot be  
proved.


I do not know all the details beyond this because I leave that to  
experts.


Thanks

Donna
[EMAIL PROTECTED]



On 28-Jun-06, at 6:49 PM, John Randall wrote:


John Randall wrote:


This corresponds to converting a matrix to Smith normal form over the
integers, versus diagonalizing it over the rationals.  I agree  
that one
might think of this as the difference between 111r333 and 1r3, but  
it does
not really have to do with computer representation of rationals:  
it is
more that the integers form a principal ideal domain while the  
rationals

do not.


Although I got Donna's point, the above is garbled: obviously Z and  
Q are

both PIDs.  What I meant to say is:

Given an integer matrix, there may be a difference in its Smith normal
forms when it is considered as a matrix over Z (which corresponds  
to the

"111r333-:1r3" case) and as a matrix over Q (which corresponds to
"111r333-:1r3").  From Donna's description, I believe the problem lies
here rather than in representations of rational numbers.

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread John Randall
John Randall wrote:

> This corresponds to converting a matrix to Smith normal form over the
> integers, versus diagonalizing it over the rationals.  I agree that one
> might think of this as the difference between 111r333 and 1r3, but it does
> not really have to do with computer representation of rationals: it is
> more that the integers form a principal ideal domain while the rationals
> do not.

Although I got Donna's point, the above is garbled: obviously Z and Q are
both PIDs.  What I meant to say is:

Given an integer matrix, there may be a difference in its Smith normal
forms when it is considered as a matrix over Z (which corresponds to the
"111r333-:1r3" case) and as a matrix over Q (which corresponds to
"111r333-:1r3").  From Donna's description, I believe the problem lies
here rather than in representations of rational numbers.

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread John Randall
John Randall wrote:

> This corresponds to converting a matrix to Smith normal form over the
> integers, versus diagonalizing it over the rationals.  I agree that one
> might think of this as the difference between 111r333 and 1r3, but it does
> not really have to do with computer representation of rationals: it is
> more that the integers form a principal ideal domain while the rationals
> do not.

Although I got Donna's point, the above is garbled: obviously Z and Q are
both PIDs.  What I meant to say is:

Given an integer matrix, there may be a difference in its Smith normal
forms when it is considered as a matrix over Z (which corresponds to the
"111r333-:1r3" case) and as a matrix over Q (which corresponds to
"111r333-:1r3").  From Donna's description, I believe the problem lies
here rather than in representations of rational numbers.

Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread John Randall
Donna:

I finally get your point: see below.  Sorry it has taken so long.

> dly wrote:
> Anyway, some methods to approach such problems involve building a
> simplex plateau as for general problems but with only integer
> elements and this property must be maintained at each iteration.
> INTEGER not RATIONAL, but if you are forced at some step to say
> divide 111 by 333 you might want to keep the result as 111r333 and go
> on until a later step where you can get back into an Integer.  You
> are best to consult the literature as this is getting quite long and
> I don't seem to be making it clear.
>

This corresponds to converting a matrix to Smith normal form over the
integers, versus diagonalizing it over the rationals.  I agree that one
might think of this as the difference between 111r333 and 1r3, but it does
not really have to do with computer representation of rationals: it is
more that the integers form a principal ideal domain while the rationals
do not.  However, I do get what you are driving at.


Best wishes,

John


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-28 Thread dly


John

Sorry.  In your earlier post it was the IBM vector processor that you  
wanted to know more about.  The additional information about integer  
linear programming was for the information of those that were not as  
familiar with it as you.



If I was up to speed in J perhaps I could give a J example--if anyone  
can please jump in.


A standard linear problem (not in J )is given- by equations:

Max μ = α,χ
Αχ=β
χ≥Ο

Where Α is an m x n shaped matrix, α and χ are vectors of length n  
and β is a vector of length m and Ο is 0 vector.

It is easy to see this can be expressed in J or APL.

There are many situations  where it does not make sense for these  
variables to assume other than INTEGER values such as how many  
machines do you need, how many people should you assign to a task to  
produce the shortest schedule, or how many houses should you build,  
how many stocks should you buy/sell to yield the largest profit.


Unlike the case for general LP problems which are almost universally  
solved by one algorithm there are (were?) large numbers of Integer LP  
algorithms none of which were universally successful in solving LARGE  
problems.  The primary limitation is the number of integer variables  
so if there are more than few hundred variables they cannot be solved  
except in special cases.


Anyway, some methods to approach such problems involve building a  
simplex plateau as for general problems but with only integer  
elements and this property must be maintained at each iteration.   
INTEGER not RATIONAL, but if you are forced at some step to say  
divide 111 by 333 you might want to keep the result as 111r333 and go  
on until a later step where you can get back into an Integer.  You  
are best to consult the literature as this is getting quite long and  
I don't seem to be making it clear.


Perhaps you can find discussions of why the performance of Gormory's  
algorithms which were some of the most effective were completely  
unpredictable.


I had a discussion recently with a Canadian economist who was  
completely dismissive of Computer Analysts and on further discussion  
it may have been due to the inability of any that he had worked with  
to grasp these details.  I was thinking in the back of my mind how Dr  
Iverson had told me that his initial motivation for arrays in APL  
were due to his work with Leontief.  I wondered if J would be able to  
improve these results.  Anyway, I am not sure if any of this suggests  
an answer to your question.


http://www.news.harvard.edu/gazette/1999/02.11/leontief.html

On 27-Jun-06, at 8:28 PM, John Randall wrote:


rational numbers (which are defined as equivalence
classes), I still don't see the difference between representatives.



On 27-Jun-06, at 4:42 PM, John Randall wrote:


Could you explain this a little?  I know something about mixed and  
pure

integer linear programming, but nothing about IBM's vector processor.



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-27 Thread John Randall
dly wrote:
[Interesting history deleted]

> In general linear programming models the results can assume any
> values in the feasible region and are allowed to be continuous.
> Altho for some problems such as transportation assignment or network
> flow, integer solutions can be obtained automatically, the extreme
> points of a general linear programming problem is not ordinarily
> restricted to having only integer-valued components.  Moreover one
> cannot merely round the fractional values of an optimal solution and
> expect it to produce the optimal value solution.  In a mixed integer-
> continuous variable problem only some of the variables are required
> to be integers.
>

Donna:

Thanks for this information.  I guess I misunderstood (or am
misunderstanding now): you first raised the linear programming/vector
processor issue as an example as to why 111r333 contained more information
than 1r3.  I completely agree that approximating a rational number by a
floating point number may be inappropriate in some circumstances, however
if we are talking about rational numbers (which are defined as equivalence
classes), I still don't see the difference between representatives.

The rational type in J can be useful, but it is easily added to any
language.  In fact a rational number class is a common exercise in OOP
courses, especially if the language has operator overloading.

By the way, floating point numbers are rational, too: in fact 64 bit
floating point numbers represent more rational numbers than <32 bit
integers>r<32 bit integers>.  So you also have the reverse problem:
approximating a floating point number by a rational.  More generally, the
fact that finitely many rational numbers tell us anything about
uncountably many real numbers is remarkable in itself.

Best wishes,

John



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-27 Thread dly
Being rusty and went to my bookshelf for a relevant text which is  
circa 1974 and will give you an idea of how rusty my math may be.


I did not have the chance to use IBM's vector processor but it was  
first described to me over lunch by Dr James Brown of IBM in 1988 I  
believe on the occasion of a presentation of a new version of APL2.   
(I might add that my IBM rep had simply introduced him as Jim Brown  
and I had no idea of his role in APL2 until the presentation that  
followed).  He provided several illustrations of how APL2 was able to  
take immediate advantage of the vector processor--which I envision as  
a very special math coprocessor for the mainframe aimed at speeding  
computation by performing calculations in parallel  that had  
previously been done seriatim due to Von Newman architecture. The APL  
language, expressing everything in arrays that could be raveled to  
vectors, could take immediate advantage of this.


He then mentioned an application that seemed to me to require an  
Integer Linear Programming algorithm but did not mention having made  
any special provision for this and when I questioned him on this  
point he seemed confused and I realized that he was discussing an  
application of one of his customers and early adopters of the IBM  
Vector processor and was unfamiliar with what constraints their  
actual application might require.  Our lunch needed to be adjourned  
because it was time for the presentation to begin.  I was too  
embarrassed, on learning who I had been debating with to pursue my  
questioning after the proceedings.


In the text it states that no algorithm (i.e. in 1974) has shown  
itself to consistently solve large integer programming problems.


In general linear programming models the results can assume any  
values in the feasible region and are allowed to be continuous.   
Altho for some problems such as transportation assignment or network  
flow, integer solutions can be obtained automatically, the extreme  
points of a general linear programming problem is not ordinarily  
restricted to having only integer-valued components.  Moreover one  
cannot merely round the fractional values of an optimal solution and  
expect it to produce the optimal value solution.  In a mixed integer- 
continuous variable problem only some of the variables are required  
to be integers.


At the time (1974), there were three classes of algorithms (1)  
cutting plane, (2) enumeration and (3) partitioning used as  
additional constraints to ensure the solution or feasible region has  
the desired integer properties.  I was thus interested in 1988 and  
again interested today in 2006 if there has been progress.


This is the reason I want to clearly understand limits and  
constraints of any algorithms underlying any primitives of J.



Donna
[EMAIL PROTECTED]



On 27-Jun-06, at 4:42 PM, John Randall wrote:


Donna L.Y. wrote:

This information is extremely relevant to an integer Linear
Programming model a point apparently lost on some early users of
IBM's vector processor.


Donna:

Could you explain this a little?  I know something about mixed and  
pure

integer linear programming, but nothing about IBM's vector processor.

Thanks,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-27 Thread John Randall
>> Donna L.Y. wrote:
>>> This information is extremely relevant to an integer Linear
>>> Programming model a point apparently lost on some early users of
>>> IBM's vector processor.

Donna:

Could you explain this a little?  I know something about mixed and pure
integer linear programming, but nothing about IBM's vector processor.

Thanks,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-27 Thread Miller, Raul D
Donna L.Y. wrote:
> My observation was to provide an illustration of relevance and not a
> request to dump extraneous features into scalar numbers in J
>
> It is a welcome innovation of J to denote 1r3 which is only relevant
> in certain instances and otherwise fine as 0.33 .

Ah... I think you're talking about the extra precision of
rational numbers (when compared to floating point numbers)?

> In general, not understanding is a legitimate request for information
> but not a refutation of another point of view.

I apologize if it seemed like I was attempting to refute your point
of view.

I was attempting to address several potential points which had been
raised in this thread.  The "refutation" was aimed at a point which
was independent of the issue you were talking about.

[In other words, my "I may not understand" comment should be read,
in retrospect, as "I did not understand", and should be taken to 
mean that the following comments were not relevant to your point.]

Thanks,

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-27 Thread dly
My observation was to provide an illustration of relevance and not a  
request to dump extraneous features into scalar numbers in J


It is a welcome innovation of J to denote 1r3 which is only relevant  
in certain instances and otherwise fine as 0.33 .  I am told this  
is included specifically because its relevance to musicians was  
suggested to Ken Iverson by David Steinbrook.


My daughter, an architecture student, told me this weekend that she  
went on a course to learn about some rendering tools only to find  
that the application required you to denote drawings in a programming  
language rather than by drawing techniques.  The application's  
creator not only could not understand her explanation of how this  
could be achieved, but was completely dismissive.  She told me she  
knew I would never do that.


In general, not understanding is a legitimate request for information  
but not a refutation of another point of view.


Donna
[EMAIL PROTECTED]



On 27-Jun-06, at 3:42 PM, Miller, Raul D wrote:


Donna L.Y. wrote:

This information is extremely relevant to an integer Linear
Programming model a point apparently lost on some early users of
IBM's vector processor.


I probably do not understand what information you are trying to
refer to.

If you need to know that 1r3 came from 111%333 then you should
have retained the original values.  Talking about 111r333 as
something distinct from 1r3 might be a convenient shorthand in
some application domains, but it's the job of the programmer
to make sure that the proper information is used in the right
fashion.  You don't need to dump lots of features into scalar
numbers to accomplish that.

--
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-27 Thread Miller, Raul D
Donna L.Y. wrote:
> This information is extremely relevant to an integer Linear  
> Programming model a point apparently lost on some early users of  
> IBM's vector processor.

I probably do not understand what information you are trying to
refer to.

If you need to know that 1r3 came from 111%333 then you should
have retained the original values.  Talking about 111r333 as
something distinct from 1r3 might be a convenient shorthand in
some application domains, but it's the job of the programmer
to make sure that the proper information is used in the right
fashion.  You don't need to dump lots of features into scalar
numbers to accomplish that.

-- 
Raul

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-27 Thread dly
This information is extremely relevant to an integer Linear  
Programming model a point apparently lost on some early users of  
IBM's vector processor.


Donna
[EMAIL PROTECTED]



On 27-Jun-06, at 2:57 PM, Miller, Raul D wrote:


is a loss of information, i.e., the fact that
one is dividing 111 by 333.

In most cases, such a loss of factual information is irrelevant.


In most cases, it's better than irrelevant -- this loss of
information is a tremendously good thing.

Most of the time, the information that is lost is noise -- and if
you need to know the exact expression, you can go look at the
original script.


--
For information about J forums see http://www.jsoftware.com/forums.htm


RE: [Jgeneral] significant digits

2006-06-27 Thread Miller, Raul D
Gerry Lowry wrote:
> 1  111
> _and   __
> 3  333
>
> are equivalentBUT
>
> when the first fraction is used to represent
> the second fraction, as in   1r3   then there
> is a loss of information, i.e., the fact that
> one is dividing 111 by 333.
>
> In most cases, such a loss of factual information is irrelevant.

In most cases, it's better than irrelevant -- this loss of
information is a tremendously good thing.

Most of the time, the information that is lost is noise -- and if
you need to know the exact expression, you can go look at the
original script.  If you need to know the date and time when the
operation was invoked, you can record that in user defined code.
Etc.

Of course, if you go that route, you'll have to think deeply
about what it is that you are trying to accomplish.  Is 1+1
performed at 2am the same as 1+1 performed at 3pm?  Is 3 apples
equivalent to 3 oranges?  You could spend forever simply
dealing with the potential issues surrounding the issues 
associate with 0+1.  (Assuming that that's what interests you.)

> Regardless, what I was really attempting to demonstrate
> is that I would rather see
>0....
> in preference to 1r3.

You can write your own formatting verb.  Or, if you could
provide the specs, someone else could write one for you.
(Do you always want to see 32 digits after the decimal
point?  Under what conditions should the ellipses appear?)

-- 
Raul 

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-26 Thread John Randall
dly wrote:
> I am not sure where it is orbiting
>
> There is a concept called significance
>
> knowing the limitations of an algorithm such as it uses double
> precision floating point numbers means that is as precise as it gets
>
> there are other possibilities such as IEEE quadruple-precision
> floating-point data type "quadruple" (128 bits or 16 bytes).
>
> Do you think there is value in knowing whether something is
> calculated with single, double, quadruple precision?
>
> If it is all the same to you then don't worry if it is not all the
> same to me.
>
> Donna
> [EMAIL PROTECTED]
>
>

Donna:

32-bit J uses 64-bit floating point numbers with a 52-bit mantissa (since
it is normalized, this gives 53 bits of precision) and an exponent in the
range -1023 to 1024.

For approximating a single quantity, this translates to about 16 digits of
decimal precision.  An further calculations will have fewer digits of
precision, unpredictably in general.  Permuting the order of terms in
1+1e_16+_1 will give you 0, 1 and 16 digits of decimal precision, even
though each calculation is done using "double precision" arithmetic. 
Simply knowing that this is what the algorithm uses is of little value in
knowing the accuracy of the result.  That is why it is "all the same to
me": you need to do something else to ensure that calculations are
accurate.

People in scientific computing have thought about this issue a lot, and
there are ways of getting good results, although they may not be obvious.
Here is a simple example.  A common beginner's error is to estimate f'(x)
as (f(x+h)-f(x))/h with error O(h f''(x)), as in calculus, and think that
one can get a better result by making h as small as possible.  This
compounds subtracting two nearly equal quantities with dividing a large
number by a small number, almost guaranteeing a loss of significance. 
Using (f(x+h)-f(x-h))/(2h) will give a result with error O(h^2 f'''(x)),
typically allowing a larger value of h for the same accuracy with fewer
truncation problems.

The question "How do I ensure my calculations are accurate?" is too
general to answer.  There are many more specific questions that have good
answers.

Best wishes,

John

--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-26 Thread dly

I am not sure where it is orbiting

There is a concept called significance

knowing the limitations of an algorithm such as it uses double  
precision floating point numbers means that is as precise as it gets


there are other possibilities such as IEEE quadruple-precision  
floating-point data type "quadruple" (128 bits or 16 bytes).


Do you think there is value in knowing whether something is  
calculated with single, double, quadruple precision?


If it is all the same to you then don't worry if it is not all the  
same to me.


Donna
[EMAIL PROTECTED]



On 26-Jun-06, at 2:04 PM, Don Guinn wrote:

John, isn't this whole thread revolving around what is a correct  
value? To me it looks like a good part of this discussion revolve  
around many J primitives converting to double precision floating  
point resulting in a loss of precision. Are you defining a  
calculation as "correct" if the result is the closest number  
representable in a double precision floating point number to the  
result if calculated in infinite precision? This may not be  
sufficient in some calculations. But that's as good as it gets in  
most programming languages and is usually more than adequate. The  
problem is that it is not always adequate. And that's as you say,  
it's a numerical analysis question.


Perhaps the possible coming of arbitrary precision numbers (or  
whatever they're called) in J might address many of the concerns in  
this thread.


John Randall wrote:

As I mentioned in an early post, you can assume that J library  
functions
return correct values.  As soon as you manipulate them in any way,  
it is
your algorithm.  My prior example showed how even + can be ill- 
behaved. An I/O logical analyzer is not going to help: it's a  
numerical analysis

question.

Best wishes,

John

- 
-
For information about J forums see http://www.jsoftware.com/ 
forums.htm






--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-26 Thread John Randall
Randy MacDonald wrote:
> Hello Donna;
>
>>   %/ 111 333
>> 0.33
>>
>
> ...I don't think I see your point. The 111 is lost here as well. I'm sure
> there is a function (r: perhaps?) such that:
>
>111 r: 333
>
> is the same(which, of course, is a meta-J notion) as
>
>111r333
>
  %/ x: 111 333
1r3


John



--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-26 Thread Dan Bron
In general, if you have specific questions about your data, ask them.  
Depending on the display is dangerous.  Never mind print precision, or even 
telling character from a number, a scalar from a vector, or one empty from 
another.  Sometimes you can't even tell a noun from a verb!  

Trust no one, Scully.

-Dan
--
For information about J forums see http://www.jsoftware.com/forums.htm


Re: [Jgeneral] significant digits

2006-06-26 Thread dly

Never mind

just lame response to lame response

Donna
[EMAIL PROTECTED]



On 26-Jun-06, at 2:38 PM, Randy MacDonald wrote:


Hello Donna;


  %/ 111 333
0.33



...I don't think I see your point. The 111 is lost here as well.  
I'm sure there is a function (r: perhaps?) such that:


  111 r: 333

is the same(which, of course, is a meta-J notion) as

  111r333

-- 
--

|\/| Randy A MacDonald   | APL: If you can say it, it's done.. (ram)
|/\| [EMAIL PROTECTED]  |
|\ | |If you cannot describe what you are doing
BSc(Math) UNBF'83þas a process, you don't know what you're  
doing.

Sapere Aude  | - W. E. Deming
Natural Born APL'er  | Demo website: http://156.34.90.191/
-(INTP) 
{ gnat }-


- Original Message - From: "dly" <[EMAIL PROTECTED]>
To: "General forum" 
Sent: Monday, June 26, 2006 11:05 AM
Subject: Re: [Jgeneral] significant digits



Donna
[EMAIL PROTECTED]



On 26-Jun-06, at 1:58 PM, Randy MacDonald wrote:



I would prefer the shorter answer. The two item list:

  111 333

does preserve the original terms, but hides the division  
operation. Trade-off city...


- 
-
For information about J forums see http://www.jsoftware.com/ 
forums.htm



--
For information about J forums see http://www.jsoftware.com/forums.htm


--
For information about J forums see http://www.jsoftware.com/forums.htm


  1   2   >