It gets real complicated. The goal is to run each aircraft as hard as possible. If it’s not moving, it’s not making money.
For a domestic hub & spoke operation the airplane will thread in and out, in and out, in and out all day. It’ll probably go to a different out-station each time with the goal of filling the entire workday with the max number of hours. An airplane just shuttling between A & B & A & B over and over all day would be very unusual unless you’re talking about a small carrier with only a handful of destinations.
Each aircraft needs an overnight inspection every few days. Not every station is equipped to do that, and even the stations that are staffed for it will specialize in one aircraft type. So out of, say, 20 stations where a particular type overnights, only 3 can do the work on them.
So the maintenance department arranges a flow where each airplane cycles to sleep at a different station each night, passing through the desired inspection station once a week. So airplane A zigs & zags all day to & fro ending up at ABC for its inspection. The next five nights it sleeps at DEF, GHI, JKL, MNO, & PQR respectively. Finally the next day ( night 7 in the cycle) it does the same pattern as the first day, ending at ABC for its next weekly inspection. Meantime Airplane B is flying the very same weeklong pattern, just one day behind aircraft A. Airplanes C, D, E, & F follow along, each one day behind the previous.
Now mix in 3 or 4 or 8 hubs, hub-to-hub flying, international long haul, spares, malfunctions, diversions, weather, cancellations, etc., etc. The published schedule is also different on all 7 days of the week. M-F are usually pretty similar, but Sat & Sun are different from weekdays and different from each other.
And at least once a month the whole thing changes as we work through the seasons and holidays.
You can see why those scheduling departments run on Red Bull & Excedrin at work, and scotch after hours.