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

Re: [tlaplus] Creating sets with dependencies between fields



Try something like this:

```
files = {[id |->id, originalFileIds |-> {id}]: id \in 1..MaxFileID}
```

H

On Sat, Nov 18, 2023, 5:09 AM thisismy...@xxxxxxxxx <thisismyidashish@xxxxxxxxx> wrote:
Hi

How do i create a variable whose fields depend upon each other like:
set of all files whose id is in range 1..MaxFileID and originalFileIds is a set whose value is id.

I tried `self.<field_name>` i.e. self.id and it did n't work.

E.g.
------ MODULE abc -----------

(*-- algorithm some

variables
    files = [id: 1..MaxFileID, originalFileIds: {}] \* using originalFildIds: {{id}} does not work.

end alorightm;*)

Thanks
Ashish



--
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/6aef4a17-22d5-4b4a-9eca-039c87cd24cbn%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 tlaplus+unsubscribe@xxxxxxxxxxxxxxxx.
To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/CAJ-b8sxh6%2BL5wFaGrsAxDi7dmfPO4EkW6nJtYb04Hc2XQ6BzrQ%40mail.gmail.com.