Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.

problem of importing a nas mesh file

Please login with a confirmed email address before reporting spam

Hello I am trying to import a very simple nas mesh file into comsol. But i got an error message which says: "Mesh is incorrect. -Detail: Vertex index out of range."

I could not figure out why. Can anybody help ?

The mesh is attached.

Thanks, Quan



3 Replies Last Post Nov 8, 2019, 4:13 a.m. EST
Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 4 years ago Nov 7, 2019, 5:07 a.m. EST

Hi Quan,

The problem with this file is that the GRID lines contain "Grid" instead of all uppercase "GRID". If you make that change the import works as expected. Was this file created by another software or was it created manually? We haven't seen NASTRAN mesh files with "Grid" written in that way, but if such files are created from another software, we will look into relaxing the requirement that the dataset names are written using all uppercase letters.

Best regards,

Magnus Ringh, COMSOL

Hi Quan, The problem with this file is that the GRID lines contain "Grid" instead of all uppercase "GRID". If you make that change the import works as expected. Was this file created by another software or was it created manually? We haven't seen NASTRAN mesh files with "Grid" written in that way, but if such files are created from another software, we will look into relaxing the requirement that the dataset names are written using all uppercase letters. Best regards, Magnus Ringh, COMSOL

Please login with a confirmed email address before reporting spam

Posted: 4 years ago Nov 7, 2019, 10:02 a.m. EST
Updated: 4 years ago Nov 7, 2019, 5:02 a.m. EST

Thanks, Magnus.

It is generated by myself using matlab. I think even if you dont relax the uppercase requirement because it was not generated from a standard process, you should change the error message so that it is easier for the users to debug.

Thanks, Magnus. It is generated by myself using matlab. I think even if you dont relax the uppercase requirement because it was not generated from a standard process, you should change the error message so that it is easier for the users to debug.

Lars Gregersen COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 4 years ago Nov 8, 2019, 4:13 a.m. EST

Hi Quan

If you have LiveLink for Matlab then you can use the API for setting up a mesh without having to resport to using a file.

See the section Getting and Setting Mesh Data in the Programming Reference Manual for more infomation. For a standard mesh you only have to specify vertices (setVertex) and elements (setElem). See the attached example.

-------------------
Lars Gregersen
Comsol Denmark
Hi Quan If you have LiveLink for Matlab then you can use the API for setting up a mesh without having to resport to using a file. See the section Getting and Setting Mesh Data in the Programming Reference Manual for more infomation. For a standard mesh you only have to specify vertices (setVertex) and elements (setElem). See the attached example.

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.