diffのマイナスを無くす計算式 - sirogamichandayo/atcoder-diff-problems-go GitHub Wiki

  • atcoder problemsのdiffにはマイナスが存在するので、切り取りを行うことで負の値を消している。
"abc138_a": {
	"slope": -0.0007168608759555057,
	"intercept": 5.865100960838195,
	"variance": 0.926552668651041,
	"difficulty": -848, // マイナスになってる
	"discrimination": 0.004479398673070138,
	"irt_loglikelihood": -260.5412324380486,
	"irt_users": 4554,
	"is_experimental": false
},

https://kenkoooo.com/atcoder/resources/problem-models.jsonの一部分を表示

計算式(typescript)

  Math.round(
    difficulty >= 400 ? difficulty : 400 / Math.exp(1.0 - difficulty / 400)
  );

https://github.com/kenkoooo/AtCoderProblems/blob/6a7fdf2efc5b02d84e7fafcb262aae8008b3c236/atcoder-problems-frontend/src/utils/index.ts#L49