# Error reading CGNS file with arbitrary polyhedral elements

**URL:** https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286
**Category:** ParaView Support
**Created:** [January 24, 2021, 2:04pm UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286 "2021-01-24T14:04:51Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![mnataraj](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/m/5f8ce5/32.png) [@mnataraj](https://discourse.paraview.org/u/mnataraj)
#### Post date: [January 24, 2021, 2:04pm UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/1 "2021-01-24T14:04:51Z")

</div>

Hi,

I am using Paraview to visualize a CGNS file which was generated by one of the test examples in the CGNS github. It gives an error “Mixed definition of unstructured zone by elements and by faces is not valid”. Here is the link to the cgns file.

> **[elemtest.cgns](https://www.dropbox.com/s/0isbgxajitd27cd/elemtest.cgns?dl=0)**
>
> Shared with Dropbox

---

<div class="post-metadata">

### Author: ![MicK7](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mick7/32/1374_2.png) [@MicK7](https://discourse.paraview.org/u/MicK7)
#### Post date: [February 15, 2021, 6:55am UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/2 "2021-02-15T06:55:31Z")

</div>

The Paraview reported error seems clear. You can’t mixed ngon/nface with classical unstructured elements. Thanks for pointing out the cgns github file that is not up to date.

---

<div class="post-metadata">

### Author: ![mnataraj](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/m/5f8ce5/32.png) [@mnataraj](https://discourse.paraview.org/u/mnataraj)
#### Post date: [February 15, 2021, 8:19pm UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/3 "2021-02-15T20:19:08Z")

</div>

Thanks for the reply, Mickael! That is very useful to know.

---

<div class="post-metadata">

### Author: ![Alexandre\_Minot](https://discourse.paraview.org/user_avatar/discourse.paraview.org/alexandre_minot/32/7132_2.png) [@Alexandre\_Minot](https://discourse.paraview.org/u/Alexandre_Minot)
#### Post date: [April 18, 2022, 7:51pm UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/4 "2022-04-18T19:51:50Z")

</div>

Hi Mickaël,

We have not found anything in the CGNS documentation that indicates that ngons and canonical elements must but separated. Could you refer us to such document or explain how the standard does not allow for it?

Many thanks,  
Alexandre

---

<div class="post-metadata">

### Author: ![MicK7](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mick7/32/1374_2.png) [@MicK7](https://discourse.paraview.org/u/MicK7)
#### Post date: [April 19, 2022, 4:13pm UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/5 "2022-04-19T16:13:04Z")

</div>

Hello, what is your use case ?  
Indeed the standard does not prevent you from using both in the same zone. But, it isconvenient for ParaView reader to assume that we are not mixing the two worlds.

---

<div class="post-metadata">

### Author: ![Alexandre\_Minot](https://discourse.paraview.org/user_avatar/discourse.paraview.org/alexandre_minot/32/7132_2.png) [@Alexandre\_Minot](https://discourse.paraview.org/u/Alexandre_Minot)
#### Post date: [April 19, 2022, 7:24pm UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/6 "2022-04-19T19:24:22Z")

</div>

Thanks for your answer. We are working on some internal mesh reorganization and are considering our options, so no finished use case yet. Compatibility with existing readers is one of the elements we are taking into account.

---

<div class="post-metadata">

### Author: ![MicK7](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mick7/32/1374_2.png) [@MicK7](https://discourse.paraview.org/u/MicK7)
#### Post date: [October 16, 2024, 9:15am UTC](https://discourse.paraview.org/t/error-reading-cgns-file-with-arbitrary-polyhedral-elements/6286/7 "2024-10-16T09:15:55Z")

</div>

I checked the source recently and I think the reader has loosen its requirements. You can now have separate classical elements + Ngon but still no MIXED element sections.
