can anybody explain what the differences are between an array based sequence and a list based sequence and why the structural comparison works in one but not in the other?
let listCompared = [[1.0; 0.0; 0.0]; [0.0; 1.0; 0.0]] = [[1.0; 0.0; 0.0]; [0.0; 1.0; 0.0]]
let arrayCompared = [|[|1.0; 0.0; 0.0|]; [|0.0; 1.0; 0.0|]|] = [|[|1.0; 0.0; 0.0|]; [|0.0; 1.0; 0.0|]|]
let fromList xs = xs |> List.map List.toSeq |> List.toSeq
let fromArray xs = xs |> Array.map Array.toSeq |> Array.toSeq
let listSeqCompared = (fromList [[1.0; 0.0; 0.0]; [0.0; 1.0; 0.0]]) = (fromList [[1.0; 0.0; 0.0]; [0.0; 1.0; 0.0]])
let arraySeqCompared = (fromArray [|[|1.0; 0.0; 0.0|]; [|0.0; 1.0; 0.0|]|]) = (fromArray [|[|1.0; 0.0; 0.0|]; [|0.0; 1.0; 0.0|]|])
let lazyCompared = seq{yield seq{yield 1.0; yield 0.0; yield 0.0}; yield seq{yield 0.0; yield 1.0; yield 0.0}} = seq{yield seq{yield 1.0; yield 0.0; yield 0.0}; yield seq{yield 0.0; yield 1.0; yield 0.0}}
>>>
val listCompared : bool = true
val arrayCompared : bool = true
val fromList : xs:'a list list -> seq<seq<'a>>
val fromArray : xs:'a [] [] -> seq<seq<'a>>
val listSeqCompared : bool = true
val arraySeqCompared : bool = false
val lazyCompared : bool = false