


HIT_PWA Evaluate a PWA function.
-------------------------------------------------------------------------
DESCRIPTION
-------------------------------------------------------------------------
[y,region]=hit_pwa(theta,regions,point)
-------------------------------------------------------------------------
INPUT
-------------------------------------------------------------------------
theta{i}: PV of the i-th mode.
regions(i): polyhedron describing the region of the i-th mode.
point: vector describing the point at which the map will be evaluated (it
can be either a row or a column).
-------------------------------------------------------------------------
OUTPUT
-------------------------------------------------------------------------
y: value of the PWA map. It is NaN if the point does not fall in at least
one region. This allows one to skip the point when using plot or plot3.
region: number of the region the point belongs to. It is NaN if the point
does not fall in at least one region.