OK, you'll get a bit of pseudo-code/algebra, that solves most of the problem. Lets write the equation for the plane as:
that is all points in 3-D r who's scalar product with the unit-vector,
normal to the plane, is l. We then write the equation for the line: This gives us the equation for the line-plane intersection:
Which we can solve for s at the intersection:
giving us the intersection-point:
So that makes the first step.
Next step I'd take would be to make a 2-D coordinate system in the plane, any random origin-point will do (one of your polygon-points seems convenient), then a unit-vector towards one of its neighbors will make a good direction, and an arbitrary direction perpendicular to that. Now you have an origin and 2 basis-vectors for your plane and can convert your 5+1 (minus the origin-point...) to their corresponding points in this plane. That completes the second step.
Third step is to use the matlab-function inpolygon - which gives you the in/out-answer.
I leave the 2 last steps for you to do, it shold be rather straightforward, and makes for a nice geometric function, you can keep forever.
HTH