# SPECFEM3D\_Globe with Cubit/Trelis

**URL:** <https://community.geodynamics.org/t/specfem3d-globe-with-cubit-trelis/1119>\
**Category:** SPECFEM\
**Tags:** specfem3d\
**Created:** [February 24, 2020, 10:25pm UTC](https://community.geodynamics.org/t/specfem3d-globe-with-cubit-trelis/1119 "2020-02-24T22:25:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![djherm](https://yyz2.discourse-cdn.com/flex036/user_avatar/community.geodynamics.org/djherm/32/546_2.png) [@djherm](https://community.geodynamics.org/u/djherm)\
**Post date:** [February 24, 2020, 10:25pm UTC](https://community.geodynamics.org/t/specfem3d-globe-with-cubit-trelis/1119/1 "2020-02-24T22:25:01Z")

</div>

Good afternoon,

I am a fairly new user to the SPECFEM code family (and this site overall).

Under the Cartesian Package, I know we are able to input a mesh we generate with CUBIT/TRELIS through code included like run\_cubit2specfem3d.py

However, is it possible (or has it already been attempted) to port a mesh generated in Cubit to SPECFEM3D\_GLOBE? I don’t see the associated code or examples in the GLOBE package compared with Cartesian and am curious if there is some aspect that prevents this transfer.

Thank you for any advice or assistance.

---

<div class="post-metadata">

**Author:** ![dpeter](https://yyz2.discourse-cdn.com/flex036/user_avatar/community.geodynamics.org/dpeter/32/227_2.png) [@dpeter](https://community.geodynamics.org/u/dpeter)\
**Post date:** [February 27, 2020, 7:08pm UTC](https://community.geodynamics.org/t/specfem3d-globe-with-cubit-trelis/1119/2 "2020-02-27T19:08:29Z")

</div>

well, the global version uses the in-house mesher based on a cubed-sphere mesh, which is perfectly balanced between different partitions, and works extensively with geographic/geocentric coordinate transformations. it deals with internal discontinuities and geochemical layering as well as higher sampling for the D’’ region. this mesher is meant to construct a planet.

the Cartesian version allows for much more mesh flexibility. mesh slices with different number of elements are common to load-balance between acoustic/elastic/poroelastic domains. coordinate transformations if needed are done between UTM and Cartesian xyz values. CUBIT/Trelis meshing is only the first step, before partitioning and creating a GLL mesh. this mesher ignores gravitational and rotational effects on waves, thus there is no need to account for radial directions and geographic position.

so in order to port from CUBIT/Trelis to the globe version, it would involve quite some work. it hasn’t been attempted yet - at least not to my knowledge. but, nothing is impossible…

---

<div class="post-metadata">

**Author:** ![djherm](https://yyz2.discourse-cdn.com/flex036/user_avatar/community.geodynamics.org/djherm/32/546_2.png) [@djherm](https://community.geodynamics.org/u/djherm)\
**Post date:** [March 5, 2020, 5:11pm UTC](https://community.geodynamics.org/t/specfem3d-globe-with-cubit-trelis/1119/3 "2020-03-05T17:11:59Z")

</div>

Thank you for the response. That makes sense according to the way you explained it. I would still be interested in eventually trying it, but that may be a project for a different time.

---

<div class="post-metadata">

**Author:** ![brioglade](https://yyz2.discourse-cdn.com/flex036/user_avatar/community.geodynamics.org/brioglade/32/203_2.png) [@brioglade](https://community.geodynamics.org/u/brioglade)\
**Post date:** [January 22, 2021, 6:52am UTC](https://community.geodynamics.org/t/specfem3d-globe-with-cubit-trelis/1119/4 "2021-01-22T06:52:52Z")

</div>

hi,so many indentation errors when I use run\_cubit2specfem3d.py.Did you also meet those indentation errors？
