BUFFALO — Being good students on track to graduate, Wisconsin’s upperclassmen are fluent in all of the cutting-edge statistics that measure sports so intricately these days. Being Badgers, they also recognize where the ratings, evaluations and computer models all fall short.

“The thing is, with all those algorithms, they can’t calculate heart, will to win, toughness, desire,” Nigel Hayes said less than a half-hour after hitting the reverse layup that brought down defending NCAA champion Villanova. “They can’t put that into a formula to come out with a percentage chance to win. And those are the things that we have.”

What the eighth-seeded Badgers also have is a ticket to New York and the Sweet 16 this week after another of its incalculable victories, a 65-62 decision over No. 1 overall seed Villanova on Saturday.

That result certainly did not seem probable with 5:31 remaining, when the Wildcats (32-4) held a 57-50 lead and, apparently, all the cards.

Wisconsin’s top guard, Bronson Koenig, had four fouls. Its most formidable frontcourt scorer, Ethan Happ, had three. What’s more, the Badgers kept missing free throws. But it all changed for a team that had defeated seemingly unbeatable Kentucky two years ago and eliminated higher-seeded Xavier on a last-second three-pointer by Koenig a year ago tomorrow.

This time, the result ensured that The Big Dance will not have its first repeat champion in 10 years.

advertisement | advertise on newsday

“Down the stretch, they made two great offensive plays, two great defensive stops, and that was the difference in the game,” Villanova coach Jay Wright said. “That’s what close games come down to. We’ve been on the other end of that a lot. When another team steps up and makes those plays, you’ve got to give them credit.”

The Badgers held Villanova to a single field goal in the final 5:31, but Wright thought the pivotal play was the one that occurred with 3:28 remaining. The guard known as Klutch Koenig on his campus drilled a three-pointer from the corner to tie it at 57, drawing a huge roar from the Wisconsin contingent and wiping the slate clean from a momentum standpoint. “That’s a breakdown on our part,’’ Wright said, “but it’s also great execution on their part.”

Koenig thought it was the least he could do after spending nearly eight crucial minutes on the bench with foul trouble. “I felt terrible, to say the least,’’ said the young man who is a member of the Ho-Chunk Nation and publicly protested alongside fellow Native Americans against the Dakota Access Pipeline. “I was just trying to be a coach from the bench and help our guys out. I knew that’s not how my career was going to end. I knew when the coach gave me the opportunity to get back in there, I was going to make something happen.”

“Layups are easy. He made the tough jump shots,” Hayes said, referring to another three-pointer by Koenig that put Wisconsin (27-9) up by three with two minutes left.

But nothing is easy when the score is tied and the season is on the line, which was the case when Wisconsin coach Greg Gard called a side isolation play for Hayes with 12 seconds left. The senior forward drove the baseline and made an eye-catching reverse layup. “I actually thought I missed it. I felt I threw it a little too hard,” he said of a shot he never will forget.

After that, Wisconsin denied the ball from playmaker Jalen Brunson, leaving the Wildcats’ best player, Josh Hart, to take it all the way to the basket. Happ got in front of him, turning the driving Hart toward Vitto Brown, who took the ball away before Hart could get off a shot.

“We went into a ball screen, but Wisconsin made a heck of a defensive play,” Hart said, his hopes for a repeat and his college career suddenly ended.

Hayes had 19 points, Koenig 17 and Happ 12 for the Badgers, who were only 7-for-16 on free throws. Hart led Villanova with 19 points and Donte DiVincenzo scored 15.

So it is the team from Madison, Wisconsin, that will play at Madison Square Garden this week. The Badgers are the only team to have emerged from the first weekend in each of the past four NCAA Tournaments. They also have qualities that cannot be measured.

“We played a really great team,” Hayes said. “It took a great effort from us, and we’re just proud of ourselves for getting the job done.”