Linear scaling methods, such as ONIOM and QM/MM, work by partitioning the system into different layers or regions. In ONIOM, for example, the system is divided into a high-level quantum mechanical (QM) region and a low-level molecular mechanics (MM) region. The high-level calculations are performed only on the most critical part of the system, while the rest is treated with less expensive methods. This reduces the overall computational cost without sacrificing much accuracy.