XANSYS Message: 30 [Go back to message list]
[bookmark on del.icio.us]
No rating yet
Subject: vwrite work around
Author: Joe Rasche
Date: 1998-12-15 16:17:00*vwrite work around!
Thanks Dave and John for the info. It looks like the trick Dave uses will work
for now. We are currently on HP and Sun machines but we will most likely move
to NT in the near future. What do we do then? If we go down this path, we
will
have to rewrite a lot of code when we go to NT. I thought that ANSYS was
supposed to run the same independent of the hardware. Is this still the
approach? Can we have the *vwrite command handle the "I" character?
Best regards,
Joe Rasche
John Swanson wrote:
Sorry, no hidden commands here. We are dealing directly with the
compilers on the
systems. Some choose to allow double precision data to be written
correctly with the "i" format,
some to not.
John.Swanson
Dave Lindeman wrote:
The trick I use is to open a scratch file, use an Fx.0 format for integers, and
follow all integers with a '%' character. For example,
*CFOPEN,scratch,dat
*VWRITE,I
(F6.0,'%')
*CFCLOS
Next, you can use a text editor to eliminate all '.%' combinations, or, under
UNIX
use:
/SYS,sed 's/.%//g' scratch.dat > filename.dat
Alternatively, you can use the CHRVAL function in APDL to first store the
integers as text strings, then use an A* output format.
Regards,
Dave
Initial Question:
> From: jz9hn2@a... ( Joseph A Rasche 230-3796 3892)
> Question: On the *vwrite command, what format character should be
> used to write
> out an integer. ANSYS 5.4 version running on HP and SUN.