Top Banner
Guest Lecture to ME537 Fall 2010 – Learning Based Control By Matt Knudson, Ph.D. Autonomous Agents and Distributed Intelligence Oregon State University Corvallis, OR 97330 November 3 rd , 2010 OSU Campus Expert Systems and Fuzzy Logic for Non-Linear Control Introduction Expert / Rule-Based Systems – Concepts – Applications Fuzzy Logic – Concepts – Applications Wrap-Up Overview
13

Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

May 13, 2018

Download

Documents

ngonhi
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Guest Lecture to ME537 Fall 2010 – Learning Based Control

By Matt Knudson, Ph.D.

Autonomous Agents and Distributed Intelligence

Oregon State University

Corvallis, OR 97330

November 3rd, 2010

OSU Campus

Expert Systems and Fuzzy Logic for

Non-Linear Control

•! Introduction

•! Expert / Rule-Based Systems

–! Concepts

–! Applications

•! Fuzzy Logic

–! Concepts

–! Applications

•! Wrap-Up

Overview

Page 2: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Expert Systems

•! Model-Based Control Method

•! Encodes ‘Expert’ Knowledge / Behavior

–! Uses inference rules

•! Advantages

–! Consistent Decision Making

–! Maintains Large Amounts of Information

–! Encourages Good Decision-Making Organization

–! Never Ignores Information

•! Disadvantages

–! Lacks Common Sense

–! Errors in Knowledge Breakdown Entire System

Expert Systems: A Concept

•! Uses ‘decision networks’ to encode information

–! Several nodes represent choices made by experts

If Path Clear

Then Define Max Speed

If Close to Goal

Then Refine Max Speed

If Turning Sharp

Then Choose Speed

Page 3: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Expert Systems: A Concept

•! Nodes

–! Chance Nodes: Random variables representing uncertainty.

•! Conditional distribution indexed on parent states

–! Decision Nodes: Where decision maker has a choice of actions.

•! For most control, one decision node

–! Utility Nodes: Utility function (cost) of action taken given state.

•! Often just a tabulation of utility of each state

•! Can be parameterized additive or multilinear

Expert Systems: A Concept

Page 4: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Expert Systems: A Concept

•! Generally two components

–! Decision Maker: Encodes preferences between outcomes

–! Decision Analyst: Enumerates possible actions

•! Elicits preferences from Maker

•! Focus on Decision Maker

–! Several ways to encode preferences

–! Most common: Information Value Theory

•! We’ll avoid the subject here

–! Simplest is inference rules

•! Consist of if-clauses and then-clauses

•! The former is based on information, latter is choice to make

Expert Systems: Example

•! Servo Control

–! Sense position and velocity of controlled object

–! For example: Steering Wheels

•! An ‘expert’ controls the servo a specific way

–! The behavior of the expert is encoded into knowledge

–! Can be simple thresholds

–! “If position error is greater than 0.5 rad”

•! “Then turn motor on”

–! “If rotational velocity is less than 0.2 rad/s”

•! “Then increase motor voltage”

Page 5: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Expert Systems: Design

1.! Create a causal model: Based on expert knowledge.

•! What happens when I do this?

2.! Simplify to qualitative decision model: Remove variables based on expert experiences.

•! Are these two states independent?

3.! Assign probabilities: Likely done via empirical data / laboratory experiments.

•! What is the probability that the system will go to state B from state A?

4.! Assign utilities: Decide when the system has performed well / poorly.

•! Did I minimize cost?

5.! Verify and refine: Based on a gold-standard.

•! How close was I to the expert(s)?

Expert Systems: Results

•! Advantages

–! Very simple computation – even with large stored information

•! Due to information storage / search

–! Great for known-outcome systems

•! Or systems with large amounts of empirical data

–! Very easy to tune

•! Disadvantages:

–! Can be dangerous

•! Experts may not be experts – even if it is you

–! Finding experts (models) difficult

–! Locked in to specific behavior horizons

•! Can result in control discontinuities

Page 6: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic

•! Model-Free Control Method

–! Cut out the expert

•! Stochastic Extension of Boolean

•! Advantages

–! Simple Implementation

–! Powerful / Robust Output

–! Low Tuning Iteration

–! Computationally Trivial

–! Requires only Output Feedback

•! Disadvantages

–! Solution is Engineered

–! No Learning without Accessories

–! Arbitrary Information Flow

Fuzzy Logic: A Concept

•! Extend expert systems

–! Soft decision boundaries

•! Boolean algebra operates on discrete values

–! ‘True’ and ‘False’

•! Fuzzy algebra operates on continuous values

–! ‘Degrees of Truth’

•! Allows state to be continuous from 0 to 1

–! Represents stochastic nature of real world

–! Draws analogy to probability theory

•! Not the same thing!

Page 7: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: A Concept

X Y AND

0 0 0

0 1 0

1 0 0

1 1 1

X Y OR

0 0 0

0 1 1

1 0 1

1 1 1

X NOT

0.2 0.8

0.9 0.1

X Y AND

0.1 0.1 0.1

0.1 0.9 0.1

0.7 0.2 0.2

0.9 1.0 0.9

X Y OR

0.1 0.1 0.1

0.1 0.9 0.9

0.7 0.2 0.7

0.9 1.0 1.0

X NOT

0 1

1 0

Boolean

Fuzzy

Selects Minimum! Selects Maximum! Selects 1-X!

Fuzzy Logic: Mechanics

•! Regions of Truth

–! Regions for input comparison

–! ‘Fuzzification’ is buzzword for the comparison

•! Outputs a ‘truth’

•! Determines how ‘true’ the input is

•! Can be almost any function

•! Linguistic Variables

–! Features of the state space

–! Allows designer and algorithm to think the same

–! ‘Linguistic’ ~= ‘Concept’

Page 8: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: Examples

Fuzzy Logic: Examples

•! Servo

–! off_target: Are we not where we should be?

–! close: Are we close?

–! too_fast: Are we moving too quickly?

•! Terrain

–! wide: Is the potential path wide?

–! direct: Is it direct to the goal?

•! Speed

–! close: Are we near the goal?

–! sharp_turn: When we get there, is the next turn sharp?

–! clear_path: Is the path we’re on clear?

Page 9: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: Algorithm Development

1.! Choose Regions of Truth

2.! Create Fuzzifiers

3.! Select Linguistic Variables

4.! Numerically Define Regions

5.! Fuzzify Inputs for Each Variable

6.! Apply Fuzzy Rule

7.! Repeat from (4)

Fuzzy Logic: Applications

•! Autonomous Navigation

–! Servo Actuation

•! Steering

•! Throttle

•! Brakes

•! Vision

–! Speed Control

–! Terrain Interpretation

Page 10: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: Applications - Servo

Steer Level = Off Target AND NOT ( Close AND Too Fast )

Fuzzy Logic: Applications – Speed Control

Vehicle Speed = Clear Path AND NOT ( Close AND Sharp Turn )

Page 11: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: Applications – Speed Control

Fuzzy Logic: Applications – Terrain Interpretation

Path Quality = Wide AND Direct

Page 12: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: Applications – Terrain Interpretation

Fuzzy Logic: Applications – Autonomous Vehicle

Page 13: Expert Systems and Fuzzy Logic for Non-Linear Controlclasses.engr.oregonstate.edu/mime/fall2010/me537/...Fuzzy Logic •! Model-Free Control Method –! Cut out the expert •! Stochastic

Fuzzy Logic: Results

•! Entire vehicle controlled via Fuzzy Logic

•! Maximum tuning iterations: 10

•! Computation less than 20% of total

•! Powerful

–! Feedback: Position, heading, speed

–! Output: Steering, throttle, brake voltages

•! Robust

–! Overcame large signal errors

–! Correct interpretation with large sensor failures

•! Simple

–! Paper-to-Implementation: 2 hours

Guest Lecture to ME537 Fall 2010 – Learning Based Control

By Matt Knudson, Ph.D.

Autonomous Agents and Distributed Intelligence

Oregon State University

Corvallis, OR 97330

November 3rd, 2010

OSU Campus

Expert Systems and Fuzzy Logic for

Non-Linear Control