CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Mesh Generation & Pre-Processing Software > Pointwise & Gridgen

HDF5 or ADF?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 16, 2015, 07:32
Default HDF5 or ADF?
  #1
Member
 
Join Date: Jul 2014
Posts: 31
Rep Power: 11
nba1942 is on a distinguished road
Hi, I am trying to export 3d unstructured grid in CGNS format in Pointwise V17.0.

What I need to do is to get my code read up boundary conditions from the grid file.

I am not familiar with CGNS, so I am learning how to use it. I am following steps in "A User's Guide To CGNS".

I made a simple code which does nothing meaningful yet.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
program cgns_test
include 'cgnslib_f.h'
call cg_open_f('cone.cgns',CG_MODE_READ,index_file,ier)
call cg_goto_f(index_file,index_base,ier,'Zone_t',1,
+ 'ZoneBC_t',1,'BC_t',ib,'end')
if (ier .ne. CG_OK) call cg_error_exit_f
print *, index_file,index_base,ier
index_base=1
index_zone=1
call cg_nbocos_f(index_file,index_base,
+ index_zone,nbocos,ier)
print *, index_file,index_base,index_zone,nbocos,ier
stop
end
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

"nbocos" is the number of boundary conditions of the grid, which is updated by the subroutine "cg_nbocos_f". Here is the problem.

I checked that "ier" should be 2(which means "no problem" I guess) and "nbocos" should be the number of the B.C.s from the example code. But in my code with the grid I made, "ier" is 1 and "nbocos" has trash value.

I compiled CGNS library with HDF5 library, not with ADF library. "A User's Guide To CGNS" says that CGNS would automatically read and write files in HDF5 format if the user compiled the library with HDF5.

But I think Pointwise writes the grid file in ADF form, not in HDF5 form.(Actually I am not sure about this. I just found the line saying "....ADF Database Version A02011>AdF0Thu Jul 16 16:04:21 2015 AdF1Thu Jul 16 16:04:21 2015 AdF2LLAdF......" in the binary CGNS grid file)


What I want to ask is;

Is there any way to convert the grid file in ADF form to HDF5 form? or Can Pointwise V17.0 export the grid in HDF5 format?

Waiting for any reply.

Thank you.

PS here is my code and the grid

https://www.dropbox.com/s/fcfzql0mch..._test.zip?dl=0
nba1942 is offline   Reply With Quote

Old   July 16, 2015, 11:35
Default
  #2
Senior Member
 
Zach Davis
Join Date: Jan 2010
Location: Los Angeles, CA
Posts: 101
Rep Power: 16
RcktMan77 is on a distinguished road
Hi,

The CGNS distribution includes a number of tools. One such utility, named adf2hdf will convert your ADF formatted cone.cgns file to an HDF5 formatted file via the command
Code:
adf2hdf cone.cgns
More information about the included CGNS tools can be found at CGNS Tools Documentation page. Also note that the latest release of Pointwise exports CGNS grid files natively using HDF5 rather than ADF as is the case with the older release version that you are using.
RcktMan77 is offline   Reply With Quote

Old   July 16, 2015, 12:19
Default @rcktman77
  #3
Member
 
Join Date: Jul 2014
Posts: 31
Rep Power: 11
nba1942 is on a distinguished road
Thanks for your reply!!

I am pretty sure that you gave me the solution

I will try it right away!
nba1942 is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
HDF5 IO library for OpenFOAM haakon OpenFOAM Programming & Development 41 April 21, 2023 08:30
Sample hdf5 writer iyer.arvind OpenFOAM Post-Processing 7 February 3, 2016 12:19
[General] Time steps, XDMF, and HDF5 Atholis ParaView 1 April 29, 2015 05:30
How could I use CGNS with HDF5 codezy SU2 1 April 8, 2014 02:26
Write data file into a hdf5 format using c++ rahulsng Main CFD Forum 0 January 23, 2012 05:32


All times are GMT -4. The time now is 13:26.