<< Chapter < Page Chapter >> Page >

Through this section, we've seen some of the common patterns that can arise in the formulas.Following upon the idea of Design Patterns as describing common programming idioms,``Specification Patterns'' describe common logic specification idioms.For a list of LTL specification patterns, see Property Pattern Mappings for LTL .

In addition, there are also algebraic equivalences for LTL,just as there are for propositional logic . We have already seen a DeMorgan-like example; there are also less obvious equivalences, such as distributing over : ( ) ( ) and the redundancy of -over- : ( ) ( ) It can be fun to dabble in rewriting LTL formulas, but (alas) we won't visit that topic further here.

Using temporal logic in spin

So, we have a Promela program and an LTL formula to verify. How do we use the tool? In SPIN, in the "Run" menu,select "LTL Property Manager". This opens a new window. The top half contains several subpartsfor entering an LTL formula, while the bottom half is for using it.

In the "Formula" textbox, you can type an LTL formula. If you prefer, you can enter the operators using the buttons below,rather than typing. Also, you can use the "Load" button to restore a previously-saved LTLformula from a file. For a formula, the next checkboxes allow you to either verify thatthe formula always holds or never holds. The "Notes" textbox is simply descriptive text. If you plan on savingthe formula, it is helpful to remind yourself what this formula means and is used for.The "Symbol Definitions" textbox is where the LTL variables (typically p , q , etc. ) are related to the Promela code.This is done through #define s which are temporarily added to your Promela code.

Let's consider another critical section example. The following code simply puts the critical section into a loop. Also included isour standard code to check that the mutual exclusion property is satisfied, although the assertion is commented out. 1 /* Number of copies of the process to run. */ 2 #define NUM_PROCS 33 4 show bool locked = false;5 show int num_crit = 0; 67 active[NUM_PROCS] proctype loop()8 { 9 do10 :: true ->11 12 atomic {13 !locked ->14 locked = true; 15 }16 17 /* Critical section of code. */18 /* Something interesting would go here. */ 1920 num_crit++; 21 /* assert(num_crit == 1); */22 num_crit--; 2324 locked = false; 25 /* End critical section of code. */26 od; 27 }

Using temporal logic, we can accomplish the same check without the assertion.There are several similar ways of doing this.

One way is to verify that num_crit always has the value 0 or 1. To do this, we'll make the following definitionin xspin's ``Symbol Definitions'' textbox: #define p ((num_crit == 0) || (num_crit == 1)) We then want to verify that p always holds, so our formula is []p and mark that we always want this formula to hold.

Questions & Answers

Is there any normative that regulates the use of silver nanoparticles?
Damian Reply
what king of growth are you checking .?
What fields keep nano created devices from performing or assimulating ? Magnetic fields ? Are do they assimilate ?
Stoney Reply
why we need to study biomolecules, molecular biology in nanotechnology?
Adin Reply
yes I'm doing my masters in nanotechnology, we are being studying all these domains as well..
what school?
biomolecules are e building blocks of every organics and inorganic materials.
anyone know any internet site where one can find nanotechnology papers?
Damian Reply
sciencedirect big data base
Introduction about quantum dots in nanotechnology
Praveena Reply
what does nano mean?
Anassong Reply
nano basically means 10^(-9). nanometer is a unit to measure length.
do you think it's worthwhile in the long term to study the effects and possibilities of nanotechnology on viral treatment?
Damian Reply
absolutely yes
how to know photocatalytic properties of tio2 nanoparticles...what to do now
Akash Reply
it is a goid question and i want to know the answer as well
characteristics of micro business
for teaching engĺish at school how nano technology help us
Do somebody tell me a best nano engineering book for beginners?
s. Reply
there is no specific books for beginners but there is book called principle of nanotechnology
what is fullerene does it is used to make bukky balls
Devang Reply
are you nano engineer ?
fullerene is a bucky ball aka Carbon 60 molecule. It was name by the architect Fuller. He design the geodesic dome. it resembles a soccer ball.
what is the actual application of fullerenes nowadays?
That is a great question Damian. best way to answer that question is to Google it. there are hundreds of applications for buck minister fullerenes, from medical to aerospace. you can also find plenty of research papers that will give you great detail on the potential applications of fullerenes.
what is the Synthesis, properties,and applications of carbon nano chemistry
Abhijith Reply
Mostly, they use nano carbon for electronics and for materials to be strengthened.
is Bucky paper clear?
carbon nanotubes has various application in fuel cells membrane, current research on cancer drug,and in electronics MEMS and NEMS etc
so some one know about replacing silicon atom with phosphorous in semiconductors device?
s. Reply
Yeah, it is a pain to say the least. You basically have to heat the substarte up to around 1000 degrees celcius then pass phosphene gas over top of it, which is explosive and toxic by the way, under very low pressure.
Do you know which machine is used to that process?
how to fabricate graphene ink ?
for screen printed electrodes ?
What is lattice structure?
s. Reply
of graphene you mean?
or in general
in general
Graphene has a hexagonal structure
On having this app for quite a bit time, Haven't realised there's a chat room in it.
what is biological synthesis of nanoparticles
Sanket Reply
Got questions? Join the online conversation and get instant answers!
Jobilize.com Reply

Get the best Algebra and trigonometry course in your pocket!

Source:  OpenStax, Model checking concurrent programs. OpenStax CNX. Oct 27, 2005 Download for free at http://cnx.org/content/col10294/1.3
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Model checking concurrent programs' conversation and receive update notifications?