Content deleted Content added
m Changed the name of the function from S(x) to S. |
m →Pseudocode: ''html entities'' |
||
Line 52:
===Pseudocode===
''// Initialize parameters''
μ := −6
t := 0
maxits := 100
N := 100
Ne := 10
''// While maxits not exceeded and not converged''
'''while''' t < maxits '''and'''
''// Obtain N samples from current sampling distribution''
X := SampleGaussian(μ,
''// Evaluate objective function at sampled points''
S := exp(−(X − 2) ^ 2) + 0.8 exp(−(X + 2) ^ 2)
''// Sort X by objective function values in descending order''
X := sort(X, S)
''// Update parameters of sampling distribution''
μ := mean(X(1:Ne))
t := t + 1
''// Return mean of final sampling distribution as solution''
'''return''' mu
|