Skip to content

Commit 63928ab

Browse files
committed
encap: Stop wasting space during interpolation.
Signed-off-by: Matthew Emmett <[email protected]>
1 parent c204060 commit 63928ab

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/pfasst-encapsulated.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,10 @@ namespace pfasst {
123123
auto* crse_factory = src->get_factory();
124124
auto* fine_factory = dst->get_factory();
125125

126-
vector<Encapsulation<scalar>*> fine_q(ndst), fine_tmp(ndst);
126+
vector<Encapsulation<scalar>*> fine_q(ndst), fine_tmp(nsrc);
127127

128128
for (int m=0; m<ndst; m++) fine_q[m] = dst->get_q(m);
129-
for (int m=0; m<ndst; m++) fine_tmp[m] = fine_factory->create(solution);
129+
for (int m=0; m<nsrc; m++) fine_tmp[m] = fine_factory->create(solution);
130130

131131
if (initial)
132132
for (int m=1; m<ndst; m++)
@@ -145,7 +145,7 @@ namespace pfasst {
145145

146146
dst->get_q(0)->mat_apply(fine_q, 1.0, tmat, fine_tmp, false);
147147

148-
for (int m=0; m<ndst; m++) delete fine_tmp[m];
148+
for (int m=0; m<nsrc; m++) delete fine_tmp[m];
149149
for (int m=0; m<ndst; m++) dst->evaluate(m);
150150

151151

0 commit comments

Comments
 (0)