1. O2 Sensor: A faulty oxygen sensor can affect the air-fuel ratio, causing the engine to run rich or lean. This can lead to various issues, including engine performance problems, increased emissions, and potentially the symptoms you described.
2. Leaking Head Gasket: A leak in the head gasket can cause compression issues, resulting in rough idling, misfires, and knocking sounds. It can also lead to coolant leaks and oil contamination, which can further impact engine performance.
3. Spark Plugs or Ignition System: Worn-out or faulty spark plugs, as well as issues with the ignition system (e.g., ignition coil, spark plug wires), can cause misfires and lead to the engine running rough. This can also result in sparks or arcing if the ignition system is compromised.
4. Bad Gas: Using contaminated or old gasoline can cause a range of issues, including engine knocking, poor performance, and even damage to the engine components.
It's important to note that these are just possible explanations, and the exact cause may be different. To accurately identify the root cause, it would be best to have a qualified mechanic diagnose the vehicle, preferably with the help of diagnostic tools and visual inspections.