G54FUZ/COMP4033 Coursework (2020/2021)
Designing and Tuning a Fuzzy Inference System
The coursework is to design an imaginary fuzzy inference system for advising a doctor whether a patient
should be referred to a hospital for emergency investigations based on two biomedical inputs: the patient’s
temperature and severity of headache. You will create several different fuzzy inference systems, with
different terms in the linguistic variables, different membership functions and different rules, carry out
inference using different operators and different defuzzification techniques (and perhaps other similar
variations), and tune the various models by analysing the performance of the various systems. You will write
a report on your various fuzzy models and discuss which is your ‘best’ final model. Marks will be awarded for
the processes employed and the analysis carried out, rather than the absolute performance of your final
system (there is no ‘correct’ final model that you must end up with).
The following scenario is obviously a simplified version of a real medical scenario, but nevertheless you will
need to use the same principles and processes involved in creating a solution for a realistic real-world
scenario. You have been asked to create a fuzzy inference system (FIS) to provide advice to family doctors
that they can use to assess patients when they come in with an illness, to establish whether the patient needs
to be sent to hospital for emergency attention. In this very simple scenario, the FIS will take two inputs,
Temperature and Headache, which will be represented as two fuzzy linguistic variables, and produce a single
output, Urgency, which represents the degree of urgency (or severity) of the patient’s condition. When
provided with numerical inputs in terms of temperature and severity of headache (rated on an arbitrary scale
from 0 to 10), the system will use a set of rules like:
• IF Temperature is high AND Headache is mild THEN Urgency is medium
• IF Temperature is very high AND Headache is severe THEN Urgency is emergency
to produce a single numerical output in the range 0 to 100, with 0 meaning the patient’s condition is not at
all urgent (no need to go to hospital) and 100 meaning extremely urgent (rush to hospital as quickly as
possible). Hint: for Temperature there is a normal range, and both low and high values can indicate a health
problem; while for Headache, the higher the rating, the worse is the problem. Feel free to research normal
and abnormal ranges of temperature on sites such as Wikipedia and NHS Direct, and the various medical
terms that may be used to describe abnormal temperatures and different severities of headache (but do not
worry, this is not supposed to be medically realistic!).
Fuzzy Inference System(s)
You should develop a variety of different FIS using R and the R Fuzzy Toolkit. When constructing various FIS
models, you should consider:
• the number of terms in each input variable (3, 5 or 7 terms) and in the output variable (3 or 5 terms),
giving each term an appropriate linguistic label
• various types of membership functions (triangular, trapezoidal, Gaussian, sigmoidal)
• the precise parameters of each membership function
• the rules that connect the input terms to the output terms
• the fuzzy operators used in the FIS (consider both min/max and product/probabilistic-or families)
• various defuzzification methods
You can make up the various terms in the variables and the rules within your FIS (this is not a test of actual
medical knowledge) in order to create systems with the properties you require. You should examine the
output of different systems at various inputs.
Save your single final ‘best’ FIS and hand it in as described below. This final FIS must be loadable into R.
Data Report Deliverable
In addition to your final FIS, you must submit a written report describing the fuzzy modelling process
conducted. The length of your report is 1000 - 2000 words (maximum) and eight sides of A4, excluding the
cover page, but including all tables and figures, minimum font size 11pt (a full page of text in a similar style
to this document would contain about 800 words, so the only around 2½ pages maximum of the total report
will be text). The report should clearly explain what you did, how and why you did it, and should be well
structured and illustrated. It is alright to use less than 2000 words if you are able to describe the details
required. Your report should consist of three main sections. The first should describe the various models you
have created, taking into account the various model choices described above. The second section should
detail the final model, including its configuration and its full rule set. You must provide illustrative example
input-outputs. The third section should briefly discuss why you have arrived at this final system, and discuss
its operation (why do you feel it works well). You should not include lengthy code, or raw output in the main
body of your report, but you may include these in appendices. Note that appendices will not contribute to
the word count, and are not explicitly marked: they are for additional reference only. While marks will not
be specifically deducted for going over length, ONLY the first 2000 words will be marked (so, for example, if
you use 2000 words in Sections 1 & 2, as per below, you will receive no marks for Section 3).
Assessment Criteria and Marking Guidelines
The report will be assessed out of 25 marks as follows:
• Section 1 – Description of Alternative Fuzzy Models [12 marks]: Marks will be awarded for the
variety of different models you consider, the creativity and imagination used in deriving the terms,
membership functions, rules, etc. While not describing every alternative model in detail, you should
provide evidence that you have implemented these.
• Section 2 – Detail of Final Fuzzy Model [8 marks]: Marks will be awarded for the clear and accurate
description of your ‘final.fis’, and examples.
• Section 3 – Discussion of Final Fuzzy Model [5 marks]: Marks will be awarded for the clarity and
depth of discussion as to why you consider your final FIS to work well, why you made the choices you
made, how you have assessed its performance, and whether you feel it is of good standard. Discuss
limitations of your final FIS and/or problems you encountered.
A further 5 marks will be awarded for the overall structure, style and presentation of your report. A first class
report would have a clear structure with appropriate sub-headings, well-written, clear informative text, and
clear and attractive pictures, graphs and tables. There is no need to provide references. Note that your
‘final.fis’ code will not be marked separately – it is only to confirm that your final FIS does actually work as
described in your report.
Plagiarism vs. Group Discussions
As you know, plagiarism is completely unacceptable and will be dealt with according to the University’s
standard policies. Having said this, we do encourage students to have general discussions regarding the
coursework with each other in order to promote the generation of new ideas and to enhance the learning
experience. This being said, you must be very careful not to cross the boundary into plagiarism. The important
part is that when you sit down to actually do the fuzzy modelling and write about it, you do it individually. If
you do this, and you truly understand what you have written, you will not be guilty of plagiarism. Do NOT,
under any circumstances, share code, figures, or graphs, etc.
Deadline and Submission Procedure
• The submission deadline is 3pm April 28th via Moodle.
• Name your FIS file FUZ-FIS-XXX.fis, and name your report FUZ-CWK-XXX.pdf, where XXX should be
replaced by your student ID number (e.g. 4078181). Submit both via the G54FUZ Moodle page.
• A late penalty of 5% (1.25 absolute marks out of the 25 available) per calendar day (including
weekends) will be applied, to a maximum of one week, after which a mark of zero will be
automatically awarded. Of course, valid extenuating circumstances may override this; if you have any
such extenuating circumstances contact Chao.Chen@nottingham.ac.uk or the School Office as soon
as possible. 学霸联盟