Modeling Traffic Patterns using Java

Similar documents
Pedestrian Safety Lesson Plan

Vehicular and Pedestrian Access to Herndon Metrorail Station. Robert B. Boxer, Director John Stuart, Clark Nexen October 28, 2015

INTRODUCTION TO SIGNAL TIMING & TRAFFIC CONTROL

Summary of Pedestrian Safety Unit

Designing a Traffic Circle By David Bosworth For MATH 714

Simulation Analysis of Intersection Treatments for Cycle Tracks

Long Red, Short Green, I Got Skipped, and Why Do I Always Have To Stop Who Runs These Signals and How Do I Get Ahold Of Them?

Traffic Signal Optimization Project (Hosman Road) (Future Coordinated Corridor)

Module 3 Developing Timing Plans for Efficient Intersection Operations During Moderate Traffic Volume Conditions

James Williams Middle School 915 Acacia Lane

Grand Slam Tennis Computer Game (Version ) Table of Contents

How to Develop a Pedestrian Safety Action Plan

Safe Routes to School

Summary: Mercer County Princeton Avenue & Spruce Street Study January 2009

SPEAKING OUTLINE School Bus Drivers In-service LESSON: Safe Student Loading and Unloading Slide 1 I. Introduction school bus is the safest

DOWNTOWN TUPELO MAIN STREET: ROAD DIET STUDY

Modeling Signalized Traffic Intersections Using SAS Simulation Studio. Leow Soo Kar

Lesson 5: School Bus Safety

Lesson #7. Review: Lesson #6 Destination: Eureka. SKILLS A. Protected Left Turns

Grade 2-3 READING Traffic Safety Cross-Curriculum Activity Workbook

Unit 2: Section 2 Negotiating Intersections

2014/2015 BIKE ROUTE PLAN 83 AVENUE PROTECTED BIKE LANE

One-Way Street Movement vs. Two-Way Street Movement

LINCOLNWOOD POLICE DEPARTMENT

Real Time Bicycle Simulation Study of Bicyclists Behaviors and their Implication on Safety

Grade 2-3 MATH Traffic Safety Cross-Curriculum Activity Workbook

11/28/2016 VIA

Public Information Centre

133 rd Street and 132 nd /Hemlock Street 132 nd Street and Foster Street MINI ROUNDABOUTS. Overland Park, Kansas

J Street and Folsom Boulevard Lane Conversion Project (T ) Before and After Traffic Evaluation

Evaluation of cross-walk timing and the application of a standard crossing light timing formula

Arlington Public Schools Thomas Jefferson Site Evaluation Transportation Networks. Thomas Jefferson Working Group Meeting #6 November 10, 2014

TRAFFIC IMPACT ANALYSIS

City of Vallejo Traffic Calming Toolbox

TRANSPORTATION NEEDS ASSESSMENT

Traffic Signal Redesign 50% Design Report

An Analysis of Reducing Pedestrian-Walking-Speed Impacts on Intersection Traffic MOEs

Recommended Improvements - Ruby/Banning Neighbourhood Greenway

APS Stratford Project Transportation Analysis Overview. Stratford BLPC #5 June 1, 2015

RC-67M has been updated to include more details to be consistent with both ADAAG and PROWAG. The following slides discusses the general notes found

Designing for Pedestrian Safety

Evaluation of Innovative Bicycle Facilities:

Section 5.1 Randomness, Probability, and Simulation

Addendum to Mitigated Negative Declaration

Mathematics of Planet Earth Managing Traffic Flow On Urban Road Networks

Lesson 4: Parking Lot Safety

BENNING ROAD & BRIDGES TRANSPORTATION IMPROVEMENTS CRASH DATA AND SAFETY ANALYSIS TECHNICAL MEMORANDUM DRAFT MAY 2016

Comments EXECUTIVE SUMMARY

Converse Elementary Traffic Safety Brochure

Adult School Crossing Guard Guidelines

Lake Whitney Elementary School

Moving Towards Complete Streets MMLOS Applications

Hidden Oaks Elementary School

5/31/2016 VIA . Arwen Wacht City of Sacramento Community Development Department 300 Richards Blvd., 3 rd Floor Sacramento, CA 95811

Subject: Bike Project Field Trial Must Validate Bike Safety Claims

Pedestrians under high-risk despite technological improvements

SCHOOL CROSSING PROTECTION CRITERIA

MEMORANDUM. Charlotte Fleetwood, Transportation Planner

Clybourn Ave. Protected Bike Lane Study Halsted St. to Division St.

Walkability in St Kilda Creates a Feeling of Social Cohesion Lily Weinberg Healthy Communities Assignment 2 14 September 2009

Optimizing The Operations of Closely Spaced Traffic Signals. Gordon E. Meth, P.E., PTOE ITE District 1 Annual Meeting May 21, 2004

EXECUTIVE SUMMARY. Page 1 of 6

GARLAND ROAD/GASTON AVENUE/ GRAND AVENUE INTERSECTION IMPROVEMENT STUDY

US 278 Corridor Concept Presentation. Avondale Estates Intersection Improvement/Roundabout and Road Diet Feasibility Study March 19, 2015

Grade 2-3 SPELLING Traffic Safety Cross-Curriculum Activity Workbook

Drivers Responsibilities to Pedestrians

Lesson 4: Parking Lot Safety

California Pedestrian and Bicycle Safety Curriculum

Mission Bay Loop (MBL) Public Meeting

MEMORANDUM. Nantasket Road at Kingsley Road Kingsley Road at Sumner Street Kingsley Road at Revere Street Kingsley Road at Kenberma Street

University Avenue & Farley Avenue/University Bay Drive Area Scenario Base Conditions Multiple concerns

COWETA HIGH SCHOOL AND EAST HIGHWAY 51

Unit Five : Driving In Neighborhoods

COMMUNITY PEDESTRAIN SAFETY TRAINING. Long Beach June 5 th, 2010

Southside Road. Prepared for: City of St. John s Police & Traffic Committee. Prepared by: City of St. John s Traffic Division

Traffic circles. February 9, 2009

Foothill Expressway Improvements Between El Monte and San Antonio

Summarize and compare traffic model results for two scenarios 2030 As Is 2030 Jensen Connection

WISCONSIN AVENUE EXTENSION SECOND PUBLIC INFORMATION MEETING. March 28, 2017

DEPARTMENT OF ENVIRONMENTAL SERVICES. North Harrison Street (Lee Highway to Little Falls Road) Comparative Analysis. Prepared for:

Sherwood Drive Traffic Circle

1. Places where one road meets or crosses another are called intersections. F

Meeting Summary Public Information Meeting #1 Warren County Pathway Corridor Project September 27, 2018

Northeast 65 th Street Vision Zero Project Proposals From A Roosevelt High School Student Joe Mangan

Welcome. Thank you for your interest in the Lewis & Clark Viaduct Concept Study

Keywords: multiple linear regression; pedestrian crossing delay; right-turn car flow; the number of pedestrians;

Atwood Avenue Fair Oaks Avenue Cottage Grove Road

City of Fairfax, Virginia City Council Work Session

Self-Organizing Signals: A Better Framework for Transit Signal Priority

The Miami-Dade Safe Routes to School Initiative

2014/2015 BIKE ROUTE PLAN 83 AVENUE PROTECTED BIKE LANE

REPORT TO MAYOR AND COUNCIL

5.1A Introduction, The Idea of Probability, Myths about Randomness

Central Freeway and Octavia Circulation Study

NCHRP Project Crossing Solutions at Roundabouts and Channelized Turn Lanes for Pedestrians with Vision Disabilities UNC-CH CH Highway Safety Res

CALVERT COUNTY PUBLIC SCHOOLS Transportation Department 1305 Dares Beach Road Prince Frederick, Maryland FAX

Study on fatal accidents in Toyota city aimed at zero traffic fatality

Intersection Improvement: Sturgeon Road, Silver Avenue and Murray Park Road Roundabout. Welcome. Public Information Session

I-10 AT SCENIC LOOP RD. Open House

Lesson 2: Crossing Streets Safely

Transcription:

The College at Brockport: State University of New York Digital Commons @Brockport Lesson Plans CMST Institute 5-2005 Modeling Traffic Patterns using Java Kim Meek The College at Brockport Follow this and additional works at: http://digitalcommons.brockport.edu/cmst_lessonplans Part of the Physical Sciences and Mathematics Commons, and the Science and Mathematics Education Commons Repository Citation Meek, Kim, "Modeling Traffic Patterns using Java" (2005). Lesson Plans. 284. http://digitalcommons.brockport.edu/cmst_lessonplans/284 This Lesson Plan is brought to you for free and open access by the CMST Institute at Digital Commons @Brockport. It has been accepted for inclusion in Lesson Plans by an authorized administrator of Digital Commons @Brockport. For more information, please contact kmyers@brockport.edu.

Modeling Twelve- Corners Traffic

Project Background Many students must pass a crosswalk across Winton Rd near Twelve Corners in order to reach Brighton High School each day. A trusty crossing guard ensures their safety by operating a traffic light that stops cars so that students can safely cross. Each time the light turns red, all road traffic stops, and cars build up at the intersection.

Problem: Can the timing of the crosswalk s traffic light be improved to minimize traffic congestion while still ensuring the safety of the students?

Data Collection Team members BW and DG observed pedestrian and motor vehicle traffic at the crosswalk for 10 minutes during peak traffic time. And collected the following data: # of Cars: 53 # of students: 17 Time light was red: 30 seconds Average time light was green: 2 minutes

Computer Technology Chosen: Java programming All three team members are AP Computer Science students, and have a strong understanding of the Java language Java s object-oriented nature allows for classes to be designed for each type of object that interacts at the crosswalk Java s Marine Biology Case Study, part of the AP Computer Science Curriculum, provides an excellent framework to simulate the crosswalk.

The Marine Biology Case Study Provides a simulation of fish randomly moving about an environment. Fish can be added to any square and facing any direction Different speeds of simulation can be chosen, or it can proceed through single steps (MBS)

Important MBS Classes Fish The code for the fish in the simulation. Contains an act method that tells the fish what to do in each step of the program Environment Provides a grid for objects in the simulation. Only one object can inhabit each square. Only fish objects can be added. MBSGUI Provides a Graphics User Interface for the simulation. Allows for easy tweaking of the simulation as well as a way to view it.

New Classes we Added Since only Fish can be added to environment, we faced a problem. Fortunately, Java offered a solution. We made all our new classes extend Fish so that they could be used. By overriding the act method in these classes, we could also design specific behaviors for all of them. Fish Car Children CrossingGuard Grass

Class Descriptions: Car Detects whether it is in the westbound or eastbound lane and moves accordingly. If the light is red, the Car stops before the crosswalk. Even if light is green, if a child is in the way, the Car will stop

Children Moves on sidewalk towards crossing guard. If light is green, waits in line for light to turn red. Once light turns red, runs across the crosswalk and continues to walk on other side of road.

CrossingGuard Can be seen as God within the simulation. Adds new cars and children randomly. Has a probability of turning light red based on how many kids are waiting. Once light is red, turns light green after a number of steps.

Grass Grass has nothing in its act method. It simply sits where it is and doesn t move. Its sole purpose is to stay in its spot and make the simulation more aesthetically pleasing.

The Simulation Working

Solving the Problem At all times, we kept the number of kids and cars at the real life ratio the same, and we also kept timing constant. The part of the simulation that we changed between trials was the behavior of the CrossingGuard in turning the light red and green. By analyzing the effects of the different methods, we determined which ones worked better than others, and which one worked the best.

Solution 1: Set Times Our first Solution was to have a fixed time for the light to stay green between red lights. This meant that the light change was completely independent of its surroundings. Pros: This method provided regularity, and the timings could be set to the ratio of cars to children. Cons: Since car and child creation was completely random, the light needed more ability to respond to the environment. With this method, large groups of children could bunch at the light, or traffic could be stopped when no children needed to cross.

Solution 2: One-Student Trigger Our next solution was to turn the light red whenever there was any child waiting for the light. We created the trigger by monitoring whether or not there were children in the CrossingGuard s row Pros: This method ensured that children would always be able to cross in a timely manner. Cons: This method resulted in a lot of traffic slowdown since the light would turn red any time there was a student waiting, which would happen frequently. A large number of cars would have to stop in order to ensure that just one student could cross.

Solution 3: Multi-Student Trigger This method was very similar to the last in that it measured whether or not there were children in the CrossingGuard s row. This time, there needed to be more than one child to set off the trigger. We set the needed number to three children Pros: Traffic could stop less frequently because more students would cross during each red light. Cons: Because children do not always come in groups, a single student could end up waiting at the light forever, or at least a very long time.

Solution 4: Probability Trigger Our final solution used random probability to decide whether or not to turn the light red. Whenever a child was waiting, there was a 1/6 chance that the light would change in the next movement. Also, for each additional child another 1/6 was added to the probability. Pros: This method combined the pros of solutions 2 and 3. The light usually waited until multiple children were waiting until it changed, but single children could also cross on their own eventually. Cons: Since this method throws more random chance into the mix, there is always the possibility of rare abnormalities occuring. eg: a group as large as 5 in theory faces the chance of waiting forever.

Final Decision: Solution 4 The probability trigger created a system that was fair to both the cars and the children. The possible abnormalities would be very very rare, and we never encountered them in our simulations, so we consider them to be a moot point.

Questions?