Group Abstract Group Abstract

Message Boards Message Boards

Errors of exporting FITS file

Could anyone help? Always getting errors when export simple data to FITS format. I'm using Macbook Air, OS X 10.8.4. Not sure if it's machine dependent.   

 d = First@
 Export["image.fits", d]
 ConstantArray::ilsmn: Single or list of non-negative machine-sized integers expected at position 2 of ConstantArray[32,{-17}]. >>
 Join::heads: Heads List and ConstantArray at positions 1 and 3 are expected to be the same. >>
 BinaryWrite::nocoerce: Join[{83,73,77,80,76,69,32,32,61,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,84,32,47,32,78,111,114,109,97,108,32,70,73,84,83,32,102,105,108,101,32,<<750>>},<<3>>,{32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,<<13>>,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,<<27>>}] cannot be coerced to the specified format. >>
1 year ago

It worked for me using Mathematica9 under Windows 7.  Here is the header dump of the exported file using DS9:

SIMPLE = T / Normal FITS file
BITPIX = 16 / Bits/pixel, negative is floating point
NAXIS = 2 / Dimensionality of data
NAXIS1 = 561
NAXIS2 = 561
EXTENDED= T / Extensions may be present
PCOUNT = 0 / Deprecated
GCOUNT = 1 / Deprecated
BSCALE = 1 / Scale factor
BZERO = 0 / Zero factor real=tape*bscale+bzero
CREATOR = 'Created by Wolfram Mathematica 9.0 :'

Let me know if you want it tried using Mathematica8 (under Windows). 
POSTED BY: Frank Iannarilli
1 year ago
I have the same problem exporting FITS files. I'm running Mathematica 9 on Ubuntu 12.04 LTS (KDE). The error message when I export a known good FITS file is:
ConstantArray::ilsmn: "Single or list of non-negative machine-sized integers expected at position 2 of ConstantArray[32,{-17}]"
POSTED BY: Jonathan Aguilar
1 year ago