Create trim_spec.c

Trim functions.