anchor.diff:              | ex -> failwith ex.Message
   
           let mutable commandQueue = new CommandQueue(provider, provider.Devices |> Seq.head)
  +
  +        let multiplicateProbabilities = probabilityMultQuote
  +        let summProbabilities = probabilitySummQuote
   
           let command = 
               <@
  
positive.code:                     let tj = r.GlobalID1                    
                      let mutable buf = c.[ti * resultColumns + tj]
                      for k in 0 .. vectorLength - 1 do
                          buf <- Probability.innerMult a.[ti * vectorLength + k] b.[k * resultColumns + tj]
                                 |> Probability.innerSumm buf
                      c.[ti * resultColumns + tj] <- buf
              @>
  
          member this.multiplicate (nt1Matrix: ProbabilityMatrix.T) (nt2Matrix: ProbabilityMatrix.T) (from1: SubMatrix.T) (from2: SubMatrix.T) actualColCount =
              let from1Matrix = nt1Matrix.[fst from1.Left..(fst from1.Right - 1), 
                                           snd from1.Left..(snd from1.Right - 1)]
              let from2Matrix = nt2Matrix.[fst from2.Left..(fst from2.Right - 1),
                                           (snd from2.Left)..(snd from2.Right - 1 - (from1.Size - actualColCount))]
  
      //        if from1.Size >= 4
      //        then
      //        else
  
              let resultRows = from1.Size
              let resultColumns = actualColCount
              let vectorLength = from1.Size
          
              let result = Array.zeroCreate(from1.Size * actualColCount)
  
              let kernel, kernelPrepare, kernelRun = provider.Compile command
      
              let d = new _2D(from1.Size, actualColCount, min 4 from1.Size, 1)
              kernelPrepare d resultColumns vectorLength from1Matrix.innerValue from2Matrix.innerValue result
           
              commandQueue.Add(kernelRun()).Finish() |> ignore        
              commandQueue.Add(result.ToHost provider).Finish() |> ignore
  
              ProbabilityMatrix.create result from1.Size actualColCount
  
          member this.releaseResources =
              commandQueue.Dispose()
              provider.Dispose()
              provider.CloseAllBuffers()
  
              
      type SimpleMatriceswMultiplicator () =
  
          member this.multiplicate (nt1Matrix: ProbabilityMatrix.T) (nt2Matrix: ProbabilityMatrix.T) (from1: SubMatrix.T) (from2: SubMatrix.T) actualColCount =
              let from1Matrix = nt1Matrix.[fst from1.Left..(fst from1.Right - 1), 
                                           snd from1.Left..(snd from1.Right - 1)]
              let from2Matrix = nt2Matrix.[fst from2.Left..(fst from2.Right - 1),
                                           (snd from2.Left)..(snd from2.Right - 1 - (from1.Size - actualColCount))]
  
              let resultRows = from1.Size
              let resultColumns = actualColCount
              let vectorLength = from1.Size
          
              let calculateCell (i, j) = 
                  [0..vectorLength - 1] 
                  |> List.fold (fun buf k -> Probability.summ buf (Probability.multiplicate from1Matrix.[i, k] from2Matrix.[k, j])) 
                               Probability.zero    
                               
              ProbabilityMatrix.init resultRows resultColumns calculateCell 
  
         
      type MatrixHolder(tKeys, pKeys, stringSize) = 
      
          let GPUMultiplicator = new GPUMatriceswMultiplicator ()
          let simpleMultiplicator = new SimpleMatriceswMultiplicator ()
              
          // swich to dictionary (?)
          let tMatrix = Map<NonTerminal, ProbabilityMatrix.T>
  
negative.code:                 let nt2Matrix = tMatrix.[nt2]
                  let {where=where; from1=from1; from2=from2} = task
                  let actualColCount = (min (snd task.from2.Top) (stringSize + 1)) - snd task.from2.Left
  
                  let from1Matrix = nt1Matrix.[fst from1.Left..(fst from1.Right - 1), 
                                               snd from1.Left..(snd from1.Right - 1)]
                  let from2Matrix = nt2Matrix.[fst from2.Left..(fst from2.Right - 1),
                                               (snd from2.Left)..(snd from2.Right - 1 - (from1.Size - actualColCount))]
                  
                  let resultRows = from1.Size
                  let resultColumns = actualColCount
                  let vectorLength = from1.Size
  
                  let multiplicationResult = GPUMultiplicator.multiplicate from1Matrix.innerValue 
                                                                           from2Matrix.innerValue 
                                                                           resultRows
                                                                           resultColumns
                                                                           vectorLength
                  ProbabilityMatrix.create multiplicationResult resultRows resultColumns
                  |> addProbsToPSubMatrix task.where nts 
  //                else addProbsToPSubMatrix nts (simpleMultiplicator.multiplicate nt1Matrix nt2Matrix task.from1 task.from2 actualColCount) task.where               
                  
              crossproduct tasks nts |> Array.iter performOneTask