/// <summary> /// Adds a new Fuzzy Set (Checks for naming /// conflicts first) /// </summary> /// <param name="_fs"></param> /// <returns></returns> public int Add(FuzzySet _fs) { // adds a fuzzy set (checks name first) // -1 = fails FuzzySet k = Find(_fs.GetName()); if (k != null) return -1; int i = FindEmpty(); if (i==-1) return -1; f[i] = _fs; if (i >= numFuzzySets) numFuzzySets=i+1; return i; }