change asDoubleArray to toDoubleArray in Linear
avoid allocation of new array by wrapping existing array
Merge pull request #65 from prasant94/develop

change asDoubleArray to toDoubleArray in Linear