Linda, you can define log =: 13 : '(^. y) % ^. x'
which I bet is the way dyadic ^. is defined. 10 log 10^i:2 _2 _1 0 1 2 1j2 log 1j2^i:2 _2j_1.45289e_16 _1j_7.26445e_17 0 1 2j1.45289e_16 1j2 ^. 1j2^i:2 _2j_1.45289e_16 _1j_7.26445e_17 0 1 2j1.45289e_16 I suppose it would take special code to get rid of the tiny imaginary parts here. Kip Sent from my iPad On Jan 18, 2013, at 4:33 AM, "Linda Alvord" <lindaalv...@verizon.net> wrote: > Kip, I just got back to a different and interesting sidetrack on this long > thread. What a simple way to write a proof in J. > > _1 = ^ 0j1 * o. 1 > 1 > > (0j1 * o.1) = ^. _1 > 1 > > > Therefore: Negative numbers can have logarithms to the base e > > Can they also have common logs? > > Also, It makes you wonder if there isn't some sequence out there somewhere > where there is an ordered sequence of complex numbers: > > i:2 > _2 _1 0 1 2 > > i:0j2 > > Happy wandering and pondering. > > Linda > > > -----Original Message----- > From: programming-boun...@forums.jsoftware.com > [mailto:programming-boun...@forums.jsoftware.com] On Behalf Of km > Sent: Thursday, January 17, 2013 9:31 AM > To: programm...@jsoftware.com > Subject: Re: [Jprogramming] Hermitian from triangular > > Linda, about logarithms of negative numbers > > First of all, you know the number e =: ^ 1 and you know ^ y is e^y . You > may not know that ^ x j. y by definition is (^ x) * (cos + 0j1 * sin) y > where cos =: 2&o. and sin =: 1&o. . I first learned this in a college > math class called Complex Analysis. A good reference is E. B. Saff and A. > D. Snider, Fundamentals of Complex Analysis, Pearson Education, Inc. 2003. > > Anyway, a famous identity in higher math is > > _1 = ^ 0j1 * o. 1 > 1 > > which should tell you that > > (0j1 * o.1) = ^. _1 > 1 > > i.e., negative numbers can have logarithms to the base e . For more on > this, please see Saff and Snider's Chapter 3. > > Kip Murray > > Sent from my iPad > > > On Jan 17, 2013, at 4:22 AM, "Linda Alvord" <lindaalv...@verizon.net> wrote: > >> Isn't the log of negative numbers indefined? >> >> This is a problem: >> >> %1&o.+0 >> _ >> %1&o.-0 >> _ >> >> This is nice! >> >> %1&o.%_ >> _ >> %1&o.%__ >> __ >> >> >> The csc is very small for negative numbers close to zero and very >> large for very small positive numbers. >> >> Linda >> >> -----Original Message----- >> From: programming-boun...@forums.jsoftware.com >> [mailto:programming-boun...@forums.jsoftware.com] On Behalf Of Bo >> Jacoby >> Sennt: Thursday, January 17, 2013 3:37 AM >> To: programm...@jsoftware.com >> Subject: Re: [Jprogramming] Hermitian from triangular >> >> Henry, How is negative zero different from positive zero when taking >> the log? >> ^.%__ NB. log -0 >> __ >> ^.%_ NB. log +0 >> __ >> >> >> - Bo >> >> >>> ________________________________ >>> Fra: Henry Rich <henryhr...@nc.rr.com> >>> Til: programm...@jsoftware.com >>> Sendt: 0:38 torsdag den 17. januar 2013 >>> Emne: Re: [Jprogramming] Hermitian from triangular >>> >>> Negative zero makes sense as a last vestige of gradual underflow; and >> anyway, it's well-behaved: it looks like 0 except when you take the >> log, reciprocal, or square root. In any normal computation, it goes >> away. In contrast, NaN messes up anything it touches. >>> >>> I think we've had negative 0 in J forever. If NaN is a data virus, >>> -0 is a >> virus that has been inserted into our DNA. >>> >>> Henry Rich >>> >>> On 1/16/2013 4:45 PM, Raul Miller wrote: >>>> On Wed, Jan 16, 2013 at 4:35 PM, Henry Rich <henryhr...@nc.rr.com> > wrote: >>>>> Negative zero isn't a bug, it's a feature that numerical types, >>>>> especially William Kahan, wanted to get into IEEE-754 to help out >>>>> some things. I'm not expert enough to explain. >>>> >>>> Something similar could be said about NaN. >>> --------------------------------------------------------------------- >>> - 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