anchor.diff:                  let f2  = "H2O" |> parseFormulaString 
                   let res = substract f1 f2 |> toString 
                   Expect.equal res "H0.00 O0.00" "Substraction of formulas failed"
  -
           ]
       
       open BioFSharp.Mass  
  
positive.code:                     Root   = (-1. * Isotopes.Table.H1.NatAbundance / Isotopes.Table.H2.NatAbundance)
                      }
                  let H' = createDi "H" (Isotopes.Table.H1,Isotopes.Table.H1.NatAbundance) (Isotopes.Table.H2,Isotopes.Table.H2.NatAbundance) 
                  Expect.isTrue (H=H') (sprintf "%A <> %A, check parameter order 'create'" H H')
  
              testCase "test_createTriIsotopic" <| fun () ->
                  let compareComplexNumbers (c1:System.Numerics.Complex) (c2:System.Numerics.Complex) = 
                      (Math.Abs(c1.Real - c2.Real) <= 0.0001) &&
                      (Math.Abs(c1.Imaginary - c2.Imaginary) <= 0.0001);     
                  let (rootO,rootO') =
                      System.Numerics.Complex(-0.0926829268292669, 22.0592593273255),
                      System.Numerics.Complex(-0.0926829268292696, -22.0592593273255)
  
negative.code:                     Root   = (rootO,rootO')//
                      }
                  let O' = createTri "O" (Isotopes.Table.O16,Isotopes.Table.O16.NatAbundance) (Isotopes.Table.O17,Isotopes.Table.O17.NatAbundance) (Isotopes.Table.O18,Isotopes.Table.O18.NatAbundance)
                  yield 
                      testList "test_createTriIsotopic" [
                          testCase "calcRootsTri_firstReal" <| fun () ->
                              Expect.floatClose Accuracy.high (fst O.Root).Real (fst O'.Root).Real ""
                          testCase "calcRootsTri_secondReal" <| fun () ->
                              Expect.floatClose Accuracy.high (snd O.Root).Real (snd O'.Root).Real ""
                          testCase "calcRootsTri_firstImaginary" <| fun () ->
                              Expect.floatClose Accuracy.high (fst O.Root).Imaginary (fst O'.Root).Imaginary ""
                          testCase "calcRootsTri_secondImaginary" <| fun () ->
                              Expect.floatClose Accuracy.high (snd O.Root).Imaginary (snd O'.Root).Imaginary ""
                      ]                                 
                  yield 
                      testCase "initialization" <| fun () ->
                          Expect.equal  O O' "Record initialization via function differs from initialization via record expression. Check parameter order of 'createTri'"                       
              ]
  
              testList "test_TriIsotopicCompare" [    
                  let O   = createTri "O" (Isotopes.Table.O16,Isotopes.Table.O16.NatAbundance) (Isotopes.Table.O17,Isotopes.Table.O17.NatAbundance) (Isotopes.Table.O18,Isotopes.Table.O18.NatAbundance)
                  let O'  = {O with Symbol = "N"}
                  let O'' = {O with Xcomp = nan}
                  yield 
                      testCase "negative" <| fun () ->
                          Expect.notEqual O O' "Expected equality, because the member 'CompareTo' checks for equality of the record field Symbol"                           
                  yield 
                      testCase "positive" <| fun () ->
                          Expect.equal O O'' "Expected equality, because the member 'CompareTo' checks for equality of the record field Symbol"                             
              ]                                    
          ]
      
      open BioFSharp.Formula
  