threshold simulation