Coreform Cubit Version: Cubit 16.14
Platform: Windows
I am seeing unexpectedly large geometric errors when creating an ellipsoid by (1) creating a unit sphere and (2) scaling it anisotropically. The issue is especially pronounced for small ellipsoids, where the axis-aligned bounding box (AABB) lengths deviate substantially from the intended semi-axes.
# Import
import numpy as np
cubit.reset()
# Create ellipsoid (x/a)**2 + (y/b)**2 + (z/c)**2 = 1
a, b, c = 1., 2., 3.
cubit.cmd('sphere r 1')
vol_id = cubit.get_last_id('volume')
cubit.cmd(f'vol {vol_id} scale x {a} y {b} z {c}')
# Compute relative errors (using AABB extents)
aabb = cubit.volume(vol_id).bounding_box()
x_length = aabb[3] - aabb[0]
y_length = aabb[4] - aabb[1]
z_length = aabb[5] - aabb[2]
print(f'Relative error in total x-axis length = {np.abs(x_length-2*a)/(2*a)}')
print(f'Relative error in total y-axis length = {np.abs(y_length-2*b)/(2*b)}')
print(f'Relative error in total z-axis length = {np.abs(z_length-2*c)/(2*c)}')
# Create smaller ellipsoid
a, b, c = 0.01, 0.02, 0.03
cubit.cmd('sphere r 1')
vol_id = cubit.get_last_id('volume')
cubit.cmd(f'vol {vol_id} scale x {a} y {b} z {c}')
# Compute relative errors
aabb = cubit.volume(vol_id).bounding_box()
x_length = aabb[3] - aabb[0]
y_length = aabb[4] - aabb[1]
z_length = aabb[5] - aabb[2]
print(f'Relative error in total x-axis length = {np.abs(x_length-2*a)/(2*a)}')
print(f'Relative error in total y-axis length = {np.abs(y_length-2*b)/(2*b)}')
print(f'Relative error in total z-axis length = {np.abs(z_length-2*c)/(2*c)}')
Output observed
For a,b,c = 1,2,3:
Relative error in total x-axis length ≈ 0.0404
Relative error in total y-axis length ≈ 0.0532
Relative error in total z-axis length ≈ 0.00033
For a,b,c = 0.01,0.02,0.03:
Relative error in total x-axis length ≈ 0.2590
Relative error in total y-axis length ≈ 0.7612
Relative error in total z-axis length ≈ 0.0333
Thanks in advance for any help.






