You are on page 1of 10

See discussions, stats, and author profiles for this publication at: https://www.researchgate.

net/publication/360223623

Contemporary Fuzzy Logic, A Perspective of Fuzzy Logic with Scilab

Book · May 2022


DOI: 10.1007/978-3-030-98974-3

CITATIONS READS

0 143

3 authors, including:

Stefania Tomasiello Vincenzo Loia


University of Tartu Università degli Studi di Salerno
95 PUBLICATIONS   995 CITATIONS    437 PUBLICATIONS   7,442 CITATIONS   

SEE PROFILE SEE PROFILE

Some of the authors of this publication are also working on these related projects:

Designing an Energy Management System for smart houses View project

Special Issue: Towards robust explainable and interpretable artificial intelligence in Evolutionary Intelligence View project

All content following this page was uploaded by Stefania Tomasiello on 14 May 2022.

The user has requested enhancement of the downloaded file.


Big and Integrated Artificial Intelligence

Volume 1

Series Editor
Vincenzo Loia, Department of Management and Innovation Systems, University of
Salerno, Fisciano, Italy
The series “Big and Integrated Artificial Intelligence” (BINARI) publishes new
developments and advances in the theory and computational aspects of AI in the
context of Big Data Engineering. The aim is to address the issues related to the inte-
gration of different technologies, as well as the engineering aspects of the deploy-
ment of integrated AI technologies in real-world scenarios—quickly and with a high
quality.
The intent is to cover the theory, applications, and design methods of BigAI as
a dual concept of big data and AI, embedded in the fields of engineering, computer
science, physics and life sciences, as well as the methodologies behind them. The
series contains monographs, lecture notes and edited volumes in the Big and Inte-
grated Artificial Intelligence intending to integrate multiple AI technologies (e.g.,
vision, speech, real-time control) in order to develop efficient and robust systems
interacting in the real world.
Topics covered include, but are not limited to, multimodal representations and
modeling, deep architectures and learning algorithms, self-monitoring systems, high-
dimensional data driven systems, optimization schemes, uncertainty handling.
Of particular value to both the contributors and the readership are the short publi-
cation timeframe and the world-wide distribution, which enable both wide and rapid
dissemination of research output.

More information about this series at https://link.springer.com/bookseries/16396


Stefania Tomasiello · Witold Pedrycz ·
Vincenzo Loia

Contemporary Fuzzy Logic


A Perspective of Fuzzy Logic with Scilab
Stefania Tomasiello Witold Pedrycz
Institute of Computer Science Department of Electrical and Computer
University of Tartu Engineering
Tartu, Estonia University of Alberta
Edmonton, AB, Canada
Vincenzo Loia
Department of Management and Innovation
Systems
University of Salerno
Fisciano, Salerno, Italy

ISSN 2662-4133 ISSN 2662-4141 (electronic)


Big and Integrated Artificial Intelligence
ISBN 978-3-030-98973-6 ISBN 978-3-030-98974-3 (eBook)
https://doi.org/10.1007/978-3-030-98974-3

© The Editor(s) (if applicable) and The Author(s), under exclusive license to Springer Nature
Switzerland AG 2022
This work is subject to copyright. All rights are solely and exclusively licensed by the Publisher, whether
the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse
of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and
transmission or information storage and retrieval, electronic adaptation, computer software, or by similar
or dissimilar methodology now known or hereafter developed.
The use of general descriptive names, registered names, trademarks, service marks, etc. in this publication
does not imply, even in the absence of a specific statement, that such names are exempt from the relevant
protective laws and regulations and therefore free for general use.
The publisher, the authors and the editors are safe to assume that the advice and information in this book
are believed to be true and accurate at the date of publication. Neither the publisher nor the authors or
the editors give a warranty, expressed or implied, with respect to the material contained herein or for any
errors or omissions that may have been made. The publisher remains neutral with regard to jurisdictional
claims in published maps and institutional affiliations.

This Springer imprint is published by the registered company Springer Nature Switzerland AG
The registered company address is: Gewerbestrasse 11, 6330 Cham, Switzerland
To all the enthusiastic students and learners
Preface

Writing a book is like a journey through past experiences that one may want to
share with potential readers. The Italian writer Italo Calvino in “Six Memos for the
Next Millennium”, a book of undelivered lectures scheduled at Harvard University,
pinpoints the essential features of a book: lightness, quickness, exactitude, visibility,
multiplicity, and consistency. Even though these features were meant for novels, we
believe that most of them also apply to a scientific textbook. Armed with such a vision,
we wish to offer to the readers a synthesis of our research and experience through
the courses we have delivered to upper-level undergraduate students and to graduate
students majoring in computer science, mathematics, physics, and engineering.
More than half a century has passed since fuzzy logic appeared, but the research in
this area is still very active, with many applications in different fields of our modern
society. The COVID-19 pandemic, which has upset everyone’s life, has also brought
changes in our work habits. More than ever, especially for students, the availability
of free and open-source software has been important.
In this book, the reader is introduced to basic concepts that span the classical
notions of fuzzy logic to more advanced notions from the current state-of-the-art
research. Each of the major topics is accompanied with examples and Scilab codes.
To the best of our knowledge, this is the first book presenting topics in fuzzy logic
with the support of free open-source software, such as Scilab. Even though this book
may be used as a textbook for some courses, there are sufficient ideas for starting
research projects in fuzzy logic.
We wish to thank our students, whose questions inspired many of this book’s exam-
ples and problems. Stefania Tomasiello acknowledges funding from the European
Social Fund via the IT Academy programme.

Tartu, Estonia Stefania Tomasiello


Edmonton, Canada Witold Pedrycz
Salerno, Italy Vincenzo Loia

vii
Contents

1 Introduction to Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1


1.1 Fuzzy Sets: Some Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
1.1.1 Sets and Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.2 Support, Core, Height . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5
1.2 Operations on Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.3 α-Level Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
1.4 Generalizations of Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.4.1 Type-2 Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.4.2 Intuitionistic, Neutrosophic and Rough Sets . . . . . . . . . . . . . . 15
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
2 Fuzzy Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.1 Zadeh’s Extension Principle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.2 Fuzzy Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.2.1 Parametric Form of Fuzzy Numbers and Types
of Fuzzy Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
2.2.2 Fuzzy Partition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
2.3 Interval Arithmetics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
2.4 Arithmetic Operations with Fuzzy Numbers . . . . . . . . . . . . . . . . . . . . 27
2.4.1 First Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
2.4.2 Second Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
2.4.3 Method for LR-Type Fuzzy Numbers . . . . . . . . . . . . . . . . . . . 32
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
3 Fuzzy Relations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
3.1 Fuzzy Relations on Sets and Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . 37
3.1.1 Relations and Fuzzy Relations . . . . . . . . . . . . . . . . . . . . . . . . . 37
3.1.2 Fuzzy Relations on Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . 41
3.2 Composition of Fuzzy Relations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
3.2.1 Set-Relation Composition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
3.3 Fuzzy Relational Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44

ix
x Contents

3.3.1 Fuzzy Relational Equations with the Max-Min


Composition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
3.3.2 Bilinear Fuzzy Relation Equations . . . . . . . . . . . . . . . . . . . . . . 45
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
4 Fuzzy Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
4.1 Logic and Fuzzy Logic: A Brief Overview . . . . . . . . . . . . . . . . . . . . . 49
4.2 Fuzzy Logic Basic Connectives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
4.3 Generalized Composition of Fuzzy Relations . . . . . . . . . . . . . . . . . . . 55
4.4 Linguistic Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
4.5 Linguistic Modifiers and Composite Linguistic Terms . . . . . . . . . . . 56
4.6 Fuzzy Propositions, Modus Ponens and Generalized Modus
Ponens . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
5 Fuzzy Inference Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
5.1 Fuzzy Rule Bases . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
5.1.1 Single Rule with Single Antecedent . . . . . . . . . . . . . . . . . . . . . 62
5.1.2 Single Rule with Multiple Antecedents . . . . . . . . . . . . . . . . . . 63
5.1.3 Multiple Rules with Multiple Antecedents . . . . . . . . . . . . . . . 63
5.2 Fuzzy Controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
5.2.1 Fuzzy Controllers and Dynamical Systems . . . . . . . . . . . . . . . 65
5.3 Mamdani System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
5.3.1 Defuzzification Methods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
5.4 Takagi-Sugeno-Kang System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
6 Combining Artificial Neural Networks and Fuzzy Sets . . . . . . . . . . . . . 79
6.1 A Brief Introduction to Artificial Neural Networks . . . . . . . . . . . . . . 79
6.2 A Fuzzy Neural Network . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
6.3 Adaptive Neuro-Fuzzy Inference System (ANFIS) . . . . . . . . . . . . . . 83
6.4 An ANFIS Variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
6.4.1 The ANFIS Variant Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
7 Fuzzy Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
7.1 Direct and Inverse Fuzzy Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
7.1.1 Fuzzy Partitions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
7.1.2 F-Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
7.1.3 F-Transform in Two Variables . . . . . . . . . . . . . . . . . . . . . . . . . 97
7.2 Types of Fuzzy Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
7.2.1 F1 –Transform . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
7.2.2 Least–Squares Based F0 -Transform . . . . . . . . . . . . . . . . . . . . . 100
7.3 Application to Data Compression . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
7.3.1 F0 -Transform Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102
7.4 Application to Machine Learning Algorithms . . . . . . . . . . . . . . . . . . . 104
7.4.1 Local Weighted Regression . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
Contents xi

7.4.2 Lazy Learning with F-Transform . . . . . . . . . . . . . . . . . . . . . . . 106


References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107
8 Introduction to Granular Computing . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109
8.1 Fundamentals of Granular Computing . . . . . . . . . . . . . . . . . . . . . . . . . 109
8.1.1 Information Granules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109
8.1.2 Granularity and Fuzzy Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111
8.1.3 Construction of Information Granules Through
Clustering . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 112
8.1.4 Another Type of Information Granule . . . . . . . . . . . . . . . . . . . 113
8.2 Granular Neural Networks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
8.2.1 Granular Functional Networks and Granular
Functional Link Artificial Neural Networks . . . . . . . . . . . . . . 115
8.2.2 A Granular Recurrent Neural Network . . . . . . . . . . . . . . . . . . 118
References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124

Appendix A: Scilab Notes and Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 125

View publication stats

You might also like