-1

I use the following code for my project I can't write it

for j = l :n 
    if j > 1 
        A(j:n,j) = A(j:n, j) - A(j:n, l :j - l )·A(j, l:j - l )T 
    end 
    A(j:n, j) = A(j:n, j) / J A(j,j) 
end

I use the package for this

\usepackage[ruled,vlined]{algorithm2e}
\usepackage{algorithmic}

I tried to write but I didn't find any solution please help : I sovle it :) enter image description here

  • 2
    You need to check the documentation of algorithm2e which is very helpful. Also, your code doesn't stand as a minimal working example. – Diaa Jan 26 at 17:16
1

You can start with

enter image description here

\documentclass{article}
\usepackage[noline]{algorithm2e}

% https://tex.stackexchange.com/a/362194/2288
\SetKwFor{For}{for }{}{end}

\begin{document}
    \begin{algorithm}
        \For{j = l :n}{
            \If{j > 1}{
                A(j:n,j) = A(j:n, j) - A(j:n, l :j - l )·A(j, l:j - l )T 
            }
            A(j:n, j) = A(j:n, j) / J A(j,j)  
        }
    \end{algorithm}
\end{document}
|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.