You are on page 1of 4

SPS Basic: Liquid English Advanced Logic

Advanced Logic 8

8.1 Objectives

At the end of this section, you will be familiar with the following:

 Alarming

 Define Sequences

 Whenever Statements

8.2 Model Acceptance

You’ve done it! Your boss has informed you that you are the only new hire that has
successfully provided a solution to the problems that have been laid before you.

You are bombarded with the urge to scream out “THERE CAN BE OOOOONLY
ONE!”, but you refrain because you realize that the boast itself, albeit funny, doesn’t
really make any sense. Only one what?... new hire?... that’s just silly….

You realize your boss has been speaking, during the celebration/contemplation and that
you didn’t hear what was said. You ask him to repeat himself one more time so you can
make sure you understand him. But, when he starts to explain that there needs to be a
few tweaks done in the model you can’t help but think that you need to schedule a trip to
the doctor. You think you have a problem focusing when your boss is talking…

You snap back and your boss says ok thanks and walks out. You’re in trouble because
now you don’t know what to do and you’ve already asked him to repeat himself once.
You look around frantically and then realize he left a sticky note listing his requests…

Create sequencing for the pump


 Start Sequence – Open suction, wait until suction valve is completely
opened, start pump, wait one minute, open discharge valve.
 Stop Sequence – Stop pump, close discharge valve, wait until pump is fully
stopped, close suction valve.

Create an alarm that will go off if the pressure at pump inlet ever drops below 0 psig.

GL Noble Denton 8-1


SPS Basic: Liquid English Advanced Logic

Create logic such that if the suction pressure of the pump drops below zero, execute
the stopping sequence.

8.3 System Startup


You realize two things; first being that although the task list is short, the requests aren’t
very easy, second that you’re going to schedule that doctors appointment sooner than
later…

Creating Startup Conditions

1. Open IPLiquid_VFD.intran and save it as IPLiquid_final.intran.

2. In Model Builder, save IPLiquid_VFD.inprep as IPLiquid_final.inprep.

3. Edit P1 initial status so it reads NO instead of YES.

4. Change P1.DIS and P1.SUC initial valve fractions to 0.

5. Both valves and the pump should show up as red now.

Alarm Logic

6. Open IPLiquid_Final.intran.

7. Insert alarm logic that is triggered if (P1:P- < 0). Use any name and message text
you like.

Note: The Help and Reference will be useful here.

8. Comment out the current MACRO line of code and add the following:

MACRO (INIT, DIST1 SHOW P1_SW)

9. Save the INTRAN file and run the model.

GL Noble Denton 8-2


SPS Basic: Liquid English Advanced Logic

Startup Sequence

The startup sequence should bring the line up as fast as possible, because time is money, without
pulling vacuum

10. Open back up IPLiquid_final.intran and add a DEF.SEQ, P1_START, that performs
the following:

 Open P1.SUC
 Open P1.DIS
 Waits until P1.SUC is opened
 Start P1

11. Create another DEF.SEQ, P1_STOP, that performs the following:


 Stops the pump
 Closes the discharge valve
 Waits until the pump is fully stopped
 Closes the suction valve

12. Run the model until at steady state.

13. Go to Simulation > Submit Sequence… > and select P1_START. Does the pump
startup as expected? _________________________

14. Change P1_SW:SS to 1.

15. Press the button in Model Builder to open the model directory.

16. Open IPLiquid_Final.almlog. Does your alarm appear correctly? ______________

17. Stop the model.

18. Add a SUB.SEQ P1_START that is initiated at TIME = 60.

19. Run the model.

20. Repeat #18 except select P1_STOP. Does the pump stop as expected? ___________

21. Use Simplot to create a time plot of P1:RPM, P1.SUC:FR, and P1.DIS:FR.

22. When the pump starts, does it do so only after P1.SUC:FR = 1? _____________

23. When the pump stops, does the suction valve close on after P1:RPM < 20? ________

24. Stop the model.

GL Noble Denton 8-3


SPS Basic: Liquid English Advanced Logic

Whenever Statement

You know that you will need to create a WHENEVER that stops the pump if vacuum
ever occurs upstream of the pump…

…after you setup logic for the WHENEVER conditional ;)

Note: The conditional for the WHENEVER should be false most of the time.

25. Run the model and change P1_SW:SS to 1.

26. Does the pump shutdown as expected? ______________________

Summary/Conclusion
You have successfully done as your boss requested. You’ve updated the INPREP file to:

 Have the line off upon startup of the simulation.

You updated the INTRAN file to:

 Alarm if the pump suction pressure enters a vacuum.


 Shutdown the pump suction pressure enters vacuum.
 Startup the line via a SUBMIT SEQUENCE

Used SIMPLOT to verify the sequencing occurred when it should.

Other topics to consider researching are:


 Archiving
 Include Files
 Macros

GL Noble Denton 8-4

You might also like