%------------------------------------
\begin{algorithm}
\caption{HHS \cite{Branch1998}}
\label{hhsa}
\begin{algorithmic}[1] %1表示每隔一行编号
\Require The original signal $x$.
\Ensure The energy-time-frequency distribution of $x$.
\Function{EMD}{$x, seg\_len$}
\State $ N \gets length(x) / seg\_len$;
\For {$i=1 \to i=N$}
\State $seg(i) \gets x(1+(i-1)*seg\_len : i*seg\_len)$;
\EndFor
\EndFunction
\end{algorithmic}
\end{algorithm}
\renewcommand{\algorithmicensure}{\textbf{Output:}} % Use Output in the format of Algorithm
\begin{algorithm}[h]
\caption{Conjugate Gradient Algorithm with Dynamic Step-Size Control} % 名称
\label{alg::conjugateGradient}
\begin{algorithmic}[1]
\Require
$x_0$: initial individual, i.e, state;
$x_0$: initial solution;
$s$: step size;
\Ensure
optimal $x^{*}$
\State initial $g_0=0$ and $d_0=0$;
\Repeat
\State compute gradient directions $g_k=\bigtriangledown f(x_k)$;
\State compute Polak-Ribiere parameter $\beta_k=\frac{g_k^{T}(g_k-g_{k-1})}{\parallel g_{k-1} \parallel^{2}}$;
\State compute the conjugate directions $d_k=-g_k+\beta_k d_{k-1}$;
\State compute the step size $\alpha_k=s/\parallel d_k \parallel_{2}$;
\Until{($f(x_k)>f(x_{k-1})$)}
\end{algorithmic}
\end{algorithm}
\IncMargin{1em}
\begin{algorithm}
\caption{XXXXXX)}\label{algo_disjdecomp}
\SetKwData{Left}{left}\SetKwData{This}{this}\SetKwData{Up}{up}
\SetKwFunction{Union}{Union}\SetKwFunction{FindCompress}{FindCompress}
\SetKwInOut{Input}{input}\SetKwInOut{Output}{output}
\Input{${d_j^{t_k}}^\ast $, ${S_i}^\ast $, ${RIE_k}$}
\Output{${d_j^{t_k}}^\ast $, ${S_i}^\ast $, ${RIE_k}$}
\BlankLine
%\emph{${d_j^{t_k}}^\ast $ $\leftarrow$ $\emptyset$}; \emph{${S_i}^\ast $ $\leftarrow$ $\emptyset$} \;
% Calculate the formulation that connects participants \emph{$ u_j $} and task \emph{$t_k$} \;
\For {$\vee t_{1}, t_{2} \in\left(0, t_{n}\right]$}{
\If {$T>0$}{
\For{$k\leftarrow 1$ \KwTo $N_{ub}^t$}{
\If {the number of subarea index for task {$ k > 1 $}}
{Choose initial subarea \emph{$ a_i $} satisfying formula ()\;
\lElse {Apply right hand to find a set of subareas satisfying formula () based on both the current location of participant \emph{$u_j$} and the location of task \emph{$t_k$}}\;}
\If {{$acc < 0 $}}
{
\If {{$ N_{index}^e > 0 $}}
{Choose next subarea \;
\lElse {${S_i}^\ast $ $\leftarrow$ $a_i$;}}
\lElse {Choose next endpoint;}}
}
\If {{$ d_j^{t_k} < D_j $}}
{
${d_j^{t_k}}^\ast $ $\leftarrow$ $ d_j^{t_k} $;
}
}
}
return ${d_j^{t_k}}^\ast $, ${S_i}^\ast $
\end{algorithm}\DecMargin{1em}
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/ed65729c347829f74f79361bf2de7c1f.png)