static public AASimilarity GetInstance(string similarity)
 {
     if (similarity == "Eq")
     {
         EqClassDefinitions aEqClassDefinitions = new EqClassDefinitions();
         aEqClassDefinitions.Name = similarity;
         aEqClassDefinitions.EqClassCollection = EqClassDefinitions.GetEqClassCollection();
         return(aEqClassDefinitions);
     }
     else
     {
         HowConsevered howConsevered;
         if (similarity == "Con")
         {
             howConsevered = HowConsevered.Conserved;
         }
         else
         {
             Debug.Assert(similarity == "Semi");
             howConsevered = HowConsevered.SemiConserved;
         }
         AASimilarity aaSimilarity = TangriEtAl.GetInstance(howConsevered);
         return(aaSimilarity);
     }
 }
        static public TangriEtAl GetInstance(HowConsevered howConsevered)
        {
            TangriEtAl aTangriEtAl = new TangriEtAl();

            aTangriEtAl.ReadFile();
            aTangriEtAl.HowConsevered = howConsevered;

            if (howConsevered == HowConsevered.Conserved)
            {
                aTangriEtAl.Name = string.Format("Con");
                //A little unit testing
                Debug.Assert(aTangriEtAl.CanGoToSet('G') == "GSATDP");
            }
            else
            {
                aTangriEtAl.Name = string.Format("Semi");
                //A little unit testing
                Debug.Assert(aTangriEtAl.CanComeFromSet('P') == "ACDEGHIKLMNPQRSTVWY");
            }

            return(aTangriEtAl);
        }