function x = mid(x)

% AD implementation of mid.m
% Code written by Ilyssa Sanders and Anil V. Rao
% January 2009

if isa(a.x,'intval')
    x.value = mid(x.value);
    x.derivative = mid(x.derivative);
end