Trying to get the indentation right within the algorithmic environment I run into trouble, and all the solutions posted so far have not been able to solve my problem as I'd like to see it solved.
I want continued lines to have an indentation w.r.t the initial line (new to this forum and yet unable to post images).
However, the best I get with what I've found on this forum is either a fixed indentation for all continued lines (i.e., no difference if the initial line was indented or not), or the same indentation as the initial line (see MWE below).
Anybody has an answer to this?
\documentclass[10pt, A4]{report}
\usepackage{algorithm}
\usepackage{algpseudocode}
\begin{document}
\begin{algorithmic}\raggedright
\State Define N\_crf as the number of points on the circumference of the hyperstreamline, which will define its cross-sectional area at each r
\For {n = 1 : number of tracts}
\State \parbox[t]{\dimexpr\linewidth-\algorithmicindent\relax}{define N\_crf points creating a unit circle around r(n,i), in the plane perpendicular to t(n,i).}\strut
\EndFor
\end{algorithmic}
\end{document}