If you have a fixed collection of processes to run on a single processor and unlimited time to schedule them in, you can always brute force all permutations of the processes and then pick whichever permutation maximizes and/or minimizes whatever property you like. The problem with this approach is that it has awful time complexity.
Edit: There’s probably other subtle issues that can arise, like I/O interrupts and other weird events fwiw.
Operating System Concepts by Silberschatz, Galvin and Gagne is a classic OS textbook. Andrew Tanenbaum has some OS books too. I really liked his OS Design and Implementation book but I’m pretty sure that one is super outdated by now. I have not read his newer one but it is called Modern Operating Systems iirc.