To machinate is to scheme or plan something. You might, for example, machinate a way to defeat the more popular candidate in an election for school president.
You can use the verb machinate in two ways: to arrange or plan in a carefully detailed way, or to plot in an equally careful but somewhat sneaky or underhanded way. While a teacher might machinate to best organize and inspire her class, a movie villain also machinates in order to defeat the hero. Both meanings come from the same root, the noun machination, "plotting or intrigue," which is ultimately rooted in the Latin machina, "device or machine."