How come the least fix point coincides with the greatest fix point in a lazy non-total language like Haskell. What does continuity on complete partial orders have to do with that?
Least fix point, greatest fix point
1.1k Views Asked by Marius Catalin At
1
There are 1 best solutions below
Related Questions in HASKELL
- Typeclass projections as inheritance
- How to generate all possible matrices given a number n in Haskell
- Is there a way to get `cabal` to detect changes to non-Haskell source files?
- How to have fixed options using Option.Applicative in haskell?
- How can I create a thread in Haskell that will restart if it gets killed due to any reason?
- Automatic Jacobian matrix in Haskell
- Haskell writing to named pipe unexpectedly fails with `openFile: does not exist (No such device or address)`
- Why does Enum require to implement toEnum and fromEnum, if that's not enough for types larger than Int?
- Non-exhaustive patterns in function compress
- How to get terms names of GADT in Template Haskell?
- Implementing eval() function with Happy parser generator
- How to count the occurences of every element in a list in Haskell fast?
- In Haskell, what does `Con Int` mean?
- Extract a Maybe from a heterogeneous collection
- Haskell, Stack, importing module shows error "Module not found"
Related Questions in FIXPOINT-COMBINATORS
- Quickly memoize anonymous recursive functions using lambdas and the "fix function"
- How could this Y' same as this Y combinator itself?
- How does `const` turn multi-parameter functions iterable by the `fix` fixed-point combinator?
- What's the intuition behind fixpoints of monads NOT being the direct limit?
- Which kinds of lawfull `Functor`s are possible in Haskell?
- How to prevent a Nixpkgs overlay from being applied more than once?
- How to get an infinitely nested value?
- Fixed-point of a monadic and comonadic computation
- Compute type fixed point
- Need help understanding Fix type in Haskell
- higher order fix point in OCaml
- Why doesn't this fixed-point computation stop?
- Translating a fixed-point operator to Haskell language
- Proving two-list queue in coq
- How `fix f = let {x = f x} in x` is evaluated?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular # Hahtags
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
In a CPO (which we interpret a type as), any increasing chain has a least upper bound.
Here's an example that should convey the intuition why, in the domain of CPOs, least fixed points and greatest fixed points coincide. Consider the following functor, abusing the list notation for conciseness:
Its greatest fixed point is the type of Haskell lists (possibly infinite, possibly partial). What about its least fixed point? The following elements must be in it (
Fixconstructors are omitted):And they form an increasing chain, so there must be a least upper bound, which has to be the infinite list of natural integers
0 : 1 : 2 : .... So the least fixed point ofListFcontains infinite lists, and consequently coincides with the greatest fixed point.As was pointed out in the comments, the claim that the greatest fixed point is given by the type
[]may need clarification. For instance, wouldn't some CPO "BigList" of lists indexed by large ordinals make an even greater fixed point?One can first show that
[]satisfies the definition of a finalListF-coalgebra. Then, a property of final coalgebras is that they are unique up to isomorphism. Therefore, lists indexed by larger ordinals would result in a non-isomorphic CPO, so that cannot be a final coalgebra.I could stop there, but hold on, isn't
BigListstill a greater fixed point ofListF? My conclusion is to chalk the issue up to bad terminology and formally we should only discuss "final coalgebras", and not "greatest fixed points".Depending on how you define a "fixed point" of a functor in CPO and a notion of (pre)order between CPOs, you may find that
BigListis a fixed point ofListF, that it is greater than[], that you run into set-theoretic paradoxes when reaching towards the "greatest fixed point", and that ultimately there is nothing of value to Haskell practitioners in that way of formalizing a "greatest fixed point" because you actually wanted the nice properties of a final coalgebra.(I'd be interested to know of a direct way to define "fixed point" that excludes
BigListas one.)So instead, the term "greatest fixed point" might as well be a synonym for "final coalgebra". Some intuition carries over ("fixed points" can commonly be approached by iteration), some doesn't (it's not "greatest" in a set-theoretic sense).