This is exactly the problem. Sharpness is not based on the sensor side, it’s based on the print side. Dof is based on that range that meets that definition. See @Wlodek , post 41 or any other. I miss the selection of the sensor in your app. The sensor size determines how many times that sensor has to be multiplied to get a print of A4. That sensor size has a certain CoC. They belong together.
If you want to know when diffraction is becoming visible use a diffraction calculator.
I did show you it before. https://www.photopills.com/calculators/diffraction. It depends solely on the sensel size and the f-nr.
I mentioned you as Joanna Meyers for we have been through this and I didn’t get an adequate answer. This is basic. And once one knows the basic, one can play with it.
George