Skip to content

Commit 4b429b9

Browse files
author
Ilya Mandel
committed
Added missing virtual declaration to ShouldEnvelopeBeExpelledByPulsations
1 parent a0f1b2b commit 4b429b9

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

compas_matlab_utils/ComparisonPlots.m

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,9 @@ function HMXBplot(file, name, fignumberHMXB, colour, point)
258258
roche2Switch=h5read(file,'/BSE_Switch_Log/RocheLobe(2)');
259259
radius1Switch=h5read(file,'/BSE_Switch_Log/Radius(1)');
260260
radius2Switch=h5read(file,'/BSE_Switch_Log/Radius(2)');
261-
relevantBinaryFrom1 = whichSwitch==1 & fromSwitch==1 & toSwitch==2 & star2Switch==14 & radius1Switch>0.8*roche1Switch & M1Switch>15;
262-
relevantBinaryFrom2 = whichSwitch==2 & fromSwitch==1 & toSwitch==2 & star1Switch==14 & radius2Switch>0.8*roche2Switch & M2Switch>15;
261+
isMergerSwitch=h5read(file,'/BSE_Switch_Log/Is_Merger');
262+
relevantBinaryFrom1 = whichSwitch==1 & fromSwitch==1 & toSwitch==2 & star2Switch==14 & radius1Switch>0.8*roche1Switch & M1Switch>15 & ~isMergerSwitch;
263+
relevantBinaryFrom2 = whichSwitch==2 & fromSwitch==1 & toSwitch==2 & star1Switch==14 & radius2Switch>0.8*roche2Switch & M2Switch>15 & ~isMergerSwitch;
263264
MBH=[MBH; M2Switch(relevantBinaryFrom1); M1Switch(relevantBinaryFrom2)];
264265
MO=[MO; M1Switch(relevantBinaryFrom2); M2Switch(relevantBinaryFrom1)];
265266
figure(fignumberHMXB), scatter(MBH, MO, point, 'filled', colour, 'DisplayName', name); hold on;
@@ -342,7 +343,8 @@ function DWDplot(file, name, fignumberDWD, colourNMT, colourMT, point)
342343
M2Switch=h5read(file, '/BSE_Switch_Log/Mass(2)');
343344
aSwitch=h5read(file, '/BSE_Switch_Log/SemiMajorAxis');
344345
SeedSwitch=h5read(file, '/BSE_Switch_Log/SEED');
345-
WDIndex=find(Type1>=10 & Type1<=12 & Type2>=10 & Type2<=12);
346+
isMergerSwitch=h5read(file,'/BSE_Switch_Log/Is_Merger');
347+
WDIndex=find(Type1>=10 & Type1<=12 & Type2>=10 & Type2<=12 & ~isMergerSwitch);
346348
ind=unique(SeedSwitch(WDIndex));
347349
[~,ZAMSIndex]=ismember(ind,SeedZAMS);
348350
MAZAMS=(M1ZAMS(ZAMSIndex)+M2ZAMS(ZAMSIndex)).*aZAMS(ZAMSIndex);

src/BaseStar.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,7 +337,7 @@ class BaseStar {
337337

338338
void SetStellarTypePrev(const STELLAR_TYPE p_StellarTypePrev) { m_StellarTypePrev = p_StellarTypePrev; }
339339

340-
bool ShouldEnvelopeBeExpelledByPulsations() const { return false; } // Default is that there is no envelope expulsion by pulsations
340+
virtual bool ShouldEnvelopeBeExpelledByPulsations() const { return false; } // Default is that there is no envelope expulsion by pulsations
341341

342342
virtual void SpinDownIsolatedPulsar(const double p_Stepsize) { } // Default is NO-OP
343343

src/changelog.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1603,7 +1603,8 @@
16031603
// - Changed default values of --enhance-CHE-lifetimes-luminosities and --scale-CHE-mass-loss-with-surface-helium-abundance to true
16041604
// - Added options to set beta and gamma prescription for second stage of 2-stage CE (--common-envelope-second-stage-beta, --common-envelope-second-stage-gamma-prescription)
16051605
// - Fixed a bug in CalculateZetaEquilibrium(), which impacted when mass transfer is declared nuclear (and how conservative it is)
1606-
// - Now calculate mass accretion rate for nuclear timescale mass transfer on the fly to match with donor mass loss rate set by donor mass loss (required to fit into Roche lobe) divided by time step
1606+
// - Added missing virtual declaration to ShouldEnvelopeBeExpelledByPulsations
1607+
// - Now calculate mass accretion rate for nuclear timescale mass transfer on the fly to match with donor mass loss rate set by donor mass loss (required to fit into Roche lobe) divided by time step
16071608

16081609

16091610
const std::string VERSION_STRING = "03.21.00";

0 commit comments

Comments
 (0)