@Override
  public W<DeltaMSet> delta(DC obj)
  { if(obj instanceof MSet)
    { MSet that=(MSet)obj;
    
      Set<Pair<T,PT<Integer>>> baseSetA=this.getBaseSet();
      Set<Pair<T,PT<Integer>>> baseSetB=that.getBaseSet();
      
      Set<Pair<Pair<T,PT<Integer>>,Pair<T,PT<Integer>>>> phiMax=getPhiMax(getAllPhis(baseSetA,baseSetB));
      Equality equ=getPhiEqu(phiMax);
      int m=this.size();
      int n=that.size();
      double diffMeasure=(2*getPhiSim(phiMax).getValue()+Similarity.sizeBalance(m,n))/(m+n);
      if(equ.getValue() && m==n && phiMax.size()==m)
      { return new W( new Equality(true),new Similarity(1.0),new DeltaMSet.Id(this));}
      else
      { return new W( new Equality(false), 
                      new Similarity(diffMeasure), 
                      new DeltaMSet( dMax(phiMax),
                                     getMSet(baseSetA.less(dom(phiMax))),
                                     getMSet(baseSetB.less(codom(phiMax)))
                                   )
                    );
      }
    }
    else
    { throw new RuntimeException(obj+"should be of type MSet");} 
  }