@spiceErrorCheck<EOL>def union(a, b):
assert isinstance(a, stypes.SpiceCell)<EOL>assert isinstance(b, stypes.SpiceCell)<EOL>assert a.dtype == b.dtype<EOL>if a.dtype is <NUM_LIT:0>:<EOL><INDENT>c = stypes.SPICECHAR_CELL(max(a.size, b.size), max(a.length, b.length))<EOL><DEDENT>elif a.dtype is <NUM_LIT:1>:<EOL><INDENT>c = stypes.SPICEDOUBLE_CELL(max(a.size, b.size))<EOL><DEDENT>elif a.dtype is <NUM_LIT:2>:<EOL><INDENT>c = stypes.SPICEINT_CELL(max(a.size, b.size))<EOL><DEDENT>else:<EOL><INDENT>raise NotImplementedError<EOL><DEDENT>libspice.union_c(ctypes.byref(a), ctypes.byref(b), ctypes.byref(c))<EOL>return c<EOL>
Compute the union of two sets of any data type to form a third set.

http://naif.jpl.nasa.gov/pub/naif/toolkit_docs/C/cspice/union_c.html

:param a: First input set.
:type a: spiceypy.utils.support_types.SpiceCell
:param b: Second input set.
:type b: spiceypy.utils.support_types.SpiceCell
:return: Union of a and b.
:rtype: spiceypy.utils.support_types.SpiceCell