[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*From*: ss.nedunuri@xxxxxxxxx*Date*: Thu, 12 Mar 2020 15:15:15 -0700 (PDT)*References*: <a0c81c85-cf49-424d-9e7a-0c8876db6cec@googlegroups.com> <CAFEV_-j4ns-VAFFHq8-BQOoQ4UK2QR0sCTducteQKpvUBLZHOw@mail.gmail.com> <156ed98e-9c77-4dbf-911e-7ddedb2b3b7c@googlegroups.com> <CAFEV_-geq22WxpXF49yRZ7UQys9KDU68RFhCsOeR8HCXAm+iMw@mail.gmail.com> <792666D4-051B-4057-95C7-368A0C7379BE@gmail.com>

Thanks Stephan, that does help. I have a clarification question: In the second case, where we are trying to prove a theorem about (all instances of) the spec, is it still (intuitively) the case that a CONSTANT is only required to remain constant over a behavior? And in that case the difference between declaring CONSTANT K and K == <some value> is that in the latter case, any behavior that satisfies the assumptions must also satisfy all instances of the spec for all behaviors in which K has <some value>?

On Thursday, March 12, 2020 at 12:55:55 AM UTC-7, Stephan Merz wrote:

-- thank

On Thursday, March 12, 2020 at 12:55:55 AM UTC-7, Stephan Merz wrote:

In this discussion, it is important to make a distinction between a specification and an instance of a specification. A CONSTANT parameter in a specification represents an arbitrary value (possibly constrained by an assumption that delimits values for which the module is intended to be meaningful). By assigning different values to the constant parameters, we obtain different instances of the specification. The value is fixed for every instance, in particular it never changes during or across behaviors considered for that particular instance of the specification.TLC checks the correctness ofinstancesof TLA+ specifications, and that's why you fix the values of constants when you launch TLC.A TLA+specificationis correct (cf. section 17.6 of Specifying Systems) if the assumptions imply the theorems, and this means that any instance has to be correct (observe that the non-meaningful instances are trivially correct). Because there are infinitely many values, you cannot use TLC to check the correctness of a specification, but you can reason symbolically about TLA+ specifications, as with TLAPS.Hope this helps,StephanOn 11 Mar 2020, at 23:12, Apostolis Xekoukoulotakis <apostolis.xe...@gmail.com > wrote:You can look at page 25 for the definition of CONSTANT. Maybe others can help more.On Thu, Mar 12, 2020 at 12:02 AM ns <nedsr...@xxxxxxxxx> wrote:This article https://www.reddit.com/r/tlaplus/comments/aj018f/ seems to imply that its not a symbolic constant but rather a free variable (that doesn't change during a behavior), and therefore any theorem involving your spec must hold for all values of that constant.constant_antipatterns/

On Wednesday, March 11, 2020 at 1:58:39 PM UTC-7, Apostolis Xekoukoulotakis wrote:Constant means that it is constant. For example , If we want to describe the behavior of N agents, then N is a constant, because the number of agents does not change.On Wed, Mar 11, 2020 at 10:53 PM ns <nedsr...@xxxxxxxxx> wrote:Hello, I was unable to find an explanation for the meaning of CONSTANT anywhere in the "Specifying Systems" book. Is it true that while a VARIABLE can change its value over a behavior, a CONSTANT must keep the same value over a given behavior but can have a different value across behaviors? And that if instead of CONSTANT k and giving it the value 42 in TLC, if I write k==42 that would fixkeven across all behaviors.Ifthat's the case, then defining constants in TLC seems to be over constrained in that it requires you to assign one fixed value across all behaviors.thanks--

You received this message because you are subscribed to the Google Groups "tlaplus" group.

To unsubscribe from this group and stop receiving emails from it, send an email to tla...@xxxxxxxxxxxxxxxx.

To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/a0c81c85-cf49- .424d-9e7a-0c8876db6cec% 40googlegroups.com

--

You received this message because you are subscribed to the Google Groups "tlaplus" group.

To unsubscribe from this group and stop receiving emails from it, send an email to tla...@googlegroups.com .

To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/156ed98e-9c77- .4dbf-911e-7ddedb2b3b7c% 40googlegroups.com

--

You received this message because you are subscribed to the Google Groups "tlaplus" group.

To unsubscribe from this group and stop receiving emails from it, send an email to tla...@googlegroups.com .

To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/CAFEV_- .geq22WxpXF49yRZ7UQys9KDU68RFhC sOeR8HCXAm%2BiMw%40mail.gmail. com

You received this message because you are subscribed to the Google Groups "tlaplus" group.

To unsubscribe from this group and stop receiving emails from it, send an email to tlaplus+unsubscribe@xxxxxxxxxxxxxxxx.

To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/70315c1c-e81e-4953-a777-d1aba13c1e86%40googlegroups.com.

**Follow-Ups**:**Re: [tlaplus] meaning of CONSTANT***From:*Stephan Merz

**References**:**[tlaplus] meaning of CONSTANT***From:*ns

**Re: [tlaplus] meaning of CONSTANT***From:*Apostolis Xekoukoulotakis

**Re: [tlaplus] meaning of CONSTANT***From:*ns

**Re: [tlaplus] meaning of CONSTANT***From:*Apostolis Xekoukoulotakis

**Re: [tlaplus] meaning of CONSTANT***From:*Stephan Merz

- Prev by Date:
**[tlaplus] Syntax of cfg file** - Next by Date:
**Re: [tlaplus] Syntax of cfg file** - Previous by thread:
**Re: [tlaplus] meaning of CONSTANT** - Next by thread:
**Re: [tlaplus] meaning of CONSTANT** - Index(es):