Disk I/O and cdf

*To*: mathgroup at smc.vnet.net*Subject*: [mg120332] Disk I/O and cdf*From*: "W. Craig Carter" <ccarter at mit.edu>*Date*: Tue, 19 Jul 2011 06:56:36 -0400 (EDT)*References*: <201107080854.EAA28729@smc.vnet.net>

Hello, I have an application that I'd like to distribute as a .cdf file. However, the application uses disk i/o to interact with qhull (an open source convex hull swiss army knife). It uses something like the following which I can get to work on Windows and Mac platforms: inputdata = dataAppropriateforQHULL; Export[infile, inputdata]; cmd = "/sw/bin/qconvex Fx i n < " <> infile <> " >" <> outfile; Run[cmd]; hulldata = Import[outfile, "TABLE"]; However, this relies on disk i/o and given a previous response on this group: On 8 Jul, 2011, at 4:54 AM, John Fultz wrote: > > > But, in version 8, the situation has changed significantly. Mathematica can now > directly create and maintain CDF (or sometimes called "FreeCDF") files. Player > can play CDF files. CDF, as they might say, is the new NBP. There remain, of > course, some restrictions as to what can be accomplished in the Player. The > broadest category of items is that CDF files created directly by Mathematica > cannot store new content to disk. They can't use Export[], save files, etc. (*) It appears that this strategy wouldn't work. Does anyone know of a work-around (i.e., streams to stdin and stdout for qhull)? I can see that I could probably learn to use mathlink and the qhull libraries. But, this will make distribution more tedious. Thanks, Craig

**References**:**Re: How to write a "proper" math document***From:*John Fultz <jfultz@wolfram.com>