Write_Geometry1D Subroutine

public subroutine Write_Geometry1D(myGeom, fileName)

Arguments

TypeIntentOptionalAttributesName
class(Geometry1D), intent(in) :: myGeom
character, intent(in), optional :: fileName

Contents

Source Code


Source Code

  subroutine Write_Geometry1D(myGeom,fileName)
    implicit none
    class(Geometry1D),intent(in) :: myGeom
    character(*),optional,intent(in) :: fileName
    ! Local
    integer(HID_T) :: fileId
    ! Local
    character(LEN=self_FileNameLength) :: pickupFile

    if(present(filename)) then
      pickupFile = filename
    else
      pickupFile = 'mesh.h5'
    endif

    call Open_HDF5(pickupFile,H5F_ACC_TRUNC_F,fileId)

    call CreateGroup_HDF5(fileId,'/quadrature')

    call WriteArray_HDF5(fileId,'/quadrature/xi', &
                         myGeom%x%interp%controlPoints)

    call WriteArray_HDF5(fileId,'/quadrature/weights', &
                         myGeom%x%interp%qWeights)

    call WriteArray_HDF5(fileId,'/quadrature/dgmatrix', &
                         myGeom%x%interp%dgMatrix)

    call WriteArray_HDF5(fileId,'/quadrature/dmatrix', &
                         myGeom%x%interp%dMatrix)

    call CreateGroup_HDF5(fileId,'/mesh')

    call CreateGroup_HDF5(fileId,'/mesh/interior')

    call CreateGroup_HDF5(fileId,'/mesh/boundary')

    call WriteArray_HDF5(fileId,'/mesh/interior/x',myGeom%x%interior)

    call WriteArray_HDF5(fileId,'/mesh/interior/dxds',myGeom%dxds%interior)

    call WriteArray_HDF5(fileId,'/mesh/boundary/x',myGeom%x%boundary)

    call WriteArray_HDF5(fileId,'/mesh/boundary/dxds',myGeom%dxds%boundary)

    call Close_HDF5(fileId)

  endsubroutine Write_Geometry1D