Docsity

Representing Structure and Behavior - Study Guide for Exam | CS 1316, Study notes of Computer Science

Toggle sidebar
bg1
Recitation Guide Wednesday, July 18
1. House Keeping
a. Exam 2
i. Comments?
b. Extra Credit Homework 9
i. http://coweb.cc.gatech.edu/cs1316/633#hw9
ii. An individual assignment with limited help from TAs.
iii. If greater than lowest homework score, then it will replace the lowest
homework score.
c. Extra Optional Quiz
i. July 23 and July 25 during recitation.
ii. If grade is higher than lowest quiz grade, then this grade replaces lowest quiz
grade.
iii. Topics likely to be highly comprehensive.
d. Final Exam
i. Held Wednesday 2:50pm
e. Homework 8
i. http://coweb.cc.gatech.edu/cs1316/633#hw8
ii. Due Wednesday, July 17 11:45pm with grace until Thursday, July 18 7:00am.
iii. Cannot be pushed back more!
iv. Feel free to tweak some of the numbers in red to see if you can get better
results.
2. DES (Discrete Event Simulations)
a. Remember that:
i. In discrete simulations not every moment in time is simulated.
ii. Queues are FIFO (First in, First out) structures.
b. The EventQueue
i. Because there is no time loop, time events need to be placed in the
EventQueue, where the first one removed (processed) is the event that occurs
the earliest in time. At each run step, the next scheduled event with the lowest
time gets processed. The current time is then that time, the time that that event
is supposed to occur.
c. Agents
i. In a discrete event simulations, agents do not act(). Instead, the agents wait for
events to occur and schedule new events to correspond to the next thing that
they are going to do. Events also get scheduled according to different
probabilities.
ii. However, agents cannot always do what they want to do because of limited
resources. An agent is blocked until more resource is available.
d. Uniform distributions versus normal distributions
i. Normal distribution (Gaussian or the bell curve)
pf3

Partial preview of the text

Download Representing Structure and Behavior - Study Guide for Exam | CS 1316 and more Study notes Computer Science in PDF only on Docsity!

Recitation Guide Wednesday, July 18

  1. House Keeping a. Exam 2 i. Comments? b. Extra Credit Homework 9 i. http://coweb.cc.gatech.edu/cs1316/633#hw ii. An individual assignment with limited help from TAs. iii. If greater than lowest homework score, then it will replace the lowest homework score. c. Extra Optional Quiz i. July 23 and July 25 during recitation. ii. If grade is higher than lowest quiz grade, then this grade replaces lowest quiz grade. iii. Topics likely to be highly comprehensive. d. Final Exam i. Held Wednesday 2:50pm e. Homework 8 i. http://coweb.cc.gatech.edu/cs1316/633#hw ii. Due Wednesday, July 17 11:45pm with grace until Thursday, July 18 7:00am. iii. Cannot be pushed back more! iv. Feel free to tweak some of the numbers in red to see if you can get better results.
  2. DES (Discrete Event Simulations) a. Remember that: i. In discrete simulations not every moment in time is simulated. ii. Queues are FIFO (First in, First out) structures. b. The EventQueue i. Because there is no time loop, time events need to be placed in the EventQueue , where the first one removed (processed) is the event that occurs the earliest in time. At each run step, the next scheduled event with the lowest time gets processed. The current time is then that time, the time that that event is supposed to occur. c. Agents i. In a discrete event simulations, agents do not act(). Instead, the agents wait for events to occur and schedule new events to correspond to the next thing that they are going to do. Events also get scheduled according to different probabilities. ii. However, agents cannot always do what they want to do because of limited resources. An agent is blocked until more resource is available. d. Uniform distributions versus normal distributions i. Normal distribution (Gaussian or the bell curve)

ii. Uniform distribution

e. Insertion Sort i. How it works

1. The insertion sort algorithm sorts a list of values by repetitively inserting

a particular value into a subset of the list that has already been sorted. One at a time, each unsorted element is inserted at the appropriate position in that sorted subset until the entire list is in order. Each time an insertion is made, the number of values in the sorted subset increases by one. The insertion process requires that the other values in the array shift to make room for the inserted element. ii. Needed to insert new events into the EventQueue in the correct order. iii. Big O

  1. Best case: n (for an already sorted list)
  2. Worst case: n^2 (for a list sorted in reverse order)