This figure need to create a function calculating the APD ... working well on openCOR by modifying the model