Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Retrieve command listing from .db

Status
Not open for further replies.

Wareva

Aerospace
Sep 6, 2007
4
0
0
PT
Hi,
I've got some .db files and I wish to manually edit my problem. I was wondering if there's a way to retrieve the log info or command listing from a db file.

Thanks in advance
 
Replies continue below

Recommended for you

Hi

If you open the db file in ansys, you will be able to write out a lgw file. In this file all commands are listed.
To get the command lines from the db file it self will be a difficult matter, I don't think this is possible.

Garry
 
If you build future models using input files (*.txt, or mac for convenience) this issue can be eliminated. This is a best practice that will come highly recommended from experienced analsysts.
 
Ansys is not by default a parametric based modeling program...infact it is one of the poorest tools one could ever use for modeling. The answer to your question is no. Unless you have the log file; or if the one you want has already been overwritten you're up a creek without a paddle. You have two options:

a) Start over from scratch.
b) If you started w/ CAD geometry you could export any areas, lines, etc from your current database using IGESOUT and read these into the fresh CAD geometry in order to modify the database as needed.

Hope this helps.
 
Thanks for all the replies.

I tried both the CDWRITE and the LGWRITE commands. Both produce a log file full of garbage. Running the log file did not reproduce geometry, mesh or loads, as available in the original db.

Starting from scratch.
 
Wareva,
I dont know what it is you are trying to modify in your existing model....

You could generate an input file from the DB using

*cfopen,inputfile,inp
alls
nnn=ndnext(0)
*dowhile,nnn
*vwrite,nnn,nx(nnn),ny(nnn),nx(nnn)
('n,',F5.5,',',F10.10,',',F10.10,',',F10.10)
!check your fortran format
nnn=ndnext(nnn)
*enddo

!(make similar loop for elements and nodal loads...)

*cfclose
 
Could you be more specific as to what 'garbage' is defined as? Does CDWRITE function properly? I've never had problems with it.

If you choose to take eelco71's approach and export everything to an input file I'd recommend using the *cfwrite command over *vwrite for this application. It's much more user friendly :)

Good luck!
 
As i said, the CDWRITE and LGWRITE commands did produce a log file. Although filled with commands, running the file did not reproduce the original geometry, entirely built on the Ansys GUI. It drew some lines, and it output lots of errors.
 
To my knowledge, the log file is session dependant, not file dependant. Therefore the cdwrite and lgwrite commands will simply produce RESUME,'file','db','directory',0,0
Of course not very usefull.

Selection in GUI by picking will produce KSEL,S, , ,P51X , also not very usefull.

 
Status
Not open for further replies.
Back
Top