It's kind of trivial to say that ,: is the right inverse of +/ as +/ is the
same as {. when there is only one item. And J is a little loose on its
handling of inverses as it gives inverses which are not true inverses of
the primitive. It might be only a left or right inverse.

   (%:@*:)1 _1  NB. %: is a left inverse of *:
1 1
   (*:@%:)1 _1  NB. But it is not a right inverse
1 _1
   *: b._1      NB. Therefore this is not correct
%:
                NB. But restricting ] to be non-negative real then it is an
inverse

And the following is obvious but it never occurred to me before

   +/'a'
a


On Fri, Dec 16, 2011 at 9:18 AM, Marshall Lochbaum <mwlochb...@gmail.com>wrote:

> A right/left inverse under the operation of composition. So if
> (+/ @: ri) -: ]
> Then ri is a right inverse to +/ , while if
> (li @: (+/)) -: ]
> li is a left inverse of +/ .
> You can see that a right inverse is trivial (try ,: ) but a left inverse
> doesn't exist, because +/ discards information.
>
> Marshall
>
> On Fri, Dec 16, 2011 at 8:20 AM, Don Guinn <dongu...@gmail.com> wrote:
>
> > I don't understand what you mean by a right and left inverse to +/ .
> >
> > On Thu, Dec 15, 2011 at 7:52 AM, Marshall Lochbaum <mwlochb...@gmail.com
> > >wrote:
> >
> > > Yes, except there are an infinite number of choices. In that sense,
> it's
> > > more like trying to find +/^:_1 . It's easy to find a right inverse of
> > +/ ,
> > > but there's no good choice of a left inverse because you'll be wrong in
> > > most cases. The situation is a little better for #: , but the question
> of
> > > finding an inverse is still fundamentally unsolvable.
> > > We don't really use #: to provide an inverse to #. ; it's more the
> other
> > > way around. We use #: because it allows us to express a number in a
> > > different way which is useful for some applications.
> > >
> > > Marshall
> > >
> > > On Thu, Dec 15, 2011 at 8:19 AM, Don Guinn <dongu...@gmail.com> wrote:
> > >
> > > > Isn't the choice of the representation for #: result a lot like
> picking
> > > the
> > > > principle root?
> > > >
> > > >   %:*:_2
> > > > 2
> > > >   *:%:_2
> > > > _2
> > > >
> > > > The solution to the first expression above should really be _2 2 but,
> > > > though more correct, is impractical in actual problem solving. A
> > similar
> > > > thing occurs with circular functions.
> > > >
> > > >   1 o.0.5+0,o.2
> > > > 0.479426 0.479426
> > > >
> > > > And that is why many proofs restrict functions to be single valued.
> > > >
> > > > On Wed, Dec 14, 2011 at 9:18 PM, Marshall Lochbaum <
> > mwlochb...@gmail.com
> > > > >wrote:
> > > >
> > > > > antibase2 has an inverse only for nonnegative numbers, given by #.
> > > > > twoscomplement's inverse is [:#. (* _1^0=i.@#)"1
> > > > > signwithbits has inverse #.
> > > > >
> > > > > Marshall
> > > > >
> > > > > On Wed, Dec 14, 2011 at 11:10 PM, Kip Murray <k...@math.uh.edu>
> wrote:
> > > > >
> > > > > > Thank you, Raul.  May we have inverses?
> > > > > >
> > > > > > On 12/14/2011 9:13 AM, Raul Miller wrote:
> > > > > > > The subject line of this thread is arguably wrong -- there are
> a
> > > > > > > variety of "good ways" of decomposing integers to binary.
> > > > > > >
> > > > > > > That said, it's interesting to think about the various
> proposals
> > > > > > > expressed in terms similar to those which could be used to
> > > implement
> > > > > > > monadic #:
> > > > > > >
> > > > > > > antibase2=:      #:~    2 #~ 1 + 2<.@^. 1>.>./@,@:|@:<.
> > > > > > > twoscomplement=: #:~    2 #~ 1 + 2<.@^. 1 +>./@,@:|@:<.
> > > > > > > signwithbits=:   #:~ 0, 2 #~ 1 + 2<.@^. 1>.>./@,@:|@:<.
> > > > > > >
> > > > > > > (In all cases the #: here is dyadic, so these definitions are
> > > > > > > independent of the definition of monadic #:)
> > > > > > >
> > > > > > >     antibase2 i: 3
> > > > > > > 0 1
> > > > > > > 1 0
> > > > > > > 1 1
> > > > > > > 0 0
> > > > > > > 0 1
> > > > > > > 1 0
> > > > > > > 1 1
> > > > > > >     twoscomplement i: 3
> > > > > > > 1 0 1
> > > > > > > 1 1 0
> > > > > > > 1 1 1
> > > > > > > 0 0 0
> > > > > > > 0 0 1
> > > > > > > 0 1 0
> > > > > > > 0 1 1
> > > > > > >     signwithbits i: 3
> > > > > > > _1 0 1
> > > > > > > _1 1 0
> > > > > > > _1 1 1
> > > > > > >   0 0 0
> > > > > > >   0 0 1
> > > > > > >   0 1 0
> > > > > > >   0 1 1
> > > > > > >
> > > > > > > There's also (* * #:) but that one assumes the antibase2
> > > > > > implementation...
> > > > > > >
> > > > > >
> > > ----------------------------------------------------------------------
> > > > > > 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
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to