# \[GiDlist\] nurbs data

**URL:** <https://forum.gidsimulation.com/t/gidlist-nurbs-data/298>\
**Category:** 2013 - 2005\
**Created:** [September 15, 2013, 9:04am UTC](https://forum.gidsimulation.com/t/gidlist-nurbs-data/298 "2013-09-15T09:04:47Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hoang\_Giang\_Bui](https://forum.gidsimulation.com/letter_avatar_proxy/v4/letter/h/8edcca/32.png) [@Hoang\_Giang\_Bui](https://forum.gidsimulation.com/u/Hoang_Giang_Bui)\
**Post date:** [September 15, 2013, 9:04am UTC](https://forum.gidsimulation.com/t/gidlist-nurbs-data/298/1 "2013-09-15T09:04:47Z")

</div>

Dear Gid list,

I’m interested in reading NURBS data in GID problem type. For example to  
write custom calculation file using customization command specialized  
for .bas file. The problem is that I don’t want the mesh from GID, I  
want to access raw geometrical data using GID command in .bas file. Does  
anyone has any idea on how to achieve this?

BR  
Giang Bui

---

<div class="post-metadata">

**Author:** ![GiDTeam](https://forum.gidsimulation.com/user_avatar/forum.gidsimulation.com/gidteam/32/4_2.png) [@GiDTeam](https://forum.gidsimulation.com/u/GiDTeam)\
**Post date:** [September 16, 2013, 7:26am UTC](https://forum.gidsimulation.com/t/gidlist-nurbs-data/298/2 "2013-09-16T07:26:02Z")

</div>

Dear Giang Bui,  
The only way to access to geometrical data is using a tcl command.  
To get information of surfaces you must use:

GiD\_Geometry get surface 3  
( 3 = num of surface you are interested on )  
more info here:  
[http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_extension/special\_tcl\_commands/geometry](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_extension/special_tcl_commands/geometry)

or:

GiD\_Info list\_entities surfaces 3  
( 3 = num of surface you are interested on )  
more info here:  
[http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_extension/gid\_info\_function/list\_entities](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_extension/gid_info_function/list_entities)  
  
  
If you want to do it on a .bas , you must use: \*tcl (that is a special  
command that let you execute any tcl expression)  
You can define your own tcl procedures on .tcl file

_In the .bas file:_  
\*set var num=3  
\*tcl(WriteSurfaceInfo \*num)

_In the .tcl file:_  
proc WriteSurfaceInfo { num } {  
return [GiD\_Info list\_entities surfaces $num]  
}  
  
  
more info here:  
[http://www.gidhome.com/component/manual/customizationmanual/template\_files/commands\_used\_in\_the\_bas\_file/specific\_commands](http://www.gidhome.com/component/manual/customizationmanual/template_files/commands_used_in_the_bas_file/specific_commands)

Regards,  
Adrià  
  
  
El 15/09/2013 11:04, Hoang Giang Bui escribió:  
_Dear Gid list,_  
_I’m interested in reading NURBS data in GID problem type. For example to_  
_write custom calculation file using customization command specialized_  
_for .bas file. The problem is that I don’t want the mesh from GID, I_  
_want to access raw geometrical data using GID command in .bas file. Does_  
_anyone has any idea on how to achieve this?_  
_BR_  
_Giang Bui_

* * *

_GiDlist mailing list_  
_[GiDlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)_  
\_[http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist\_](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist_)

-------------- next part --------------  
An HTML attachment was scrubbed…  
URL: [http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20130916/1e88bc50/attachment.htm](http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20130916/1e88bc50/attachment.htm)

---

<div class="post-metadata">

**Author:** ![escolano](https://forum.gidsimulation.com/user_avatar/forum.gidsimulation.com/escolano/32/6_2.png) [@escolano](https://forum.gidsimulation.com/u/escolano)\
**Post date:** [September 16, 2013, 8:47am UTC](https://forum.gidsimulation.com/t/gidlist-nurbs-data/298/3 "2013-09-16T08:47:46Z")

</div>

As Adrià said, you must use Tcl commands to get the NURBS information,  
  
  
  
Instead of

GiD\_Info list\_entities

I recommend you the more specialized GiD-Tcl command GiD\_Geometry

e.g.

GiD\_Geometry get surface $num  
  
  
  
Enrique  
  
  
  
De: [gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
[mailto:[gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)] En nombre de Adria Melendo  
Enviado el: lunes, 16 de septiembre de 2013 9:26  
Para: [gidlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
Asunto: Re: [GiDlist] nurbs data  
  
  
  
Dear Giang Bui,  
The only way to access to geometrical data is using a tcl command.  
To get information of surfaces you must use:

GiD\_Geometry get surface 3  
( 3 = num of surface you are interested on )  
more info here:  
[http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_exten](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_exten)  
sion/special\_tcl\_commands/geometry

or:

GiD\_Info list\_entities surfaces 3  
( 3 = num of surface you are interested on )  
more info here:  
[http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_exten](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_exten)  
sion/gid\_info\_function/list\_entities  
  
  
If you want to do it on a .bas , you must use: \*tcl (that is a special  
command that let you execute any tcl expression)  
You can define your own tcl procedures on .tcl file

In the .bas file:  
\*set var num=3  
\*tcl(WriteSurfaceInfo \*num)

In the .tcl file:  
proc WriteSurfaceInfo { num } {  
return [GiD\_Info list\_entities surfaces $num]  
}  
  
  
more info here:  
[http://www.gidhome.com/component/manual/customizationmanual/template\_files/c](http://www.gidhome.com/component/manual/customizationmanual/template_files/c)  
ommands\_used\_in\_the\_bas\_file/specific\_commands

Regards,  
Adrià  
  
  
El 15/09/2013 11:04, Hoang Giang Bui escribió:  
  
  
Dear Gid list,

I’m interested in reading NURBS data in GID problem type. For example to  
write custom calculation file using customization command specialized  
for .bas file. The problem is that I don’t want the mesh from GID, I  
want to access raw geometrical data using GID command in .bas file. Does  
anyone has any idea on how to achieve this?

BR  
Giang Bui

* * *

GiDlist mailing list  
[GiDlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
[http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
  
  
  
  
-------------- next part --------------  
An HTML attachment was scrubbed…  
URL: [http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20130916/da4f59f1/attachment.htm](http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20130916/da4f59f1/attachment.htm)

---

<div class="post-metadata">

**Author:** ![Hoang\_Giang\_Bui](https://forum.gidsimulation.com/letter_avatar_proxy/v4/letter/h/8edcca/32.png) [@Hoang\_Giang\_Bui](https://forum.gidsimulation.com/u/Hoang_Giang_Bui)\
**Post date:** [October 20, 2013, 12:10am UTC](https://forum.gidsimulation.com/t/gidlist-nurbs-data/298/4 "2013-10-20T00:10:57Z")

</div>

Thanks. I can use this technique to generate a data file for NURBS.  
However, I don’t understand how GID generate a NURBS surface by tensor  
product of 2 NURBS curve. I created a NURBS surface on 2D by contour lines  
but the result is just a rectangle, although the screen showed a seemingly  
correct surface. May I know why ?

Bui  
  
  
  
On Mon, Sep 16, 2013 at 10:47 AM, Enrique Escolano  
[escolano at cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)wrote:

_As Adrià said, you must use Tcl commands to get the NURBS information,\*\*\*\*_  
_\*\* \*\*_  
_Instead of \*\*\*\*_  
_GiD\_Info list\_entities\*\*\*\*_  
_I recommend you the more specialized GiD-Tcl command GiD\_Geometry\*\*\*\*_  
_e.g. \*\*\*\*_  
_GiD\_Geometry get surface $num\*\*\*\*_  
_\*\* \*\*_  
_Enrique\*\*\*\*_  
_\*\* \*\*_  
_De: [gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist) [mailto:_  
_[gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)] \*En nomb\*\*re de \*Adria Melendo_  
_Enviado el: lunes, 16 de septiembre de 2013 9:26_  
_Para: [gidlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)_  
_Asunto: Re: [GiDlist] nurbs data\*\*\*\*_  
_\*\* \*\*_  
_Dear Giang Bui,_  
_The only way to access to geometrical data is using a tcl command._  
_To get information of surfaces you must use:_  
_GiD\_Geometry get surface 3_  
_( 3 = num of surface you are interested on )_  
_more info here:_  
\_[http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_extension/special\_tcl\_commands/geometry\_](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_extension/special_tcl_commands/geometry_)  
_or:_  
_GiD\_Info list\_entities surfaces 3_  
_( 3 = num of surface you are interested on )_  
_more info here:_  
\_[http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_extension/gid\_info\_function/list\_entities\_](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_extension/gid_info_function/list_entities_)

_If you want to do it on a .bas , you must use: \*tcl (that is a special_  
_command that let you execute any tcl expression)_  
_You can define your own tcl procedures on .tcl file_  
_In the .bas file:_  
_\*set var num=3_  
_\*tcl(WriteSurfaceInfo \*num)_  
_In the .tcl file:_  
_proc WriteSurfaceInfo { num } {_  
_return [GiD\_Info list\_entities surfaces $num]_  
_}_

_more info here:_  
\_[http://www.gidhome.com/component/manual/customizationmanual/template\_files/commands\_used\_in\_the\_bas\_file/specific\_commands\_](http://www.gidhome.com/component/manual/customizationmanual/template_files/commands_used_in_the_bas_file/specific_commands_)  
_Regards,_  
_Adrià_

_El 15/09/2013 11:04, Hoang Giang Bui escribió:\*\*\*\*_  
_\*\* \*\*_  
_Dear Gid list,\*\*\*\*_  
_\*\* \*\*_  
_I’m interested in reading NURBS data in GID problem type. For example to \*\*\*\*_  
_write custom calculation file using customization command specialized \*\*\*\*_  
_for .bas file. The problem is that I don’t want the mesh from GID, I \*\*\*\*_  
_want to access raw geometrical data using GID command in .bas file. Does \*\*\*\*_  
_anyone has any idea on how to achieve this?\*\*\*\*_  
_\*\* \*\*_  
_BR\*\*\*\*_  
_Giang Bui\*\*\*\*_  
_\*\* \*\*_  
\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\__\*\*\*\*_  
_GiDlist mailing list\*\*\*\*_  
_[GiDlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)\*\*\*\*_  
\_[http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist\*\*\*\*\_](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist **** _)  
_\*\* \*\*_  
_\*\* \*\*_

* * *

## _GiDlist mailing list_ _[GiDlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)_ \_[http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist\_](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist_) \

With Best Regards !  
Giang Bui  
To learn and to excel  
-------------- next part --------------  
An HTML attachment was scrubbed…  
URL: [http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20131020/e4840c3b/attachment.htm](http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20131020/e4840c3b/attachment.htm)

---

<div class="post-metadata">

**Author:** ![escolano](https://forum.gidsimulation.com/user_avatar/forum.gidsimulation.com/escolano/32/6_2.png) [@escolano](https://forum.gidsimulation.com/u/escolano)\
**Post date:** [October 21, 2013, 8:55am UTC](https://forum.gidsimulation.com/t/gidlist-nurbs-data/298/5 "2013-10-21T08:55:29Z")

</div>

Because it is a ‘trimmed NURBS surface’,

The underlying shape is provided by the full NURBS surface, in this case a plane defined by a NURBS of degree 1 with only 4 control points

And the ‘valid shape’ is the region inside the trimming curves, that are its boundary lines.  
  
  
  
When creating the surface by boundary, it the boundary has ‘4 sides’ (4 strong corners) you can force GiD to create a ‘untrimmed NURBS surface’,

During the surface creation open the contextual menu (click right mouse button) and select ‘No try planar’

and then select the boundary lines to create the surface.  
  
  
  
Enrique  
  
  
  
De: [gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist) [mailto:[gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)] En nombre de Hoang Giang Bui  
Enviado el: domingo, 20 de octubre de 2013 2:11  
Para: [gidlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
Asunto: Re: [GiDlist] nurbs data  
  
  
  
Thanks. I can use this technique to generate a data file for NURBS. However, I don’t understand how GID generate a NURBS surface by tensor product of 2 NURBS curve. I created a NURBS surface on 2D by contour lines but the result is just a rectangle, although the screen showed a seemingly correct surface. May I know why ?

Bui  
  
  
  
On Mon, Sep 16, 2013 at 10:47 AM, Enrique Escolano [escolano at cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist) wrote:

As Adrià said, you must use Tcl commands to get the NURBS information,  
  
  
  
Instead of

GiD\_Info list\_entities

I recommend you the more specialized GiD-Tcl command GiD\_Geometry

e.g.

GiD\_Geometry get surface $num  
  
  
  
Enrique  
  
  
  
De: [gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist) [mailto:[gidlist-bounces at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)] En nombre de Adria Melendo  
Enviado el: lunes, 16 de septiembre de 2013 9:26  
Para: [gidlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
Asunto: Re: [GiDlist] nurbs data  
  
  
  
Dear Giang Bui,  
The only way to access to geometrical data is using a tcl command.  
To get information of surfaces you must use:

GiD\_Geometry get surface 3  
( 3 = num of surface you are interested on )  
more info here: [http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_extension/special\_tcl\_commands/geometry](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_extension/special_tcl_commands/geometry)

or:

GiD\_Info list\_entities surfaces 3  
( 3 = num of surface you are interested on )  
more info here: [http://www.gidhome.com/component/manual/customizationmanual/tcl\_and\_tk\_extension/gid\_info\_function/list\_entities](http://www.gidhome.com/component/manual/customizationmanual/tcl_and_tk_extension/gid_info_function/list_entities)  
  
  
If you want to do it on a .bas , you must use: \*tcl (that is a special command that let you execute any tcl expression)  
You can define your own tcl procedures on .tcl file

In the .bas file:  
\*set var num=3  
\*tcl(WriteSurfaceInfo \*num)

In the .tcl file:  
proc WriteSurfaceInfo { num } {  
return [GiD\_Info list\_entities surfaces $num]  
}  
  
  
more info here: [http://www.gidhome.com/component/manual/customizationmanual/template\_files/commands\_used\_in\_the\_bas\_file/specific\_commands](http://www.gidhome.com/component/manual/customizationmanual/template_files/commands_used_in_the_bas_file/specific_commands)

Regards,  
Adrià  
  
  
El 15/09/2013 11:04, Hoang Giang Bui escribió:  
  
  
Dear Gid list,

I’m interested in reading NURBS data in GID problem type. For example to  
write custom calculation file using customization command specialized  
for .bas file. The problem is that I don’t want the mesh from GID, I  
want to access raw geometrical data using GID command in .bas file. Does  
anyone has any idea on how to achieve this?

BR  
Giang Bui

* * *

GiDlist mailing list  
[GiDlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
[http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist)  
  
  
  
  
\

* * *

## GiDlist mailing list [GiDlist at listas.cimne.upc.edu](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist) [http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist](http://listas.cimne.upc.edu/cgi-bin/mailman/listinfo/gidlist) \

With Best Regards !  
Giang Bui

To learn and to excel

-------------- next part --------------  
An HTML attachment was scrubbed…  
URL: [http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20131021/5e57e82b/attachment.htm](http://listas.cimne.upc.edu/pipermail/gidlist/attachments/20131021/5e57e82b/attachment.htm)
