Type persuasion for primitive types

These changes allow primitive types to be requested as different types than what is stored in the file format.  Types are cast to the requested type where possible and will suffer precision loss for casting where necessary (e.g. requesting a double as an int).

No performance penalty is imposed for using the type defined in the file type.

A 6x6 test case is provided to test conversion between the primitive types.
why double?