We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 487244b commit abf9e7bCopy full SHA for abf9e7b
particles/particles.py
@@ -148,7 +148,7 @@ def update(self, coords_n_momenta_dict):
148
raise ValueError("lengths of given phase space coordinate arrays" +
149
" do not coincide with self.macroparticlenumber.")
150
for coord, array in coords_n_momenta_dict.items():
151
- setattr(self, coord, array)
+ setattr(self, coord, array.copy())
152
self.coords_n_momenta.update(coords_n_momenta_dict.keys())
153
154
def add(self, coordinate, array):
0 commit comments