My understanding is that by using 'cap' you are definitely using a fork,
but 'capping' the one end of it!

So whereas (f b g) y  would give you something like
   fy b gy  (where b is an infix operator and f and g are unary)
then, ([: b g) y would become something like
  b of gy   so you end up with a function composition, as b is rendered
unary

Hey, I told you my explanations weren't elegant....

Personally I prefer using @ or @: as it maps closer to functional
composition.
But cap is fine too.



On 14 October 2012 02:06, Keith Park <[email protected]> wrote:

> Thanks.  Cap is sort of what I was looking for.  A bit ugly though, but I
> suppose it is the price to pay for not having some sort of operator to
> deliberately invoke a hook or a fork.
>
> On Sat, Oct 13, 2012 at 7:57 PM, alexgian <[email protected]>
> wrote:
>
> > I asked this question almost three years ago, when I was first starting.
> > Almost the same people answered it, and quite at length, too!
> >
> > If you want some explanations on the options of composing using the 'cap'
> > ([:) or the compose (@) you can look here:
> > http://jsoftware.com/pipermail/programming/2010-February/<
> > http://jsoftware.com/pipermail/programming/2010-February/018214.html>
> > search using  "composing without forking (% +/ %)"
> > Unfortunately it is not too easy to search old mails.
> >
> > It is probably also worth understanding the "under" verb, and why
> > resistances in parallel are the same concept as "sumation *under*
> > inversion" ,  given by  (+/ &.: %)
> >
> > The differences between @ and @:, and also between &. and &.:  have to do
> > with rank, I leave their explanation, should you need it, to those more
> > elegant than I
> > ----------------------------------------------------------------------
> > 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