Where communities thrive

  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
    im not saying to get rid off it
    maybe it can be another page
    that you link to "if you're interested in the CS stuff click here"
    how old are you ?!
    Jean-Jacques Dubray
    mentally or physically?
    my first computer was a TRS-80
    mine too
    im 39
    Jean-Jacques Dubray
    just a bit older...
    heh ok
    anyways ---- ofc take or leave my advice
    just saying what i think :D
    Jean-Jacques Dubray
    makes sense, just so many hours in day
    Interesting, the TODO vanilla JS is just running on the browser.
    yeah i think that's the standard
    isomorphic is interesting but i feel it's an advanced thing
    looking at your Item List
    I think it's a bit bad practice to mix your model data with the model functions/state ? e.g model.state, model.present etc ...
    what do you think about that
    Jean-Jacques Dubray

    isomorphic is interesting but i feel it's an advanced thing

    this was advanced until SAM, because that was nearly impossible to achieve
    SAM makes it totally trivial

    I think it's a bit bad practice to mix your model data with the model functions/state

    this is wiring, you can wire the pattern in any way you'd like
    The constraints of the pattern are only:

    • on role and responsibilities of Actions, Model and State
    • Sequence of invocations in the reactive loop as defined by the expression V = S( vm(M...
    • weaving of API calls in the pattern (3rd party APIs and CRUD)
    After that you can distribute and connect the elements of the pattern any way you'd like, that's the whole point of making Isomorphic JavaScript easy to achieve. Here are all the combinations you deploy the pattern as: http://sam.js.org/#iso
    There is no prescription on wiring at all
    what do you mean by "only one factoring to computing, it's called TLA+"
    This factoring is "unique", you just can't make it up (IMHO)
    You can define formalisms on top of it, but you cannot decide arbitrarily what the foundation is, it is foundational.
    Computer science is not based on opinion.
    As I mentioned before, there is not only one factoring to computing, and that is just as known as the fact that the earth is round.
    maybe you have to do a little bit more research.
    you can't throw up any formalism in the air and say that one works too,
    That's exactly what you are doing with SAM
    My point is that TLA+ is a formalism which can be used to describe any state machine as we know it, therefore I claim it is foundational.
    Bruno, there is only one factoring to computing, it's called TLA+, everything else that was built prior to that is an approximation
    Except that there is a very, very fundamental difference here
    SAM state machines are not of the kind (S1,A,S2)
    If that was the case, you would be correct
    As I mentioned the structure of (S1,A,S2) is an approximation
    An approximation to what? of what? What does that even mean?
    Every program written with a turing-complete language can be written in another turing-complete language including the turing original machine itself . That is all turing-complete languages allow to write the same programs.
    So writing a program as a sequence of commands is not an approximation (whatever you meant by that), it is just as valid as any other way.
    It is about semantics, 1/1 and 16-15, 2232^2 - 3 are different expressions, but they denote the same number. You can't say one expression is an approximation and the other one is the real thing.
    Back to state machines, the notation you use to describe them does not change their semantics, so (S1, A, S2) and the other one you wrote (I think it was (S1, A1, ..., NAP or something) are syntactic constructions. The behaviour of the state machines or its semantics is entirely decided based on the tuple which defines it (set of input symbols, set of output symbols, set of states, etc.)
    You have the tendency to present things which are just your unsubstantiated vision of things as being science backed by important theoretical construction, but I had a close look and I did not get to that conclusion.
    Last thing, even if all of the previously quoted statements were all true, TLA+ is irrelevant to SAM. There is no need to go read any mathematical papers on anything. To determine a judgement on some properties of a theory/architecture, you need clear semantics which I haven't seen here. On the contrary, I see mathematics formulas where the functions are not really functions.
    The SAM pattern can be described as a Mathematical expression (formula):
    V = S( vm(M.present(A(data))), nap(Model) )
    and then later
    However, that expression is only a logical expression that describes the sequence in which the elements of the pattern are invoked.
    We have pure functions, but... wait,
    Where S(), vm(), A() and nap() are pure functions with respect to the model.
    That has me wondering what would be an impure function with respect to the model. Actually that had me wondering what the hell is a pure function, and how that can be with respect to anything.
    I could go on for a long time but I lack the interest to do so.
    Jean-Jacques Dubray

    Thank you for your insights. This has been the starting point of SAM

    Much of computer science is about state machines. This is as obvious a
    remark as saying that much of physics is about equations.
    State machines provide a framework for much of computer science. They
    can be described and manipulated with ordinary, everyday mathematics—
    that is, with sets, functions, and simple logic. State machines therefore
    provide a uniform way to describe computation with simple mathematics.

    To describe a program as a state machine, we must decide what constitutes
    a step. How many steps are performed in executing the statement
    f = i ∗ f of the programs in Figure 1? Does a single step change the value
    of f to the product of the current values of i and f ? Are the evaluation of
    i ∗ f and the assignment to f two steps? Are there three steps—the reading
    of i, the reading of f , and the assignment to f ?

    That has been exactly the path I took when designing SAM, what are "steps" involved in processing an event and rendering the effects, with the understanding that you cannot ignore the semantics of the State Machine behind, actually, I would argue that any formalism that is derived without consideration of the underlying state machine is most likely flawed.

    As Dr. Lamport states (pun intended):

    The obsession with language is a strong obstacle to any attempt at unifying
    different parts of computer science. When one thinks only in terms
    of language, linguistic differences obscure fundamental similarities. Simple
    ideas can become complicated when they must be expressed in a particular
    language. A recurring theme is the difficulty that arises when necessary
    concepts cannot be introduced either because the language has no way of
    expressing them or because they are considered to be politically incorrect.

    Jean-Jacques Dubray
    Of course we must then first agree on the definition of a state machine... that's why I clearly stated the definition I used.
    Slađan Ristić
    Hi, I am reading the "no-more-mvc-frameworks" article and Jean posted an example about an "increment" action and a model. I am trying to map this to CQRS, (but I am unsure if it even makes sense). Since the model checks the validity of the data, the action is not even a command in the CQRS sense but a mapping of user input?
    So if you used CQRS for this system, the model would would split its mutation in two steps:
    1. validate data + apply "increment" command
    2. mutate + generate "incremented" event