From 34ca7d957bd3fa2dae8f34a8ecbd440c228e788f Mon Sep 17 00:00:00 2001 From: GurrenLagannTSS <54154710+GurrenLagannTSS@users.noreply.github.com> Date: Fri, 5 Feb 2021 17:37:31 -0300 Subject: [PATCH 1/4] Add proper temperatures for WC and WN stars Partially closes #901, adding WNh is a bit of an hassle for me. --- src/celengine/star.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/celengine/star.cpp b/src/celengine/star.cpp index ac4c73f50c..2316a2fb6e 100644 --- a/src/celengine/star.cpp +++ b/src/celengine/star.cpp @@ -105,16 +105,15 @@ static float tempM[3][10] = { 3650, 3550, 3450, 3200, 2980, 2800, 2600, 2600, 2600, 2600 }, }; -// Wolf-Rayet temperatures. From Lang's Astrophysical Data: Planets and -// Stars. +// Wolf-Rayet temperatures. static float tempWN[10] = { - 50000, 50000, 50000, 50000, 47000, 43000, 39000, 32000, 29000, 29000 + 185000, 158000, 140000, 115000, 89000, 75000, 65000, 56000, 50000, 45000 }; static float tempWC[10] = { - 60000, 60000, 60000, 60000, 60000, 60000, 60000, 54000, 46000, 38000 + 225000, 190000, 165000, 140000, 125000, 105000, 83000, 70000, 60000, 50000 }; // These values are based on extrapolation of 6 samples. From ce67173282f9cd125410315f8dcc2b2406eec805 Mon Sep 17 00:00:00 2001 From: GurrenLagannTSS <54154710+GurrenLagannTSS@users.noreply.github.com> Date: Fri, 5 Feb 2021 17:55:07 -0300 Subject: [PATCH 2/4] Update star.cpp --- src/celengine/star.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/celengine/star.cpp b/src/celengine/star.cpp index 2316a2fb6e..2de8319559 100644 --- a/src/celengine/star.cpp +++ b/src/celengine/star.cpp @@ -111,6 +111,7 @@ static float tempWN[10] = 185000, 158000, 140000, 115000, 89000, 75000, 65000, 56000, 50000, 45000 }; +// Note: The temperatures for early and late WCs are mostly for CSPNe. static float tempWC[10] = { 225000, 190000, 165000, 140000, 125000, 105000, 83000, 70000, 60000, 50000 From ff5adc6656d4b8c589ea24e990477b667f7ef199 Mon Sep 17 00:00:00 2001 From: GurrenLagannTSS <54154710+GurrenLagannTSS@users.noreply.github.com> Date: Fri, 5 Feb 2021 18:14:44 -0300 Subject: [PATCH 3/4] Update star.cpp --- src/celengine/star.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/celengine/star.cpp b/src/celengine/star.cpp index 2de8319559..e4666c905b 100644 --- a/src/celengine/star.cpp +++ b/src/celengine/star.cpp @@ -114,7 +114,7 @@ static float tempWN[10] = // Note: The temperatures for early and late WCs are mostly for CSPNe. static float tempWC[10] = { - 225000, 190000, 165000, 140000, 125000, 105000, 83000, 70000, 60000, 50000 + 225000, 190000, 165000, 140000, 125000, 105000, 83000, 70000, 58000, 46000 }; // These values are based on extrapolation of 6 samples. From 084942d6b5b01744c86390139aafc27485856b4f Mon Sep 17 00:00:00 2001 From: GurrenLagannTSS <54154710+GurrenLagannTSS@users.noreply.github.com> Date: Fri, 5 Feb 2021 18:27:37 -0300 Subject: [PATCH 4/4] Added WNh temperatures in a workaround.. --- src/celengine/star.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/celengine/star.cpp b/src/celengine/star.cpp index e4666c905b..f42f26edbd 100644 --- a/src/celengine/star.cpp +++ b/src/celengine/star.cpp @@ -106,9 +106,12 @@ static float tempM[3][10] = }; // Wolf-Rayet temperatures. -static float tempWN[10] = +static float tempWN[3][10] = { - 185000, 158000, 140000, 115000, 89000, 75000, 65000, 56000, 50000, 45000 + { 185000, 158000, 140000, 115000, 89000, 75000, 65000, 56000, 50000, 45000 }, + { 185000, 158000, 140000, 115000, 89000, 75000, 65000, 56000, 50000, 45000 }, + // WNh stars. Currently as a workaround until its split into its own class. + { 133000, 106000, 92000, 72000, 61000, 51000, 42000, 36000, 31000, 27000 }, }; // Note: The temperatures for early and late WCs are mostly for CSPNe. @@ -566,7 +569,7 @@ StarDetails::GetNormalStarDetails(StellarClass::SpectralClass specClass, temp = tempM[lumIndex][subclass]; break; case StellarClass::Spectral_WN: - temp = tempWN[subclass]; + temp = tempWN[lumIndex][subclass]; break; case StellarClass::Spectral_WC: temp = tempWC[subclass];