It is difficult to suggest solutions without knowing exactly what the course is, but designing a class project to develop a solution for an analogous problem might be a solution.
Assign the students a project to filter out students with ulterior motives from a theoretical class. The engineers will then be forced to produce a solution for the problem of their own creation while subtly alerting other students that not everyone enrolled in the course is there for the same reason.