Commit | Line | Data |
---|---|---|
df3ef2db BA |
1 | checkOutput = function(varName, array, refArray, tol) |
2 | { | |
3 | print(paste("Checking ",varName,sep="")) | |
4 | maxError = max(abs(array - refArray)) | |
c2028869 | 5 | if(maxError >= tol){ |
df3ef2db | 6 | print(paste("Inaccuracy: max(abs(error)) = ",maxError," >= ",tol,sep="")) |
c2028869 | 7 | } else{ |
df3ef2db BA |
8 | print("OK") |
9 | } | |
10 | } |