Skip to main content
. 2022 Aug 29;7(3):124. doi: 10.3390/biomimetics7030124
Algorithm 1 BAS Algorithm.
  • Objective Function:

  • F(X,O)

  • DBAS Initialization:

  • η=0.99

  • d=0.9

  • τ=0.9

  • Portfolio Initialization:

  • T=iter

  • D=dim

  • X=randn(1,D)

  • O=[Mn,Cn]Mn: Mean Cn: Covariance

  • Fbest=F(X,P)

  • Xbest=X

  • Fori=1:T

  •        b=randn(1,D)

  •        Compute Xr and Xl using (29) and (30)

  •        Compute Fr and Fl suing (31) and (32)

  •        Compute X using (34)

  •        F=F(X,O)

  •        

  •        IfFmin<Fbest:

  •                Fbest=Fmax

  •                Xbest=X

  •        Else:

  •               X=Xbest

  •        End If

  •        

  •        d=ηd+0.01

  •        τ=ητ

  • End For