Skip to content
This repository has been archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
Fixed bug that was preventing initial conditions file from being save…
Browse files Browse the repository at this point in the history
…d when new bodys are added in multiple add_solar_system_body calls
  • Loading branch information
MintoDA1 authored and MintoDA1 committed Oct 3, 2023
1 parent 40b0d0c commit 47e3c88
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions swiftest/simulation_class.py
Original file line number Diff line number Diff line change
Expand Up @@ -2177,10 +2177,8 @@ def add_solar_system_body(self,
dsnew = init_cond.vec2xr(self.param,**kwargs)

dsnew = self._combine_and_fix_dsnew(dsnew)
if dsnew['npl'] > 0 or dsnew['ntp'] > 0:
if dsnew['id'].max(dim='name') > 0 and dsnew['name'].size > 0:
self.save(verbose=False)



self.init_cond = self.data.copy(deep=True)

Expand Down

0 comments on commit 47e3c88

Please sign in to comment.