I have a block of code as such, and I am trying to modify it with query-replace-regexp in emacs.
fz.D(1,:) = Dcen;
fz.vol(1,:) = (4/3)*pi*((fz.D(1,:)/2).^3);
fz.POC(1,:) = Ac*fz.vol(1,:).^bc;
fz.w(1,:) = cw*fz.D(1,:).^eta;
% size - bin edges
fzl.D(1,:) = Dlim;
I want it to look as so:
fz.D(ind,:) = fz.D(1,:);
fz.vol(ind,:) = fz.vol(1,:);
fz.POC(ind,:) = fz.POC(ind,:);
and so fourth.
I tried to enact this change with the following, but it doesn't seem to work
query-replace-regexp
\(*\)(1,:) = *; -> \1(k,:) = \1(1,:);
But that seems to do nothing.
Any suggestions about how I should fix this?