-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathREADME.txt
More file actions
45 lines (32 loc) · 2.17 KB
/
README.txt
File metadata and controls
45 lines (32 loc) · 2.17 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
This project demonstrates the use of fuzzy logic for controlling traffic lights.
It's an old course project.
This project uses code found at the following locations:
trafficControl.java:
http://www.phy.ntnu.edu.tw/ntnujava/index.php?action=dlattach;topic=139.0;attach=1569 [last accessed Apr 14, 2016].
http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=139.185;wap2 [last accessed Apr 14, 2016].
http://www.phy.ntnu.edu.tw/ntnujava/index.php?topic=139.0
http://www.phy.ntnu.edu.tw/ntnujava/index.php?action=dlattach;topic=139.0;attach=906
MsgBox.java: http://www.rgagnon.com/javadetails/java-0242.html [last accessed Apr 14, 2016].
jFuzzyLogic_2.0.7.jar: https://sourceforge.net/projects/jfuzzylogic/ [last accessed Apr 14, 2016].
==========================================================================================
fuzzy.java uses fuzzy logic approach.
trafficControl.java implements fixed-cycle approach.
Fixed-cycle: uses a 30s green time.
Fuzzy logic: uses a minimum green time of 5s and a maximum of 30s.
Code also tested using Eclipse SDK Version 3.4.2.
jFuzzyLogic_2.0.7.jar library must be added to the build path.
If no "Fclurl" parameter is specified in the Java Applet Run configuration,
then the applet will try "fcl/FTJSC.fcl" (please see init() in fuzzy.java).
Description of controller
The fuzzy rules are implemented based on the paper "A fuzzy logic controller for traffic
junction signals" by Chou et al. The traffic junctions are controlled in a
synchronous manner, where all the traffic lights change signals simultaneously,
and are adjusted with the same delays. This was the approach that excelled, as shown
by Chou et al. in the aforementioned paper. The fuzzy logic rules and membership
functions can of course be modified in order to implement other sets of rules
and membership functions proposed by other researchers in the field. This is simply a
proof-of-concept.
The traffic generated by the trafficControl code resembles an oversaturated traffic
situation; a situation that has shown to be hard to deal with when using a fixed-cycle
controller, and where a fuzzy logic-based controller excels. Again, one can implement
other traffic generation models with ease.