On Thu, Mar 29, 2012 at 2:09 PM, Boyko Bantchev <boyk...@gmail.com> wrote: >>>>> (f∘g)(x) ≡ f(g(x)) >> >> And yet, f and g are not defined here, and neither are x. > > Because of course they need not to. Whatever the domains and codomains > of f and g, they do not change the meaning of composition as defined by > the above identity.
In the original definition, which led us to this point, there was no statement that f and g had domains. > But leave that identity, and consider how the DoJ defines monadic @ : > > u@v y ↔ u v y > > Where are the 'definitions' of u, v, and y? Many places, for example: http://www.jsoftware.com/help/dictionary/intro17.htm http://www.jsoftware.com/help/dictionary/dict3.htm http://www.jsoftware.com/help/dictionary/dictc.htm That said, I am not trying to claim that there are no ambiguities to resolve. >> (And, for that matter, the grammar associated with parenthesis >> are not defined here.) > > This is a ridiculous nitpicking which does not need to be commented > further. Here's an example where it (or some related issue) is relevant: f=: 2 + ] g=: 2 * ] x=: 1 :'@u' f(g(x)) >> Thus, formal definitions depend on the definitions of the symbols used >> in the definition. > > False, as exemplified by the definition of @ quoted above. The issue is "what part of the formal definition is relevant in this context". I know of some examples where this issue matters. But I have not taken time yet to think up a simple example where this matters and where every aspect of the example relates to something useful. >> More generally, Mathematics deals with numerous >> definitions for the symbols it uses. There are numerous branches of >> mathematics, each with their own conventions for these definitions. > > Irrelevant to the discussion of composition and functors. But relevant when presenting that discussion to a broad audience. >>>> One issue, here, is that the definitions of f, g and x are contextual. >>> What do you mean by 'contextual'? >> I mean that, for example, the definition of x depends on the context >> where the phrase that contains x is used. > > Again, how does the definition of @ depend on a 'context'? > (Not that that is the only counter-example available, far from that …) Why are you asking about @ when I was talking about x? Anyways, like I said before: the issue in the context of @ is: which parts of its definition are relevant in the given context. >> In one context, x might be 1 >> In another context, x might be 2 >> ... >> ... > > And again, the context of (f∘g)(x) ≡ f(g(x)) is no different than > that of u@v y ↔ u v y . How is the definition of @ 'contextual'? > Are you saying that, in the second identity, the meaning of @ depends > on what y 'might be'? But no one has claimed that u@v y ↔ u v y is some kind of unambiguous statement for all of Mathematics. And, the rank of f@g for verb f and verb g has the rank of g. Whether this is significant, depends on the definitions involved and the domains under consideration. >> And yet none of these statements were part of that "formal definition". > > Why should they be, if they are assumed anyway. Do you consider > u@v y ↔ u v y 'informal' or broken in some way due to not including the > same trivially assumed statements? I think that formal definitions are ambiguous. I do not think that formal definitions are informal. I do not think that formal definitions are broken. I think ambiguity is a solvable problem in most contexts. >>> How can a function have two different domains without being in fact >>> two different functions? Doesn't make sense to me. >> >> A domain is the set of argument values for which a function is defined. > > So far, correct. > >> A function can have multiple definitions. > > If so, all they are different functions, not one function. This is the case if the definitions conflict. I do not see why I should agree that this is the case when the definitions do not conflict. >> How else can we talk about extending a function defined on >> integers to be a function defined on real numbers? > > By defining a new, different function acting on all reals. > We don't keep and use both at the same time, and no > confusion arises. But we still might use the same symbol to refer to both of them. This is common practice in the field of mathematics. For example, we use sin(x) to refer to the function which finds the sine of x, and we do not use different symbols when x is complex than we use when x is real. >> No ranks are changed. >> The rank of the derived verb will sometimes be different, for >> different sentences. But whether this is a significant issue >> depends on the domain under consideration. > > It is significant enough to make @ and @: different adverbs, which > produce (in general) different verbs from the same arguments. > Hence, as I said, if @ is composition in the mathematical sense, > @: isn't. Frankly I am surprised you are not making the opposite claim: that @: is composition in the mathematical sense and @ is not. >> Your formal definition did not require that a verb be produced. >> So why is this an issue now? > > It did require this in exactly the same sense that u@v y ↔ u v y > does. Which, to me seems to be: not at all. >>> If x is an adverb, so that g(x) is a verb, then f(g(x)) is a hook >>> – again, not a composition. >> I do not know what you are talking about here. > > What is not clear? The example was yours. 1. Where is the hook? 2. What is the rational for saying that f@g represents composition in an earlier case but not in this case? > You took the phrase f(g(x)) with x an adverb and said > that the phrase might represent composition. True. > What I am pointing to is that this cannot be true, > even if f and g are verbs: the result is a hook, and > a hook is never a composition (in the same sense that > @ or its applications are compositions). Except, it's not a hook for the case I defined. The result of that statement is f@g -- which you have declared to be composition. That result is not a hook. If you trace the execution of the example I presented, you will never see a hook. >> If f&g is composition then clearly f(g(x)) is composition. > > False. Not only the two objects are different, they are of different > types. E.g., if f and g are numeric functions, then f&g is also a > numeric function (a verb), while f(g(x)) is a number. I was treating the case where x was a specific adverb. In that specific case, f(g(x)) is a verb. But verbs are not numbers. Here's straight from my J session: x=:1 :'@u' f=: +: g=: *: x=:1 :'@u' f@g f@g f(g(x)) f@g You are claiming that I cannot get that result from J. But J gives me that result. I am not sure why I should believe you. >>> We have to stick to the mathematical meaning of composition because >>> this is what the definition of functor depends on, and we were >>> discussing functors ... >> Except we seem to have new constraints appearing as new examples >> are introduced? > > Examples of what? If of functors, then according to what definition? > Since you were referring to the notion of functor in Haskell, I am > assuming a functor is something that has a fmap function satisfying > the homomorphic identity I quoted – and that relies on the > mathematical, Haskell, ML, etc. understanding of composiion, > represented in J as @ and &. Let's come back to this when we can agree that the result J gives me is in fact the result J gives me? >> Let's consider: >> f @: g >> ... >> So I am not sure what you are trying to say. > > If f and g – and not their modified copies – were subjected to > composition, then the result would be a verb with some rank that > apparently depends on the ranks of f and g. That rank would not > invariably be infinite, as is the case with @:. Therefore, what > @: does is not just a composition (although it resembles one). Here, I think you are making assumptions about the domains. I can agree that those assumptions are sometimes valid. I do not see any reason to agree that those assumptions are always valid. > Moreover, if @: just composed its argument verbs f and g, all of > the following conditions would be kept: > composition is a true one (equivalent to ∘ in mathematics); > f takes part in the composition unmodified; > similar of g; > the verb resulting from composing f on g is left unmodified. ok? > From @: producing verbs of always infinite ranks, it follows that > at least one of the above conditions is violated. > > I really am not sure how precisely @: achieves its result – which > of the said conditions it violates – but this is secondary, an > implementational detail of @:. The important consequence of the > above is that @: is not (strictly speaking, which we strive > for here) composition. This has to do with the domains under consideration. If the domain has a rank larger than the rank of g, then f@g is not composition. If the rank of the domain is the rank of g, then f@g is composition. > All the more so in view of the DoJ saying @ – a different adverb > – is the composition. One issue here is that while verbs can represent functions they are concrete mechanisms which manipulate symbols rather than being pure mathematical constructs. In DoJ's treatment of f @ g we only concern ourselves with nouns whose rank is smaller than that of g. In this context, f @ g and f @: g are equivalent. >> f@g is not always syntactically valid. > > Sure, and there are even more ways for f@g to become invalid … > When I wrote 'any pair of arguments' I obviously meant any pair of > verbs for which f@g makes sense. Yes, well... I suppose that's the basic question here: what makes sense? > But of course, here you are nitpicking again, because your note is > actually tangent to the content of the statement that I made and > you chose to comment. And, of course, you can make no mistakes. It's just hard for me to understand what you are saying when you are telling me that what I am seeing is not possible. -- Raul ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm