anchor.diff:  
   
           let getCtemP n (B:Matrix<float>) (h:Vector<float>) =
  +
               let Ctemp = Matrix.zero (4*(n-1)+1) n
  -            //Constraint fr monoton steigend
  -            for i=1 to (n-1) do
  -                for j=1 to n do
  -                    if (j<i) then
  -                        Ctemp.[(4*i - 3) - 1 , j - 1] <- 0.0
  -                        Ctemp.[(4*i - 1) - 1 , j - 1] <- 0.0 - B.[i-1 , j-1]
  -                        Ctemp.[(4*i - 0) - 1 , j - 1] <- 0.0 - B.[i , j-1]
  -                    elif (j=i) then
  -                        Ctemp.[(4*i - 3) - 1 , j - 1] <- (-3.0 / h.[i-1])
  -                        Ctemp.[(4*i - 1) - 1 , j - 1] <- (-3.0 / h.[i-1]) - B.[i-1 , j-1]
  -                        Ctemp.[(4*i - 0) - 1 , j - 1] <- (-3.0 / h.[i-1]) - B.[i , j-1]
  -                    elif (j=i+1) then
  -                        Ctemp.[(4*i - 3) - 1 , j - 1] <- (+3.0 / h.[i-1])
  -                        Ctemp.[(4*i - 1) - 1 , j - 1] <- (+3.0 / h.[i-1]) - B.[i-1 , j-1]
  -                        Ctemp.[(4*i - 0) - 1 , j - 1] <- (+3.0 / h.[i-1]) - B.[i , j-1]
  -                    else
  -                        Ctemp.[(4*i - 3) - 1 , j - 1] <- 0.0
  -                        Ctemp.[(4*i - 1) - 1 , j - 1] <- 0.0 - B.[i-1 , j-1]
  -                        Ctemp.[(4*i - 0) - 1 , j - 1] <- 0.0 - B.[i , j-1]
  -                    Ctemp.[(4*i - 2) - 1 , j - 1] <- B.[i-1 , j-1]
  -            for j in 1 .. n do
  -                 Ctemp.[(4*(n-1)) + 1 - 1 , j - 1] <- B.[n-1 , j-1]
  -        
  +
  +            for i = 1 to (n - 1) do    
  +                let temp = 
  +                    let htemp = 3./h.[i-1]
  +                    (List.init (i-1) (fun x -> 0.))::[-htemp]::[htemp]::[(List.init (n-i-1) (fun x -> 0.))]
  +                    |> List.concat
  +                    |> vector
  +                Matrix.setRow Ctemp (4*i-4) temp
  +                Matrix.setRow Ctemp (4*i-3) (B.Row (i-1) |> vector)
  +                Matrix.setRow Ctemp (4*i-2) (temp - (B.Row (i-1) |> vector))
  +                Matrix.setRow Ctemp (4*i-1) (temp - (B.Row (i) |> vector))
               Ctemp
   
   
  
positive.code:     open FSharp.Stats
      open FSharp.Stats.Optimization
  
  
      let private spline operator (x:Vector<float>) (y:Vector<float>) (W:Matrix<float>) lambd =
  
  
negative.code:         let Q = calcGlambda (Matrix.ofArray2D D) (Matrix.ofArray2D H) W n lambd 
          let c = calcclambda W n y lambd |> Vector.toArray
  
          let b = Array.create ((A |> Array2D.length1)) (-infinity,0.) //Array.create n (-infinity,0.) // Reconsider
  
          let a' = 
              let tmp = Matrix.create Q.NumRows Q.NumCols 1. |> setDiagonalInplace 0.5
  