![]() |
Documentation
Tools for embedded systems
|
A wrapper for the FIS object. More...
#include <fis.hpp>
Public Member Functions | |
| constexpr | system (const rules *r) |
| bool | setup (void) |
| Setup and initialize the FIS instance. | |
| bool | setupInput (const tag t, const real_t Min, const real_t Max) noexcept |
| Setup the input with the specified tag and set limits for it. | |
| bool | setupOutput (const tag t, const real_t Min, const real_t Max) noexcept |
| Setup the output with the specified tag and set limits for it. | |
| bool | setupInputMF (const tag io, const tag mf, const shapeMF s, const real_t *cp, const real_t h=1.0_re) noexcept |
| Setup the input tag and points for the specified membership function. | |
| bool | setupInputMF (const tag io, const tag mf, mfFunction customMfs, const real_t *cp, const real_t h=1.0_re) noexcept |
| Setup the input tag and points for the specified membership function. | |
| bool | setupOutputMF (const tag io, const tag mf, const shapeMF s, const real_t *cp, const real_t h=1.0_re) noexcept |
| Set the output tag and points for the specified membership function. | |
| bool | setupOutputMF (const tag io, const tag mf, mfFunction customMfs, const real_t *cp, const real_t h=1.0_re) noexcept |
| Set the output tag and points for the specified membership function. | |
| bool | fuzzify (void) noexcept |
| Perform the fuzzification operation over the crisp inputs on the requested FIS object. | |
| bool | deFuzzify (void) noexcept |
| Perform the de-Fuzzification operation to compute the crisp outputs. | |
| bool | inference (void) noexcept |
| Perform the inference process on the FIS object. | |
| bool | setInput (const tag t, const real_t value) noexcept |
| Set a crisp value of the input with the specified tag. | |
| bool | getOutput (const tag t, real_t &value) const noexcept |
| Get the de-fuzzified crisp value from the output with the specified tag. | |
| bool | setParameter (const parameter p, const paramValue x) noexcept |
| Set parameters of the FIS instance. | |
| bool | setDeFuzzMethod (deFuzzMethod m) noexcept |
| Change the default de-Fuzzification method of the FIS instance. | |
| bool | setRuleWeights (real_t *rWeights) noexcept |
| Set weights to the rules of the inference system. | |
| size_t | getNumberOfPoints (void) const noexcept |
| Get the number of points used on Mamdani to perform the de-fuzzification proccess. | |
| real_t | operator[] (tag outTag) const |
| Get the de-fuzzified crisp value from the output with the specified tag. | |
| system & | operator<< (const tag &t) |
| Select the input to set using with the specified tag. | |
| system & | operator<< (const int &value) |
| The value to set the previously selected input. | |
| system & | operator<< (const real_t &value) |
| The value to set the previously selected input. | |
| bool | isInitialized (void) const |
| Check if the FIS system has been initialized. | |
| operator bool () const noexcept | |
| Check if the FIS system has been initialized. | |
A wrapper for the FIS object.
The instance should be initialized using the fisSystem::setup() method.
| fType | Type of inference Mamdani, Sugeno or Tsukamoto. |
| numberOfInputs | The number of inputs of the FIS system. |
| numberOfOutputs | The number of outputs of the FIS system. |
| numberOfInputSets | The number of sets/membership functions for the inputs. |
| numberOfOutputSets | The number of sets/membership functions for the outputs. |
| numberOfRules | Number of rules |
|
inlineconstexpr |
|
inlinenoexcept |
Perform the de-Fuzzification operation to compute the crisp outputs.
true on success, otherwise return false.
|
inlinenoexcept |
Perform the fuzzification operation over the crisp inputs on the requested FIS object.
true on success, otherwise return false.
|
inlinenoexcept |
Get the number of points used on Mamdani to perform the de-fuzzification proccess.
|
inlinenoexcept |
Get the de-fuzzified crisp value from the output with the specified tag.
| [in] | t | The output tag |
| [out] | value | The variable where the output will be stored. |
|
inlinenoexcept |
Perform the inference process on the FIS object.
true on success, otherwise return false.
|
inline |
Check if the FIS system has been initialized.
true if instance has been initialized
|
inlineexplicitnoexcept |
Check if the FIS system has been initialized.
true if instance has been initialized
|
inline |
The value to set the previously selected input.
| [in] | value | The crisp value to set |
|
inline |
The value to set the previously selected input.
| [in] | value | The crisp value to set |
|
inline |
Select the input to set using with the specified tag.
| [in] | t | The input tag |
|
inline |
Get the de-fuzzified crisp value from the output with the specified tag.
| [in] | outTag | The output tag |
|
inlinenoexcept |
Change the default de-Fuzzification method of the FIS instance.
| [in] | m | The de-fuzzification method: use one of the following : centroid, bisector, mom, lom, som, wtaver, wtsum |
true on success, otherwise return false
|
inlinenoexcept |
Set a crisp value of the input with the specified tag.
| [in] | t | The input tag |
| [in] | value | The crisp value to set |
true on success, otherwise return false.
|
inlinenoexcept |
Set parameters of the FIS instance.
| [in] | p | The requested parameter to change/set. |
| [in] | x | The value of the parameter to set. |
true on success, otherwise return false.
|
inlinenoexcept |
Set weights to the rules of the inference system.
| [in] | rWeights | An array with the values of every rule weight; |
true on success, otherwise return false.
|
inline |
Setup and initialize the FIS instance.
true on success, otherwise return false.
|
inlinenoexcept |
Setup the input with the specified tag and set limits for it.
| [in] | t | The input tag |
| [in] | Min | Minimum allowed value for this input |
| [in] | Max | Max allowed value for this input |
true on success, otherwise return false.
|
inlinenoexcept |
Setup the input tag and points for the specified membership function.
| [in] | io | The input tag related with this membership function |
| [in] | mf | The user-defined tag for this membership function |
| [in] | s | The wanted shape/form for this membership function, can be one of the following: trimf, trapmf, gbellmf, gaussmf, gauss2mf, sigmf, dsigmf, psigmf, pimf, smf, zmf, singletonmf, concavemf, spikemf, linsmf, linzmf, rectmf, cosmf. |
| [in] | cp | Points or coefficients of the membership function. |
| [in] | h | Height of the membership function. |
true on success, otherwise return false.
|
inlinenoexcept |
Setup the input tag and points for the specified membership function.
| [in] | io | The input tag related with this membership function |
| [in] | mf | The user-defined tag for this membership function |
| [in] | customMfs | Custom user-defined membership function. |
| [in] | cp | Points or coefficients of the membership function. |
| [in] | h | Height of the membership function. |
true on success, otherwise return false.
|
inlinenoexcept |
Setup the output with the specified tag and set limits for it.
| [in] | t | The output tag |
| [in] | Min | Minimum allowed value for this output |
| [in] | Max | Max allowed value for this output |
true on success, otherwise return false.
|
inlinenoexcept |
Set the output tag and points for the specified membership function.
| [in] | io | The output tag related with this membership function |
| [in] | mf | The user-defined tag for this membership function |
| [in] | s | The wanted shape/form for this membership function, can be one of the following: trimf, trapmf, gbellmf, gaussmf, gauss2mf, sigmf, dsigmf, psigmf, pimf, smf, zmf, singletonmf, concavemf, spikemf, linsmf, linzmf, rectmf, cosmf. |
| [in] | cp | Points or coefficients of the membership function. |
| [in] | h | Height of the membership function. |
true on success, otherwise return false.
|
inlinenoexcept |
Set the output tag and points for the specified membership function.
| [in] | io | The output tag related with this membership function |
| [in] | mf | The user-defined tag for this membership function |
| [in] | customMfs | Custom user-defined membership function. |
| [in] | cp | Points or coefficients of the membership function. |
| [in] | h | Height of the membership function. |
true on success, otherwise return false.