これ 面白い
貼っておきます

https://www.researchgate.net/publication/233525067_Modifications_of_Thomae's_Function_and_Differentiability
Modifications of Thomae's Function and Differentiability
June 2009
The American Mathematical Monthly
116(6):531-535
Kevin Beanland
James W. Roberts
Craig Stevenson

Download full^text

Abstract
In 1875, K. J. Thomae discovered the now-famous example of a real-valued function that is continuous on the irrationals and not continuous on the rationals. This function is presented in many undergraduate real analysis courses and is known, to some, as the 'popcorn' function. It is not difficult to see that Thomae's function is not differentiable anywhere. The question we examine here is whether it can be modified to be differentiable on some subset of the irrationals. The answer may surprise you—it certainly surprised us.