The value of X is determined only as Fraying Sanity's triggered ability resolves. For example, if three Fraying Sanity Auras are attached to one player who had four cards put into their graveyard this turn, X will be four for the first ability to resolve, eight for the second, and sixteen for the third.