Bo is correct
There is a "zero rule" so n^0 =1 if n is not equal to 0. Bo is correct
the only possible 0^0 is the same as 0*0
Possibly the coding for ^ should take this into account.
On 2020-02-05 10:14 p.m., Skip Cave wrote:
Bo,
The original equation is:
(x^x)=2*x
2 is clearly a root. 0 is clearly not, as 0^0 = 1
Skip Cave
On Wed, Feb 5, 2020 at 2:37 PM 'Bo Jacoby' via Programming <
programm...@jsoftware.com> wrote:
Skip. (x^x)-(2*x) = x*(x-2) is zero for x=0 and x=2. Two real roots.
Newton Raphson finds one of these depending on the value of the initial
guess.
Bo.
Den onsdag den 5. februar 2020 19.08.23 CET skrev Henry Rich <
henryhr...@gmail.com>:
Yeah, a rational y wouldn't ever quite satisfy 0 = _2 0 1 p. y
Henry Rich
On 2/5/2020 1:04 PM, Devon McCormick wrote:
You especially need guardrails if you try something like this:
_2 0 1&p. Newton 1 NB. OK - square root of 2
1.41421
_2 0 1&p. Newton 1x NB. Try extended precision
C-c C-c|break NB. After waiting a while...
| _2 0 1&p.Newton 1
NB. Failure to terminate...
On Wed, Feb 5, 2020 at 7:34 AM Henry Rich <henryhr...@gmail.com> wrote:
I misread your function.
(^~ - +:) Newton 1.1
0.346323j1.2326e_32
(^~ - +:) Newton 0.5
0.346323
Still need those guardrails!
Henry Rich
On 2/5/2020 2:21 AM, Skip Cave wrote:
In "Fifty Shades of J" chapter 23, the Newton Raphson algorithm is
described thusly:
Newton =: adverb : ']-u%(u D.1)'(^:_)("0)
How would that be defined using the new derivative verbs?
Also, what is the replacement for d.?
How would I find the roots of (x^x)=2*x using Newton Raphson?
Skip
Skip Cave
Cave Consulting LLC
----------------------------------------------------------------------
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
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm