New: diagnosticfunctions