FUNCTION REFERENCE

defuzz

Defuzzify a sampled fuzzy set.

Defuzzify a sampled fuzzy set.

Syntax

y = defuzz(x,mf,method)

Methods: centroid, bisector, mom, lom, som. x must be finite and strictly increasing, and mf finite and nonnegative. centroid uses the sampled weighted mean; bisector divides the piecewise-linear area between adjacent samples into two equal halves (matching scikit-fuzzy); zero-area sets error. For all-zero sets, maxima methods use all samples.

Example

defuzz([0 1 2],[0 1 0],"centroid")

Differences from MATLAB: Type-1 fuzzy systems only. Saving fuzzy objects to MAT files is not supported yet. Object arrays are bounded to 65536 rules, 64 variables per direction and 256 MFs per variable. bisector uses piecewise-linear area integration between samples, which may differ slightly from MATLAB on coarse grids.

These are the engine’s help pages. Each page keeps its compatibility notes. File operations are unavailable in the browser.