How to get the origin of coordinate in the group?

my su model for test is as following :

the base origin of coordinate is (0,0,0,) ,but the origin of coordinate in this group is not (0,0,0):

I am developing SU with C++,and I had tried mant ways to get the origin of coordinate in this group, however I haven’t found the right way to get it until now.

anyone knows the right ways by API Of C++ or Ruby?

If grp is the group, in Ruby:

grp_origin = grp.transformation.origin