diff --git a/src/sinus.ts b/src/sinus.ts index 09f984f..1aad6bc 100644 --- a/src/sinus.ts +++ b/src/sinus.ts @@ -14,22 +14,23 @@ function getCurrentHourDecimalInTimezone(timezone) { timeZone: timezone, minute: 'numeric', }); - return parseFloat(hours) + parseFloat(minutes) / 60; + const time = parseFloat(hours) + parseFloat(minutes) / 60; + return { time, hours: parseInt(hours), minutes: parseInt(minutes) }; } export default function (timezone: string) { // time of the day in hours - decimals, not minutes - const hours = getCurrentHourDecimalInTimezone(timezone); - const hours2 = - (Date.now() / 86400000 - Math.floor(Date.now() / 86400000)) * 24 + 2; + const { time, minutes, hours } = getCurrentHourDecimalInTimezone(timezone); logger.debug( 'time of the day in hours - using decimals, not minutes: %o', - hours.toFixed(2), + time.toFixed(2), ); // express minutes also; - const hoursAbs = Math.floor(hours); - const minutes = (hours - hoursAbs) * 60; + // const hoursAbs = Math.floor(hours); + // const minutes = (hours - hoursAbs) * 60; + + logger.debug('express hours: %o', hours.toFixed(), 'minutes'); logger.debug( 'express minutes in minutes also: %o', minutes.toFixed(), @@ -37,11 +38,11 @@ export default function (timezone: string) { ); // time of the day in 2 pi cycle; - const daycycle = (hours * Math.PI) / 12; - logger.debug('time of the day in 2 pi cycle %o', daycycle.toFixed(2)); + const dayCycle = (time * Math.PI) / 12; + logger.debug('time of the day in 2 pi cycle %o', dayCycle.toFixed(2)); // time of the day in 360 deg cycle; - const dayCycleDeg = (hours * 360) / 24; + const dayCycleDeg = (time * 360) / 24; logger.debug('time of the day in 360 deg cycle %o', dayCycleDeg.toFixed(2)); // value of the sin function according to hours, oscillating from -1 to +1; @@ -69,7 +70,7 @@ export default function (timezone: string) { ); logger.debug( 'When the time of day is ' + - hours.toFixed() + + time.toFixed() + ' hours and ' + minutes.toFixed() + ' minutes, the sinusoidal value is: ' + @@ -87,7 +88,7 @@ export default function (timezone: string) { ); logger.debug( 'When the time of day is ' + - hours.toFixed() + + time.toFixed() + ' hours and ' + minutes.toFixed() + ' minutes, the cosinusoidal value is: ' + diff --git a/test/__image_snapshots__/__diff_output__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap-diff.png b/test/__image_snapshots__/__diff_output__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap-diff.png deleted file mode 100644 index be91536..0000000 Binary files a/test/__image_snapshots__/__diff_output__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap-diff.png and /dev/null differ diff --git a/test/__image_snapshots__/__diff_output__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap-diff.png b/test/__image_snapshots__/__diff_output__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap-diff.png deleted file mode 100644 index c95659c..0000000 Binary files a/test/__image_snapshots__/__diff_output__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap-diff.png and /dev/null differ diff --git a/test/__image_snapshots__/__diff_output__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap-diff.png b/test/__image_snapshots__/__diff_output__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap-diff.png deleted file mode 100644 index baad005..0000000 Binary files a/test/__image_snapshots__/__diff_output__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap-diff.png and /dev/null differ diff --git a/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap-diff.png b/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap-diff.png deleted file mode 100644 index cfe8161..0000000 Binary files a/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap-diff.png and /dev/null differ diff --git a/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap-diff.png b/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap-diff.png deleted file mode 100644 index 542e31d..0000000 Binary files a/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap-diff.png and /dev/null differ diff --git a/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap-diff.png b/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap-diff.png deleted file mode 100644 index 64459ab..0000000 Binary files a/test/__image_snapshots__/__diff_output__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap-diff.png and /dev/null differ diff --git a/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap.png b/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap.png index d8d6b82..0b5571d 100644 Binary files a/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap.png and b/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-22-6-h-alc-1-u-1-h-alc-4-u-2-h-3-snap.png differ diff --git a/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap.png b/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap.png index 78c2dc2..8ecd2bf 100644 Binary files a/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap.png and b/test/__image_snapshots__/simulator-alcohol-test-ts-simulator-alcohol-test-start-from-100-12-00-z-with-deg-23-4-h-alc-2-u-1-h-3-snap.png differ diff --git a/test/__image_snapshots__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap.png b/test/__image_snapshots__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap.png index dba3916..c1f4c1b 100644 Binary files a/test/__image_snapshots__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap.png and b/test/__image_snapshots__/simulator-cortisone-test-ts-simulator-cortisone-test-start-from-150-12-00-z-with-deg-22-4-h-cor-40-mg-1-h-bolus-3-u-3-h-2-snap.png differ diff --git a/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap.png b/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap.png index 4de55ac..fdfc387 100644 Binary files a/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap.png and b/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-100-13-00-z-with-deg-23-cor-40-mg-14-00-bolus-5-u-14-30-3-snap.png differ diff --git a/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap.png b/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap.png index bb4888c..b69cd6a 100644 Binary files a/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap.png and b/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-124-15-00-50-g-tou-14-1-snap.png differ diff --git a/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap.png b/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap.png index 04dbc2d..8d26afb 100644 Binary files a/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap.png and b/test/__image_snapshots__/simulator-test-ts-simulator-test-start-from-250-13-00-z-and-tou-14-u-bolus-8-u-14-00-3-snap.png differ diff --git a/test/__snapshots__/simulator.test.ts.snap b/test/__snapshots__/simulator.test.ts.snap index 400bbd5..19fdb22 100644 --- a/test/__snapshots__/simulator.test.ts.snap +++ b/test/__snapshots__/simulator.test.ts.snap @@ -2,11 +2,6 @@ exports[`simulator test start from 100 @13:00Z with deg23 + cor 40mg @14:00 + bolus 5u @14.30 1`] = ` Array [ - 113, - 113, - 113, - 113, - 113, 115, 115, 115, @@ -102,16 +97,31 @@ Array [ 151, 151, 151, - 152, - 152, - 152, - 152, - 152, - 152, - 152, - 152, - 152, - 152, + 153, + 153, + 153, + 153, + 153, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 154, + 153, + 153, + 153, + 153, + 153, 152, 152, 152, @@ -122,11 +132,6 @@ Array [ 151, 151, 151, - 150, - 150, - 150, - 150, - 150, 149, 149, 149, @@ -167,11 +172,16 @@ Array [ 135, 135, 135, - 132, - 132, - 132, - 132, - 132, + 133, + 133, + 133, + 133, + 133, + 131, + 131, + 131, + 131, + 131, 129, 129, 129, @@ -222,16 +232,31 @@ Array [ 111, 111, 111, + 110, + 110, + 110, + 110, + 110, 109, 109, 109, 109, 109, + 108, + 108, + 108, + 108, + 108, 107, 107, 107, 107, 107, + 106, + 106, + 106, + 106, + 106, 105, 105, 105, @@ -252,101 +277,56 @@ Array [ 102, 102, 102, - 101, - 101, - 101, - 101, - 101, - 100, - 100, - 100, - 100, - 100, - 99, - 99, - 99, - 99, - 99, - 98, - 98, - 98, - 98, - 98, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 97, - 98, - 98, - 98, - 98, - 98, - 99, - 99, - 99, - 99, - 99, - 100, - 100, - 100, - 100, - 100, - 101, - 101, - 101, - 101, - 101, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, + 102, 102, 102, 102, @@ -397,11 +377,21 @@ Array [ 111, 111, 111, + 112, + 112, + 112, + 112, + 112, 113, 113, 113, 113, 113, + 114, + 114, + 114, + 114, + 114, 115, 115, 115, @@ -477,256 +467,511 @@ Array [ 143, 143, 143, + 144, + 144, + 144, + 144, + 144, 145, 145, 145, 145, 145, + 146, + 146, + 146, + 146, + 146, 147, 147, 147, 147, 147, + 148, + 148, + 148, + 148, + 148, 149, 149, 149, 149, 149, + 150, + 150, + 150, + 150, + 150, 151, 151, 151, 151, 151, + 152, + 152, + 152, + 152, + 152, 153, 153, 153, 153, 153, + 154, + 154, + 154, + 154, + 154, 155, 155, 155, 155, 155, + 156, + 156, + 156, + 156, + 156, 157, 157, 157, 157, 157, + 158, + 158, + 158, + 158, + 158, 159, 159, 159, 159, 159, + 160, + 160, + 160, + 160, + 160, 161, 161, 161, 161, 161, + 162, + 162, + 162, + 162, + 162, 163, 163, 163, 163, 163, + 164, + 164, + 164, + 164, + 164, 165, 165, 165, 165, 165, + 166, + 166, + 166, + 166, + 166, 167, 167, 167, 167, 167, + 168, + 168, + 168, + 168, + 168, 169, 169, 169, 169, 169, + 170, + 170, + 170, + 170, + 170, 171, 171, 171, 171, 171, + 172, + 172, + 172, + 172, + 172, 173, 173, 173, 173, 173, + 174, + 174, + 174, + 174, + 174, 175, 175, 175, 175, 175, + 176, + 176, + 176, + 176, + 176, 177, 177, 177, 177, 177, + 178, + 178, + 178, + 178, + 178, 179, 179, 179, 179, 179, + 180, + 180, + 180, + 180, + 180, 181, 181, 181, 181, 181, + 182, + 182, + 182, + 182, + 182, 183, 183, 183, 183, 183, + 184, + 184, + 184, + 184, + 184, 185, 185, 185, 185, 185, + 186, + 186, + 186, + 186, + 186, 187, 187, 187, 187, 187, + 188, + 188, + 188, + 188, + 188, 189, 189, 189, 189, 189, + 190, + 190, + 190, + 190, + 190, 191, 191, 191, 191, 191, + 192, + 192, + 192, + 192, + 192, 193, 193, 193, 193, 193, + 194, + 194, + 194, + 194, + 194, 195, 195, 195, 195, 195, + 196, + 196, + 196, + 196, + 196, 197, 197, 197, 197, 197, + 198, + 198, + 198, + 198, + 198, 199, 199, 199, 199, 199, + 200, + 200, + 200, + 200, + 200, 201, 201, 201, 201, 201, + 202, + 202, + 202, + 202, + 202, 203, 203, 203, 203, 203, + 204, + 204, + 204, + 204, + 204, 205, 205, 205, 205, 205, + 206, + 206, + 206, + 206, + 206, 207, 207, 207, 207, 207, + 208, + 208, + 208, + 208, + 208, 209, 209, 209, 209, 209, + 210, + 210, + 210, + 210, + 210, 211, 211, 211, 211, 211, + 212, + 212, + 212, + 212, + 212, 213, 213, 213, 213, 213, + 214, + 214, + 214, + 214, + 214, 215, 215, 215, 215, 215, + 216, + 216, + 216, + 216, + 216, 217, 217, 217, 217, 217, + 218, + 218, + 218, + 218, + 218, 219, 219, 219, 219, 219, + 220, + 220, + 220, + 220, + 220, 221, 221, 221, 221, 221, + 222, + 222, + 222, + 222, + 222, 223, 223, 223, 223, 223, + 224, + 224, + 224, + 224, + 224, 225, 225, 225, 225, 225, + 226, + 226, + 226, + 226, + 226, 227, 227, 227, 227, 227, + 228, + 228, + 228, + 228, + 228, 229, 229, 229, 229, 229, + 230, + 230, + 230, + 230, + 230, 231, 231, 231, 231, 231, + 232, + 232, + 232, + 232, + 232, 233, 233, 233, 233, 233, + 234, + 234, + 234, + 234, + 234, 235, 235, 235, 235, 235, + 236, + 236, + 236, + 236, + 236, 237, 237, 237, 237, 237, + 238, + 238, + 238, + 238, + 238, 239, 239, 239, 239, 239, + 240, + 240, + 240, + 240, + 240, 241, 241, 241, 241, 241, + 242, + 242, + 242, + 242, + 242, 243, 243, 243, 243, 243, + 244, + 244, + 244, + 244, + 244, 245, 245, 245, @@ -1032,416 +1277,171 @@ Array [ 305, 305, 305, - 306, - 306, - 306, - 306, - 306, - 307, - 307, - 307, - 307, - 307, - 308, - 308, - 308, - 308, - 308, - 309, - 309, - 309, - 309, - 309, - 310, - 310, - 310, - 310, - 310, - 311, - 311, - 311, - 311, - 311, - 312, - 312, - 312, - 312, - 312, - 313, - 313, - 313, - 313, - 313, - 314, - 314, - 314, - 314, - 314, - 315, - 315, - 315, - 315, - 315, - 316, - 316, - 316, - 316, - 316, - 317, - 317, - 317, - 317, - 317, - 318, - 318, - 318, - 318, - 318, - 319, - 319, - 319, - 319, - 319, - 320, - 320, - 320, - 320, - 320, - 321, - 321, - 321, - 321, - 321, - 322, - 322, - 322, - 322, - 322, - 323, - 323, - 323, - 323, - 323, - 324, - 324, - 324, - 324, - 324, - 325, - 325, - 325, - 325, - 325, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 326, - 325, - 325, - 325, - 325, - 325, - 324, - 324, - 324, - 324, - 324, - 323, - 323, - 323, - 323, - 323, - 322, - 322, - 322, - 322, - 322, - 321, - 321, - 321, - 321, - 321, - 320, - 320, - 320, - 320, - 320, - 319, - 319, - 319, - 319, - 319, - 318, - 318, - 318, - 318, - 318, - 317, - 317, - 317, - 317, - 317, - 316, - 316, - 316, - 316, - 316, - 315, - 315, - 315, - 315, - 315, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 305, + 304, + 304, + 304, + 304, + 304, ] `; @@ -1451,21 +1451,20 @@ exports[`simulator test start from 250 13:00Z and tou 14u + bolus 8U @14:00 1`] Array [ 251, 252, - 253, - 254, - 255, - 255, - 255, - 255, - 255, - 255, - 255, - 255, - 255, - 255, - 254, 252, - 250, + 252, + 252, + 252, + 252, + 252, + 252, + 252, + 252, + 252, + 252, + 252, + 251, + 249, 247, 244, 241, @@ -1474,13 +1473,13 @@ Array [ 229, 225, 221, - 216, - 211, - 206, - 201, - 196, - 191, - 186, + 217, + 212, + 207, + 202, + 197, + 192, + 187, 182, 178, 174, @@ -1491,16 +1490,17 @@ Array [ 154, 150, 146, - 143, - 140, - 137, - 134, - 131, - 128, + 142, + 139, + 136, + 133, + 130, + 127, + 124, ] `; -exports[`simulator test start from 250 13:00Z and tou 14u + bolus 8U @14:00 2`] = `128`; +exports[`simulator test start from 250 13:00Z and tou 14u + bolus 8U @14:00 2`] = `124`; exports[`simulator test start from 274 22:10 + 14u tou + 1`] = ` Array [ @@ -1522,343 +1522,343 @@ Array [ "Result 304 2022-05-29T23:20:00.000Z", "Result 306 2022-05-29T23:25:00.000Z", "Result 308 2022-05-29T23:30:00.000Z", - "Result 310 2022-05-29T23:35:00.000Z", - "Result 312 2022-05-29T23:40:00.000Z", - "Result 314 2022-05-29T23:45:00.000Z", - "Result 316 2022-05-29T23:50:00.000Z", - "Result 318 2022-05-29T23:55:00.000Z", - "Result 320 2022-05-30T00:00:00.000Z", - "Result 322 2022-05-30T00:05:00.000Z", - "Result 324 2022-05-30T00:10:00.000Z", - "Result 326 2022-05-30T00:15:00.000Z", - "Result 328 2022-05-30T00:20:00.000Z", - "Result 330 2022-05-30T00:25:00.000Z", - "Result 332 2022-05-30T00:30:00.000Z", - "Result 334 2022-05-30T00:35:00.000Z", - "Result 336 2022-05-30T00:40:00.000Z", - "Result 337 2022-05-30T00:45:00.000Z", - "Result 338 2022-05-30T00:50:00.000Z", - "Result 339 2022-05-30T00:55:00.000Z", - "Result 340 2022-05-30T01:00:00.000Z", - "Result 341 2022-05-30T01:05:00.000Z", - "Result 342 2022-05-30T01:10:00.000Z", - "Result 343 2022-05-30T01:15:00.000Z", - "Result 344 2022-05-30T01:20:00.000Z", - "Result 345 2022-05-30T01:25:00.000Z", - "Result 346 2022-05-30T01:30:00.000Z", - "Result 347 2022-05-30T01:35:00.000Z", - "Result 348 2022-05-30T01:40:00.000Z", - "Result 349 2022-05-30T01:45:00.000Z", - "Result 350 2022-05-30T01:50:00.000Z", - "Result 351 2022-05-30T01:55:00.000Z", - "Result 352 2022-05-30T02:00:00.000Z", - "Result 353 2022-05-30T02:05:00.000Z", - "Result 354 2022-05-30T02:10:00.000Z", - "Result 355 2022-05-30T02:15:00.000Z", - "Result 356 2022-05-30T02:20:00.000Z", - "Result 357 2022-05-30T02:25:00.000Z", - "Result 358 2022-05-30T02:30:00.000Z", - "Result 359 2022-05-30T02:35:00.000Z", - "Result 360 2022-05-30T02:40:00.000Z", - "Result 361 2022-05-30T02:45:00.000Z", - "Result 362 2022-05-30T02:50:00.000Z", - "Result 363 2022-05-30T02:55:00.000Z", - "Result 364 2022-05-30T03:00:00.000Z", - "Result 365 2022-05-30T03:05:00.000Z", - "Result 366 2022-05-30T03:10:00.000Z", - "Result 367 2022-05-30T03:15:00.000Z", - "Result 368 2022-05-30T03:20:00.000Z", - "Result 369 2022-05-30T03:25:00.000Z", - "Result 370 2022-05-30T03:30:00.000Z", - "Result 371 2022-05-30T03:35:00.000Z", - "Result 372 2022-05-30T03:40:00.000Z", - "Result 373 2022-05-30T03:45:00.000Z", - "Result 374 2022-05-30T03:50:00.000Z", - "Result 375 2022-05-30T03:55:00.000Z", - "Result 376 2022-05-30T04:00:00.000Z", - "Result 377 2022-05-30T04:05:00.000Z", - "Result 378 2022-05-30T04:10:00.000Z", - "Result 379 2022-05-30T04:15:00.000Z", - "Result 380 2022-05-30T04:20:00.000Z", - "Result 381 2022-05-30T04:25:00.000Z", - "Result 382 2022-05-30T04:30:00.000Z", - "Result 383 2022-05-30T04:35:00.000Z", - "Result 384 2022-05-30T04:40:00.000Z", - "Result 385 2022-05-30T04:45:00.000Z", - "Result 386 2022-05-30T04:50:00.000Z", - "Result 387 2022-05-30T04:55:00.000Z", - "Result 388 2022-05-30T05:00:00.000Z", - "Result 389 2022-05-30T05:05:00.000Z", - "Result 390 2022-05-30T05:10:00.000Z", - "Result 391 2022-05-30T05:15:00.000Z", - "Result 392 2022-05-30T05:20:00.000Z", - "Result 393 2022-05-30T05:25:00.000Z", - "Result 394 2022-05-30T05:30:00.000Z", - "Result 395 2022-05-30T05:35:00.000Z", + "Result 309 2022-05-29T23:35:00.000Z", + "Result 310 2022-05-29T23:40:00.000Z", + "Result 311 2022-05-29T23:45:00.000Z", + "Result 312 2022-05-29T23:50:00.000Z", + "Result 313 2022-05-29T23:55:00.000Z", + "Result 314 2022-05-30T00:00:00.000Z", + "Result 315 2022-05-30T00:05:00.000Z", + "Result 316 2022-05-30T00:10:00.000Z", + "Result 317 2022-05-30T00:15:00.000Z", + "Result 318 2022-05-30T00:20:00.000Z", + "Result 319 2022-05-30T00:25:00.000Z", + "Result 320 2022-05-30T00:30:00.000Z", + "Result 321 2022-05-30T00:35:00.000Z", + "Result 322 2022-05-30T00:40:00.000Z", + "Result 323 2022-05-30T00:45:00.000Z", + "Result 324 2022-05-30T00:50:00.000Z", + "Result 325 2022-05-30T00:55:00.000Z", + "Result 326 2022-05-30T01:00:00.000Z", + "Result 327 2022-05-30T01:05:00.000Z", + "Result 328 2022-05-30T01:10:00.000Z", + "Result 329 2022-05-30T01:15:00.000Z", + "Result 330 2022-05-30T01:20:00.000Z", + "Result 331 2022-05-30T01:25:00.000Z", + "Result 332 2022-05-30T01:30:00.000Z", + "Result 333 2022-05-30T01:35:00.000Z", + "Result 334 2022-05-30T01:40:00.000Z", + "Result 335 2022-05-30T01:45:00.000Z", + "Result 336 2022-05-30T01:50:00.000Z", + "Result 337 2022-05-30T01:55:00.000Z", + "Result 338 2022-05-30T02:00:00.000Z", + "Result 339 2022-05-30T02:05:00.000Z", + "Result 340 2022-05-30T02:10:00.000Z", + "Result 341 2022-05-30T02:15:00.000Z", + "Result 342 2022-05-30T02:20:00.000Z", + "Result 343 2022-05-30T02:25:00.000Z", + "Result 344 2022-05-30T02:30:00.000Z", + "Result 345 2022-05-30T02:35:00.000Z", + "Result 346 2022-05-30T02:40:00.000Z", + "Result 347 2022-05-30T02:45:00.000Z", + "Result 348 2022-05-30T02:50:00.000Z", + "Result 349 2022-05-30T02:55:00.000Z", + "Result 350 2022-05-30T03:00:00.000Z", + "Result 351 2022-05-30T03:05:00.000Z", + "Result 352 2022-05-30T03:10:00.000Z", + "Result 353 2022-05-30T03:15:00.000Z", + "Result 354 2022-05-30T03:20:00.000Z", + "Result 355 2022-05-30T03:25:00.000Z", + "Result 356 2022-05-30T03:30:00.000Z", + "Result 357 2022-05-30T03:35:00.000Z", + "Result 358 2022-05-30T03:40:00.000Z", + "Result 359 2022-05-30T03:45:00.000Z", + "Result 360 2022-05-30T03:50:00.000Z", + "Result 361 2022-05-30T03:55:00.000Z", + "Result 362 2022-05-30T04:00:00.000Z", + "Result 363 2022-05-30T04:05:00.000Z", + "Result 364 2022-05-30T04:10:00.000Z", + "Result 365 2022-05-30T04:15:00.000Z", + "Result 366 2022-05-30T04:20:00.000Z", + "Result 367 2022-05-30T04:25:00.000Z", + "Result 368 2022-05-30T04:30:00.000Z", + "Result 369 2022-05-30T04:35:00.000Z", + "Result 370 2022-05-30T04:40:00.000Z", + "Result 371 2022-05-30T04:45:00.000Z", + "Result 372 2022-05-30T04:50:00.000Z", + "Result 373 2022-05-30T04:55:00.000Z", + "Result 374 2022-05-30T05:00:00.000Z", + "Result 375 2022-05-30T05:05:00.000Z", + "Result 376 2022-05-30T05:10:00.000Z", + "Result 377 2022-05-30T05:15:00.000Z", + "Result 378 2022-05-30T05:20:00.000Z", + "Result 379 2022-05-30T05:25:00.000Z", + "Result 380 2022-05-30T05:30:00.000Z", + "Result 381 2022-05-30T05:35:00.000Z", "Bolus 6U 2022-05-30T05:40:00.000Z", - "Result 396 2022-05-30T05:40:00.000Z", - "Result 396 2022-05-30T05:45:00.000Z", - "Result 395 2022-05-30T05:50:00.000Z", - "Result 393 2022-05-30T05:55:00.000Z", - "Result 391 2022-05-30T06:00:00.000Z", - "Result 388 2022-05-30T06:05:00.000Z", - "Result 385 2022-05-30T06:10:00.000Z", - "Result 381 2022-05-30T06:15:00.000Z", - "Result 377 2022-05-30T06:20:00.000Z", - "Result 373 2022-05-30T06:25:00.000Z", - "Result 368 2022-05-30T06:30:00.000Z", - "Result 363 2022-05-30T06:35:00.000Z", - "Result 358 2022-05-30T06:40:00.000Z", - "Result 353 2022-05-30T06:45:00.000Z", - "Result 348 2022-05-30T06:50:00.000Z", - "Result 343 2022-05-30T06:55:00.000Z", - "Result 338 2022-05-30T07:00:00.000Z", - "Result 333 2022-05-30T07:05:00.000Z", - "Result 328 2022-05-30T07:10:00.000Z", - "Result 323 2022-05-30T07:15:00.000Z", - "Result 318 2022-05-30T07:20:00.000Z", - "Result 313 2022-05-30T07:25:00.000Z", - "Result 308 2022-05-30T07:30:00.000Z", - "Result 303 2022-05-30T07:35:00.000Z", - "Result 299 2022-05-30T07:40:00.000Z", - "Result 295 2022-05-30T07:45:00.000Z", - "Result 291 2022-05-30T07:50:00.000Z", - "Result 287 2022-05-30T07:55:00.000Z", - "Result 283 2022-05-30T08:00:00.000Z", - "Result 279 2022-05-30T08:05:00.000Z", - "Result 275 2022-05-30T08:10:00.000Z", - "Result 272 2022-05-30T08:15:00.000Z", - "Result 269 2022-05-30T08:20:00.000Z", - "Result 266 2022-05-30T08:25:00.000Z", - "Result 263 2022-05-30T08:30:00.000Z", - "Result 260 2022-05-30T08:35:00.000Z", - "Result 257 2022-05-30T08:40:00.000Z", - "Result 254 2022-05-30T08:45:00.000Z", - "Result 251 2022-05-30T08:50:00.000Z", - "Result 249 2022-05-30T08:55:00.000Z", - "Result 247 2022-05-30T09:00:00.000Z", - "Result 245 2022-05-30T09:05:00.000Z", - "Result 243 2022-05-30T09:10:00.000Z", - "Result 241 2022-05-30T09:15:00.000Z", - "Result 239 2022-05-30T09:20:00.000Z", - "Result 237 2022-05-30T09:25:00.000Z", - "Result 235 2022-05-30T09:30:00.000Z", - "Result 233 2022-05-30T09:35:00.000Z", - "Result 232 2022-05-30T09:40:00.000Z", - "Result 231 2022-05-30T09:45:00.000Z", - "Result 230 2022-05-30T09:50:00.000Z", - "Result 229 2022-05-30T09:55:00.000Z", - "Result 228 2022-05-30T10:00:00.000Z", - "Result 227 2022-05-30T10:05:00.000Z", - "Result 226 2022-05-30T10:10:00.000Z", - "Result 225 2022-05-30T10:15:00.000Z", - "Result 224 2022-05-30T10:20:00.000Z", - "Result 223 2022-05-30T10:25:00.000Z", - "Result 222 2022-05-30T10:30:00.000Z", - "Result 221 2022-05-30T10:35:00.000Z", - "Result 220 2022-05-30T10:40:00.000Z", - "Result 220 2022-05-30T10:45:00.000Z", - "Result 220 2022-05-30T10:50:00.000Z", - "Result 220 2022-05-30T10:55:00.000Z", - "Result 220 2022-05-30T11:00:00.000Z", - "Result 220 2022-05-30T11:05:00.000Z", - "Result 220 2022-05-30T11:10:00.000Z", - "Result 220 2022-05-30T11:15:00.000Z", - "Result 220 2022-05-30T11:20:00.000Z", - "Result 220 2022-05-30T11:25:00.000Z", - "Result 220 2022-05-30T11:30:00.000Z", - "Result 220 2022-05-30T11:35:00.000Z", - "Result 220 2022-05-30T11:40:00.000Z", - "Result 220 2022-05-30T11:45:00.000Z", - "Result 220 2022-05-30T11:50:00.000Z", - "Result 220 2022-05-30T11:55:00.000Z", - "Result 220 2022-05-30T12:00:00.000Z", - "Result 220 2022-05-30T12:05:00.000Z", - "Result 220 2022-05-30T12:10:00.000Z", - "Result 220 2022-05-30T12:15:00.000Z", - "Result 220 2022-05-30T12:20:00.000Z", - "Result 220 2022-05-30T12:25:00.000Z", - "Result 220 2022-05-30T12:30:00.000Z", - "Result 220 2022-05-30T12:35:00.000Z", - "Result 220 2022-05-30T12:40:00.000Z", - "Result 220 2022-05-30T12:45:00.000Z", - "Result 220 2022-05-30T12:50:00.000Z", - "Result 220 2022-05-30T12:55:00.000Z", - "Result 220 2022-05-30T13:00:00.000Z", - "Result 220 2022-05-30T13:05:00.000Z", - "Result 220 2022-05-30T13:10:00.000Z", - "Result 220 2022-05-30T13:15:00.000Z", - "Result 220 2022-05-30T13:20:00.000Z", - "Result 220 2022-05-30T13:25:00.000Z", - "Result 220 2022-05-30T13:30:00.000Z", - "Result 220 2022-05-30T13:35:00.000Z", - "Result 220 2022-05-30T13:40:00.000Z", - "Result 220 2022-05-30T13:45:00.000Z", - "Result 220 2022-05-30T13:50:00.000Z", - "Result 220 2022-05-30T13:55:00.000Z", - "Result 220 2022-05-30T14:00:00.000Z", - "Result 220 2022-05-30T14:05:00.000Z", - "Result 220 2022-05-30T14:10:00.000Z", - "Result 220 2022-05-30T14:15:00.000Z", - "Result 220 2022-05-30T14:20:00.000Z", - "Result 220 2022-05-30T14:25:00.000Z", - "Result 220 2022-05-30T14:30:00.000Z", - "Result 220 2022-05-30T14:35:00.000Z", - "Result 220 2022-05-30T14:40:00.000Z", - "Result 220 2022-05-30T14:45:00.000Z", - "Result 220 2022-05-30T14:50:00.000Z", - "Result 220 2022-05-30T14:55:00.000Z", - "Result 220 2022-05-30T15:00:00.000Z", - "Result 220 2022-05-30T15:05:00.000Z", - "Result 220 2022-05-30T15:10:00.000Z", - "Result 220 2022-05-30T15:15:00.000Z", - "Result 220 2022-05-30T15:20:00.000Z", - "Result 220 2022-05-30T15:25:00.000Z", - "Result 220 2022-05-30T15:30:00.000Z", - "Result 220 2022-05-30T15:35:00.000Z", - "Result 220 2022-05-30T15:40:00.000Z", - "Result 220 2022-05-30T15:45:00.000Z", - "Result 220 2022-05-30T15:50:00.000Z", - "Result 220 2022-05-30T15:55:00.000Z", - "Result 220 2022-05-30T16:00:00.000Z", - "Result 220 2022-05-30T16:05:00.000Z", - "Result 220 2022-05-30T16:10:00.000Z", - "Result 220 2022-05-30T16:15:00.000Z", - "Result 220 2022-05-30T16:20:00.000Z", - "Result 220 2022-05-30T16:25:00.000Z", - "Result 220 2022-05-30T16:30:00.000Z", - "Result 220 2022-05-30T16:35:00.000Z", - "Result 220 2022-05-30T16:40:00.000Z", - "Result 220 2022-05-30T16:45:00.000Z", - "Result 220 2022-05-30T16:50:00.000Z", - "Result 220 2022-05-30T16:55:00.000Z", - "Result 220 2022-05-30T17:00:00.000Z", - "Result 220 2022-05-30T17:05:00.000Z", - "Result 220 2022-05-30T17:10:00.000Z", - "Result 220 2022-05-30T17:15:00.000Z", - "Result 220 2022-05-30T17:20:00.000Z", - "Result 220 2022-05-30T17:25:00.000Z", - "Result 220 2022-05-30T17:30:00.000Z", - "Result 220 2022-05-30T17:35:00.000Z", - "Result 220 2022-05-30T17:40:00.000Z", - "Result 220 2022-05-30T17:45:00.000Z", - "Result 220 2022-05-30T17:50:00.000Z", - "Result 220 2022-05-30T17:55:00.000Z", - "Result 220 2022-05-30T18:00:00.000Z", - "Result 220 2022-05-30T18:05:00.000Z", - "Result 220 2022-05-30T18:10:00.000Z", - "Result 220 2022-05-30T18:15:00.000Z", - "Result 221 2022-05-30T18:20:00.000Z", - "Result 222 2022-05-30T18:25:00.000Z", - "Result 223 2022-05-30T18:30:00.000Z", - "Result 224 2022-05-30T18:35:00.000Z", - "Result 225 2022-05-30T18:40:00.000Z", - "Result 226 2022-05-30T18:45:00.000Z", - "Result 227 2022-05-30T18:50:00.000Z", - "Result 228 2022-05-30T18:55:00.000Z", - "Result 229 2022-05-30T19:00:00.000Z", - "Result 230 2022-05-30T19:05:00.000Z", - "Result 231 2022-05-30T19:10:00.000Z", - "Result 232 2022-05-30T19:15:00.000Z", - "Result 233 2022-05-30T19:20:00.000Z", - "Result 234 2022-05-30T19:25:00.000Z", - "Result 235 2022-05-30T19:30:00.000Z", - "Result 236 2022-05-30T19:35:00.000Z", - "Result 237 2022-05-30T19:40:00.000Z", - "Result 238 2022-05-30T19:45:00.000Z", - "Result 239 2022-05-30T19:50:00.000Z", - "Result 240 2022-05-30T19:55:00.000Z", - "Result 241 2022-05-30T20:00:00.000Z", - "Result 242 2022-05-30T20:05:00.000Z", - "Result 243 2022-05-30T20:10:00.000Z", - "Result 244 2022-05-30T20:15:00.000Z", - "Result 245 2022-05-30T20:20:00.000Z", - "Result 246 2022-05-30T20:25:00.000Z", - "Result 247 2022-05-30T20:30:00.000Z", - "Result 248 2022-05-30T20:35:00.000Z", - "Result 249 2022-05-30T20:40:00.000Z", - "Result 250 2022-05-30T20:45:00.000Z", - "Result 251 2022-05-30T20:50:00.000Z", - "Result 252 2022-05-30T20:55:00.000Z", - "Result 253 2022-05-30T21:00:00.000Z", - "Result 254 2022-05-30T21:05:00.000Z", - "Result 255 2022-05-30T21:10:00.000Z", - "Result 256 2022-05-30T21:15:00.000Z", - "Result 257 2022-05-30T21:20:00.000Z", - "Result 258 2022-05-30T21:25:00.000Z", - "Result 259 2022-05-30T21:30:00.000Z", - "Result 260 2022-05-30T21:35:00.000Z", - "Result 262 2022-05-30T21:40:00.000Z", - "Result 264 2022-05-30T21:45:00.000Z", - "Result 266 2022-05-30T21:50:00.000Z", - "Result 268 2022-05-30T21:55:00.000Z", - "Result 270 2022-05-30T22:00:00.000Z", - "Result 272 2022-05-30T22:05:00.000Z", - "Result 274 2022-05-30T22:10:00.000Z", - "Result 276 2022-05-30T22:15:00.000Z", - "Result 278 2022-05-30T22:20:00.000Z", - "Result 280 2022-05-30T22:25:00.000Z", - "Result 282 2022-05-30T22:30:00.000Z", - "Result 284 2022-05-30T22:35:00.000Z", - "Result 286 2022-05-30T22:40:00.000Z", - "Result 288 2022-05-30T22:45:00.000Z", - "Result 290 2022-05-30T22:50:00.000Z", - "Result 292 2022-05-30T22:55:00.000Z", - "Result 294 2022-05-30T23:00:00.000Z", - "Result 296 2022-05-30T23:05:00.000Z", - "Result 298 2022-05-30T23:10:00.000Z", - "Result 300 2022-05-30T23:15:00.000Z", - "Result 302 2022-05-30T23:20:00.000Z", - "Result 304 2022-05-30T23:25:00.000Z", - "Result 306 2022-05-30T23:30:00.000Z", - "Result 308 2022-05-30T23:35:00.000Z", - "Result 310 2022-05-30T23:40:00.000Z", - "Result 312 2022-05-30T23:45:00.000Z", - "Result 314 2022-05-30T23:50:00.000Z", - "Result 316 2022-05-30T23:55:00.000Z", - "Result 318 2022-05-31T00:00:00.000Z", - "Result 320 2022-05-31T00:05:00.000Z", - "Result 322 2022-05-31T00:10:00.000Z", - "Result 324 2022-05-31T00:15:00.000Z", - "Result 326 2022-05-31T00:20:00.000Z", - "Result 328 2022-05-31T00:25:00.000Z", - "Result 330 2022-05-31T00:30:00.000Z", - "Result 332 2022-05-31T00:35:00.000Z", - "Result 335 2022-05-31T00:40:00.000Z", - "Result 338 2022-05-31T00:45:00.000Z", - "Result 341 2022-05-31T00:50:00.000Z", - "Result 344 2022-05-31T00:55:00.000Z", - "Result 347 2022-05-31T01:00:00.000Z", - "Result 350 2022-05-31T01:05:00.000Z", - "Result 353 2022-05-31T01:10:00.000Z", - "Result 356 2022-05-31T01:15:00.000Z", - "Result 359 2022-05-31T01:20:00.000Z", - "Result 362 2022-05-31T01:25:00.000Z", - "Result 365 2022-05-31T01:30:00.000Z", - "Result 368 2022-05-31T01:35:00.000Z", - "Result 371 2022-05-31T01:40:00.000Z", - "Result 374 2022-05-31T01:45:00.000Z", - "Result 377 2022-05-31T01:50:00.000Z", - "Result 380 2022-05-31T01:55:00.000Z", - "Result 383 2022-05-31T02:00:00.000Z", - "Result 386 2022-05-31T02:05:00.000Z", - "Result 389 2022-05-31T02:10:00.000Z", - "Result 392 2022-05-31T02:15:00.000Z", - "Result 395 2022-05-31T02:20:00.000Z", - "Result 398 2022-05-31T02:25:00.000Z", - "Result 400 2022-05-31T02:30:00.000Z", - "Result 400 2022-05-31T02:35:00.000Z", - "Result 400 2022-05-31T02:40:00.000Z", - "Result 400 2022-05-31T02:45:00.000Z", - "Result 400 2022-05-31T02:50:00.000Z", - "Result 400 2022-05-31T02:55:00.000Z", - "Result 400 2022-05-31T03:00:00.000Z", - "Result 400 2022-05-31T03:05:00.000Z", - "Result 400 2022-05-31T03:10:00.000Z", - "Result 400 2022-05-31T03:15:00.000Z", - "Result 400 2022-05-31T03:20:00.000Z", - "Result 400 2022-05-31T03:25:00.000Z", - "Result 400 2022-05-31T03:30:00.000Z", + "Result 382 2022-05-30T05:40:00.000Z", + "Result 382 2022-05-30T05:45:00.000Z", + "Result 382 2022-05-30T05:50:00.000Z", + "Result 380 2022-05-30T05:55:00.000Z", + "Result 378 2022-05-30T06:00:00.000Z", + "Result 375 2022-05-30T06:05:00.000Z", + "Result 372 2022-05-30T06:10:00.000Z", + "Result 368 2022-05-30T06:15:00.000Z", + "Result 364 2022-05-30T06:20:00.000Z", + "Result 360 2022-05-30T06:25:00.000Z", + "Result 356 2022-05-30T06:30:00.000Z", + "Result 351 2022-05-30T06:35:00.000Z", + "Result 346 2022-05-30T06:40:00.000Z", + "Result 341 2022-05-30T06:45:00.000Z", + "Result 336 2022-05-30T06:50:00.000Z", + "Result 331 2022-05-30T06:55:00.000Z", + "Result 326 2022-05-30T07:00:00.000Z", + "Result 321 2022-05-30T07:05:00.000Z", + "Result 316 2022-05-30T07:10:00.000Z", + "Result 311 2022-05-30T07:15:00.000Z", + "Result 306 2022-05-30T07:20:00.000Z", + "Result 301 2022-05-30T07:25:00.000Z", + "Result 296 2022-05-30T07:30:00.000Z", + "Result 292 2022-05-30T07:35:00.000Z", + "Result 288 2022-05-30T07:40:00.000Z", + "Result 284 2022-05-30T07:45:00.000Z", + "Result 280 2022-05-30T07:50:00.000Z", + "Result 276 2022-05-30T07:55:00.000Z", + "Result 272 2022-05-30T08:00:00.000Z", + "Result 268 2022-05-30T08:05:00.000Z", + "Result 265 2022-05-30T08:10:00.000Z", + "Result 262 2022-05-30T08:15:00.000Z", + "Result 259 2022-05-30T08:20:00.000Z", + "Result 256 2022-05-30T08:25:00.000Z", + "Result 253 2022-05-30T08:30:00.000Z", + "Result 250 2022-05-30T08:35:00.000Z", + "Result 247 2022-05-30T08:40:00.000Z", + "Result 245 2022-05-30T08:45:00.000Z", + "Result 243 2022-05-30T08:50:00.000Z", + "Result 241 2022-05-30T08:55:00.000Z", + "Result 239 2022-05-30T09:00:00.000Z", + "Result 237 2022-05-30T09:05:00.000Z", + "Result 235 2022-05-30T09:10:00.000Z", + "Result 233 2022-05-30T09:15:00.000Z", + "Result 231 2022-05-30T09:20:00.000Z", + "Result 230 2022-05-30T09:25:00.000Z", + "Result 229 2022-05-30T09:30:00.000Z", + "Result 228 2022-05-30T09:35:00.000Z", + "Result 227 2022-05-30T09:40:00.000Z", + "Result 226 2022-05-30T09:45:00.000Z", + "Result 225 2022-05-30T09:50:00.000Z", + "Result 224 2022-05-30T09:55:00.000Z", + "Result 223 2022-05-30T10:00:00.000Z", + "Result 222 2022-05-30T10:05:00.000Z", + "Result 221 2022-05-30T10:10:00.000Z", + "Result 220 2022-05-30T10:15:00.000Z", + "Result 219 2022-05-30T10:20:00.000Z", + "Result 219 2022-05-30T10:25:00.000Z", + "Result 219 2022-05-30T10:30:00.000Z", + "Result 219 2022-05-30T10:35:00.000Z", + "Result 219 2022-05-30T10:40:00.000Z", + "Result 219 2022-05-30T10:45:00.000Z", + "Result 219 2022-05-30T10:50:00.000Z", + "Result 219 2022-05-30T10:55:00.000Z", + "Result 219 2022-05-30T11:00:00.000Z", + "Result 219 2022-05-30T11:05:00.000Z", + "Result 219 2022-05-30T11:10:00.000Z", + "Result 219 2022-05-30T11:15:00.000Z", + "Result 219 2022-05-30T11:20:00.000Z", + "Result 219 2022-05-30T11:25:00.000Z", + "Result 219 2022-05-30T11:30:00.000Z", + "Result 219 2022-05-30T11:35:00.000Z", + "Result 219 2022-05-30T11:40:00.000Z", + "Result 219 2022-05-30T11:45:00.000Z", + "Result 219 2022-05-30T11:50:00.000Z", + "Result 219 2022-05-30T11:55:00.000Z", + "Result 219 2022-05-30T12:00:00.000Z", + "Result 219 2022-05-30T12:05:00.000Z", + "Result 219 2022-05-30T12:10:00.000Z", + "Result 219 2022-05-30T12:15:00.000Z", + "Result 219 2022-05-30T12:20:00.000Z", + "Result 219 2022-05-30T12:25:00.000Z", + "Result 219 2022-05-30T12:30:00.000Z", + "Result 219 2022-05-30T12:35:00.000Z", + "Result 219 2022-05-30T12:40:00.000Z", + "Result 219 2022-05-30T12:45:00.000Z", + "Result 219 2022-05-30T12:50:00.000Z", + "Result 219 2022-05-30T12:55:00.000Z", + "Result 219 2022-05-30T13:00:00.000Z", + "Result 219 2022-05-30T13:05:00.000Z", + "Result 219 2022-05-30T13:10:00.000Z", + "Result 219 2022-05-30T13:15:00.000Z", + "Result 219 2022-05-30T13:20:00.000Z", + "Result 219 2022-05-30T13:25:00.000Z", + "Result 219 2022-05-30T13:30:00.000Z", + "Result 219 2022-05-30T13:35:00.000Z", + "Result 219 2022-05-30T13:40:00.000Z", + "Result 219 2022-05-30T13:45:00.000Z", + "Result 219 2022-05-30T13:50:00.000Z", + "Result 219 2022-05-30T13:55:00.000Z", + "Result 219 2022-05-30T14:00:00.000Z", + "Result 219 2022-05-30T14:05:00.000Z", + "Result 219 2022-05-30T14:10:00.000Z", + "Result 219 2022-05-30T14:15:00.000Z", + "Result 219 2022-05-30T14:20:00.000Z", + "Result 219 2022-05-30T14:25:00.000Z", + "Result 219 2022-05-30T14:30:00.000Z", + "Result 219 2022-05-30T14:35:00.000Z", + "Result 219 2022-05-30T14:40:00.000Z", + "Result 219 2022-05-30T14:45:00.000Z", + "Result 219 2022-05-30T14:50:00.000Z", + "Result 219 2022-05-30T14:55:00.000Z", + "Result 219 2022-05-30T15:00:00.000Z", + "Result 219 2022-05-30T15:05:00.000Z", + "Result 219 2022-05-30T15:10:00.000Z", + "Result 219 2022-05-30T15:15:00.000Z", + "Result 219 2022-05-30T15:20:00.000Z", + "Result 219 2022-05-30T15:25:00.000Z", + "Result 219 2022-05-30T15:30:00.000Z", + "Result 219 2022-05-30T15:35:00.000Z", + "Result 219 2022-05-30T15:40:00.000Z", + "Result 219 2022-05-30T15:45:00.000Z", + "Result 219 2022-05-30T15:50:00.000Z", + "Result 219 2022-05-30T15:55:00.000Z", + "Result 219 2022-05-30T16:00:00.000Z", + "Result 219 2022-05-30T16:05:00.000Z", + "Result 219 2022-05-30T16:10:00.000Z", + "Result 219 2022-05-30T16:15:00.000Z", + "Result 219 2022-05-30T16:20:00.000Z", + "Result 219 2022-05-30T16:25:00.000Z", + "Result 219 2022-05-30T16:30:00.000Z", + "Result 219 2022-05-30T16:35:00.000Z", + "Result 219 2022-05-30T16:40:00.000Z", + "Result 219 2022-05-30T16:45:00.000Z", + "Result 219 2022-05-30T16:50:00.000Z", + "Result 219 2022-05-30T16:55:00.000Z", + "Result 219 2022-05-30T17:00:00.000Z", + "Result 219 2022-05-30T17:05:00.000Z", + "Result 219 2022-05-30T17:10:00.000Z", + "Result 219 2022-05-30T17:15:00.000Z", + "Result 219 2022-05-30T17:20:00.000Z", + "Result 219 2022-05-30T17:25:00.000Z", + "Result 219 2022-05-30T17:30:00.000Z", + "Result 219 2022-05-30T17:35:00.000Z", + "Result 219 2022-05-30T17:40:00.000Z", + "Result 219 2022-05-30T17:45:00.000Z", + "Result 219 2022-05-30T17:50:00.000Z", + "Result 219 2022-05-30T17:55:00.000Z", + "Result 219 2022-05-30T18:00:00.000Z", + "Result 219 2022-05-30T18:05:00.000Z", + "Result 219 2022-05-30T18:10:00.000Z", + "Result 219 2022-05-30T18:15:00.000Z", + "Result 219 2022-05-30T18:20:00.000Z", + "Result 219 2022-05-30T18:25:00.000Z", + "Result 219 2022-05-30T18:30:00.000Z", + "Result 219 2022-05-30T18:35:00.000Z", + "Result 219 2022-05-30T18:40:00.000Z", + "Result 220 2022-05-30T18:45:00.000Z", + "Result 221 2022-05-30T18:50:00.000Z", + "Result 222 2022-05-30T18:55:00.000Z", + "Result 223 2022-05-30T19:00:00.000Z", + "Result 224 2022-05-30T19:05:00.000Z", + "Result 225 2022-05-30T19:10:00.000Z", + "Result 226 2022-05-30T19:15:00.000Z", + "Result 227 2022-05-30T19:20:00.000Z", + "Result 228 2022-05-30T19:25:00.000Z", + "Result 229 2022-05-30T19:30:00.000Z", + "Result 230 2022-05-30T19:35:00.000Z", + "Result 231 2022-05-30T19:40:00.000Z", + "Result 232 2022-05-30T19:45:00.000Z", + "Result 233 2022-05-30T19:50:00.000Z", + "Result 234 2022-05-30T19:55:00.000Z", + "Result 235 2022-05-30T20:00:00.000Z", + "Result 236 2022-05-30T20:05:00.000Z", + "Result 237 2022-05-30T20:10:00.000Z", + "Result 238 2022-05-30T20:15:00.000Z", + "Result 239 2022-05-30T20:20:00.000Z", + "Result 240 2022-05-30T20:25:00.000Z", + "Result 241 2022-05-30T20:30:00.000Z", + "Result 242 2022-05-30T20:35:00.000Z", + "Result 243 2022-05-30T20:40:00.000Z", + "Result 244 2022-05-30T20:45:00.000Z", + "Result 245 2022-05-30T20:50:00.000Z", + "Result 246 2022-05-30T20:55:00.000Z", + "Result 247 2022-05-30T21:00:00.000Z", + "Result 248 2022-05-30T21:05:00.000Z", + "Result 249 2022-05-30T21:10:00.000Z", + "Result 250 2022-05-30T21:15:00.000Z", + "Result 251 2022-05-30T21:20:00.000Z", + "Result 252 2022-05-30T21:25:00.000Z", + "Result 253 2022-05-30T21:30:00.000Z", + "Result 254 2022-05-30T21:35:00.000Z", + "Result 255 2022-05-30T21:40:00.000Z", + "Result 256 2022-05-30T21:45:00.000Z", + "Result 257 2022-05-30T21:50:00.000Z", + "Result 258 2022-05-30T21:55:00.000Z", + "Result 259 2022-05-30T22:00:00.000Z", + "Result 260 2022-05-30T22:05:00.000Z", + "Result 261 2022-05-30T22:10:00.000Z", + "Result 262 2022-05-30T22:15:00.000Z", + "Result 263 2022-05-30T22:20:00.000Z", + "Result 265 2022-05-30T22:25:00.000Z", + "Result 267 2022-05-30T22:30:00.000Z", + "Result 269 2022-05-30T22:35:00.000Z", + "Result 271 2022-05-30T22:40:00.000Z", + "Result 273 2022-05-30T22:45:00.000Z", + "Result 275 2022-05-30T22:50:00.000Z", + "Result 277 2022-05-30T22:55:00.000Z", + "Result 279 2022-05-30T23:00:00.000Z", + "Result 281 2022-05-30T23:05:00.000Z", + "Result 283 2022-05-30T23:10:00.000Z", + "Result 285 2022-05-30T23:15:00.000Z", + "Result 287 2022-05-30T23:20:00.000Z", + "Result 289 2022-05-30T23:25:00.000Z", + "Result 291 2022-05-30T23:30:00.000Z", + "Result 293 2022-05-30T23:35:00.000Z", + "Result 295 2022-05-30T23:40:00.000Z", + "Result 297 2022-05-30T23:45:00.000Z", + "Result 299 2022-05-30T23:50:00.000Z", + "Result 301 2022-05-30T23:55:00.000Z", + "Result 303 2022-05-31T00:00:00.000Z", + "Result 305 2022-05-31T00:05:00.000Z", + "Result 307 2022-05-31T00:10:00.000Z", + "Result 309 2022-05-31T00:15:00.000Z", + "Result 311 2022-05-31T00:20:00.000Z", + "Result 313 2022-05-31T00:25:00.000Z", + "Result 315 2022-05-31T00:30:00.000Z", + "Result 317 2022-05-31T00:35:00.000Z", + "Result 319 2022-05-31T00:40:00.000Z", + "Result 321 2022-05-31T00:45:00.000Z", + "Result 323 2022-05-31T00:50:00.000Z", + "Result 325 2022-05-31T00:55:00.000Z", + "Result 327 2022-05-31T01:00:00.000Z", + "Result 329 2022-05-31T01:05:00.000Z", + "Result 331 2022-05-31T01:10:00.000Z", + "Result 333 2022-05-31T01:15:00.000Z", + "Result 335 2022-05-31T01:20:00.000Z", + "Result 337 2022-05-31T01:25:00.000Z", + "Result 339 2022-05-31T01:30:00.000Z", + "Result 341 2022-05-31T01:35:00.000Z", + "Result 343 2022-05-31T01:40:00.000Z", + "Result 345 2022-05-31T01:45:00.000Z", + "Result 347 2022-05-31T01:50:00.000Z", + "Result 349 2022-05-31T01:55:00.000Z", + "Result 351 2022-05-31T02:00:00.000Z", + "Result 353 2022-05-31T02:05:00.000Z", + "Result 355 2022-05-31T02:10:00.000Z", + "Result 357 2022-05-31T02:15:00.000Z", + "Result 359 2022-05-31T02:20:00.000Z", + "Result 361 2022-05-31T02:25:00.000Z", + "Result 363 2022-05-31T02:30:00.000Z", + "Result 366 2022-05-31T02:35:00.000Z", + "Result 369 2022-05-31T02:40:00.000Z", + "Result 372 2022-05-31T02:45:00.000Z", + "Result 375 2022-05-31T02:50:00.000Z", + "Result 378 2022-05-31T02:55:00.000Z", + "Result 381 2022-05-31T03:00:00.000Z", + "Result 384 2022-05-31T03:05:00.000Z", + "Result 387 2022-05-31T03:10:00.000Z", + "Result 390 2022-05-31T03:15:00.000Z", + "Result 393 2022-05-31T03:20:00.000Z", + "Result 396 2022-05-31T03:25:00.000Z", + "Result 399 2022-05-31T03:30:00.000Z", "Result 400 2022-05-31T03:35:00.000Z", "Result 400 2022-05-31T03:40:00.000Z", "Result 400 2022-05-31T03:45:00.000Z", diff --git a/test/__snapshots__/simulatorAlcohol.test.ts.snap b/test/__snapshots__/simulatorAlcohol.test.ts.snap index ed4d6fe..2dafa91 100644 --- a/test/__snapshots__/simulatorAlcohol.test.ts.snap +++ b/test/__snapshots__/simulatorAlcohol.test.ts.snap @@ -2,51 +2,56 @@ exports[`simulatorAlcohol test start from 100 @12:00Z with deg22(-6h) + alc 1U(+1h) + alc 4U(+2h) 1`] = ` Array [ - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, - 180, + 181, + 182, + 183, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 184, + 183, + 182, + 181, 180, 179, 178, @@ -81,15 +86,7 @@ Array [ 149, 148, 147, - 146, - 146, - 146, - 146, - 146, - 146, - 146, - 146, - 146, + 147, 146, 145, 144, @@ -114,9 +111,7 @@ Array [ 114, 112, 110, - 109, 108, - 107, 106, 105, 104, @@ -129,30 +124,56 @@ Array [ 97, 96, 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, - 95, + 94, + 93, + 92, + 91, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 90, + 91, + 92, + 93, + 94, 95, 96, 97, @@ -221,75 +242,54 @@ Array [ 160, 161, 162, - 163, - 164, - 165, - 166, - 167, - 168, - 169, - 170, - 171, - 172, - 173, - 174, - 175, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 176, - 175, - 174, - 173, - 172, - 171, - 170, - 169, - 168, - 167, - 166, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, + 162, ] `; @@ -335,101 +335,101 @@ Array [ 0, 0, 0, + 0.00011738, + 0.01019407, + 0.03519992, + 0.07057856, + 0.08957141, + 0.10691521, + 0.12267787, + 0.13692515, + 0.14972075, + 0.16112634, + 0.17120161, + 0.18000437, + 0.18759054, + 0.19401423, + 0.19932783, + 0.20358196, + 0.20682564, + 0.20910624, + 0.21046956, + 0.21095989, + 0.21062002, + 0.20949131, + 0.20761372, + 0.20502584, + 0.20176496, + 0.19786706, + 0.19336688, + 0.18829797, + 0.18269267, + 0.1765822, + 0.16999666, + 0.16296509, + 0.15551547, + 0.14767476, + 0.13946894, + 0.13092305, + 0.12206118, + 0.11290654, + 0.10348144, + 0.09380736, + 0.08390497, + 0.07379411, + 0.06349388, + 0.05302261, + 0.0423979, + 0.05060563, + 0.10488502, + 0.20018531, + 0.25774233, + 0.3115092, + 0.36043471, + 0.40471975, + 0.44455885, + 0.48014037, + 0.5116467, + 0.53925435, + 0.56313419, + 0.58345155, + 0.60036641, + 0.61403352, + 0.62460256, + 0.63221831, + 0.63702072, + 0.63914511, + 0.63872226, + 0.63587856, + 0.63073612, + 0.62341291, + 0.61402286, + 0.60267598, + 0.58947847, + 0.57453284, + 0.55793801, + 0.53978941, + 0.52017908, + 0.49919579, + 0.4769251, + 0.45344948, + 0.4288484, + 0.40319838, + 0.37657315, + 0.34904367, + 0.32067823, + 0.29154254, + 0.2616998, + 0.23121078, + 0.20013388, + 0.16852522, + 0.13643868, + 0.10392603, + 0.0710369, + 0.03781895, + 0.00431784, + 0, 0, - 0.00181238, - 0.0177838, - 0.04866478, - 0.08040778, - 0.09960293, - 0.11710451, - 0.13298247, - 0.1473046, - 0.16013653, - 0.17154178, - 0.18158188, - 0.19031635, - 0.19780282, - 0.20409703, - 0.20925293, - 0.21332269, - 0.21635676, - 0.21840394, - 0.2195114, - 0.21972474, - 0.21908803, - 0.21764385, - 0.21543335, - 0.21249625, - 0.20887092, - 0.20459442, - 0.19970251, - 0.19422969, - 0.18820927, - 0.18167337, - 0.17465295, - 0.1671779, - 0.15927699, - 0.15097797, - 0.14230756, - 0.1332915, - 0.12395458, - 0.11432064, - 0.10441265, - 0.09425268, - 0.08386196, - 0.07326091, - 0.06246914, - 0.05150549, - 0.04038805, - 0.02913419, - 0.03728223, - 0.09343661, - 0.1976542, - 0.26816815, - 0.32420285, - 0.37519333, - 0.42134888, - 0.46287218, - 0.49995948, - 0.53280077, - 0.56157998, - 0.58647512, - 0.60765843, - 0.62529659, - 0.63955083, - 0.65057711, - 0.65852624, - 0.66354405, - 0.6657715, - 0.66534487, - 0.66239582, - 0.65705159, - 0.64943508, - 0.63966498, - 0.62785591, - 0.61411852, - 0.59855962, - 0.58128226, - 0.56238586, - 0.54196633, - 0.52011615, - 0.49692445, - 0.47247717, - 0.44685709, - 0.42014396, - 0.39241458, - 0.36374288, - 0.33420002, - 0.30385446, - 0.27277204, - 0.24101608, - 0.20864743, - 0.17572455, - 0.14230359, - 0.10843847, - 0.07418093, - 0.0395806, - 0.00468507, 0, 0, 0, @@ -589,62 +589,70 @@ Array [ exports[`simulatorAlcohol test start from 100 @12:00Z with deg23(-4h) + alc 2U(+1h) 1`] = ` Array [ 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, - 101, + 102, + 103, + 104, + 105, + 106, + 107, + 108, + 109, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 110, + 109, + 108, + 107, + 106, + 105, + 104, + 103, + 102, 101, 100, 99, @@ -691,96 +699,100 @@ Array [ 58, 57, 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, - 56, + 55, + 54, + 53, + 52, + 51, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 50, + 51, + 52, + 53, + 54, + 55, 56, 57, 58, @@ -824,58 +836,46 @@ Array [ 96, 97, 98, - 99, - 100, - 101, - 102, - 103, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 104, - 103, - 102, - 101, - 100, - 99, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, + 98, 98, 97, 96, 95, - 94, - 93, - 92, - 91, ] `; @@ -937,56 +937,56 @@ Array [ 0, 0, 0, + 0.00093485, + 0.02479308, + 0.07807856, + 0.14580173, + 0.18339223, + 0.21770083, + 0.24886284, + 0.2770093, + 0.30226711, + 0.32475915, + 0.34460437, + 0.36191789, + 0.37681115, + 0.38939197, + 0.39976468, + 0.40803018, + 0.41428607, + 0.41862674, + 0.42114343, + 0.42192436, + 0.42105477, + 0.41861705, + 0.41469079, + 0.40935287, + 0.40267753, + 0.39473645, + 0.38559885, + 0.37533149, + 0.36399883, + 0.35166303, + 0.33838404, + 0.32421966, + 0.30922563, + 0.29345565, + 0.27696144, + 0.25979285, + 0.24199785, + 0.22362263, + 0.20471166, + 0.18530767, + 0.1654518, + 0.14518357, + 0.12454099, + 0.10356054, + 0.08227728, + 0.06072485, + 0.03893554, + 0.01694032, 0, 0, - 0.01424681, - 0.06025025, - 0.13438037, - 0.17874624, - 0.21557476, - 0.24908046, - 0.27940129, - 0.30667081, - 0.33101836, - 0.35256914, - 0.37144438, - 0.38776138, - 0.40163365, - 0.41317104, - 0.42247979, - 0.42966269, - 0.43481911, - 0.43804516, - 0.43943373, - 0.43907461, - 0.43705459, - 0.43345749, - 0.4283643, - 0.42185324, - 0.41399985, - 0.40487701, - 0.39455513, - 0.38310209, - 0.37058342, - 0.35706231, - 0.34259968, - 0.32725428, - 0.31108272, - 0.29413955, - 0.27647731, - 0.2581466, - 0.23919614, - 0.21967281, - 0.1996217, - 0.1790862, - 0.15810803, - 0.13672727, - 0.11498243, - 0.09291051, - 0.07054703, - 0.04792607, - 0.02508032, - 0.00204114, 0, 0, 0, diff --git a/test/__snapshots__/simulatorCortisone.test.ts.snap b/test/__snapshots__/simulatorCortisone.test.ts.snap index ea1d28d..6ab4f25 100644 --- a/test/__snapshots__/simulatorCortisone.test.ts.snap +++ b/test/__snapshots__/simulatorCortisone.test.ts.snap @@ -5,22 +5,6 @@ Array [ 151, 152, 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, - 153, 154, 155, 156, @@ -30,6 +14,8 @@ Array [ 160, 161, 162, + 162, + 162, 163, 164, 165, @@ -40,107 +26,39 @@ Array [ 170, 171, 172, - 172, - 171, + 173, + 174, + 175, + 176, + 177, + 178, + 179, + 180, + 181, + 182, + 183, + 184, + 185, + 186, + 186, + 185, + 184, + 182, + 180, + 178, + 176, + 173, 170, - 168, - 166, - 164, - 162, - 159, - 156, - 153, - 150, - 147, - 144, - 141, - 138, - 135, - 132, - 129, - 126, - 123, - 121, - 119, - 117, - 115, - 113, - 111, - 109, - 107, - 106, - 105, - 104, - 103, - 102, - 101, - 100, - 99, - 99, - 99, - 99, - 99, - 99, - 99, - 99, - 99, - 99, - 100, - 101, - 102, - 103, - 104, - 105, - 106, - 107, - 108, - 109, - 110, - 111, - 112, - 113, - 115, - 117, - 119, - 121, - 123, - 125, - 127, - 129, - 131, - 133, - 135, - 137, - 139, - 141, - 143, - 145, - 147, - 149, - 151, - 153, - 155, - 157, - 159, - 161, - 163, - 164, - 164, + 167, 164, - 163, - 162, 161, - 159, - 157, + 158, 155, - 153, - 151, + 152, 149, - 147, - 145, + 146, 143, - 141, - 139, + 140, 137, 135, 133, @@ -148,23 +66,29 @@ Array [ 129, 127, 125, - 124, 123, - 122, 121, 120, 119, 118, 117, - 117, - 117, - 117, - 117, - 117, - 117, - 117, - 117, - 117, + 116, + 115, + 114, + 113, + 113, + 113, + 113, + 113, + 113, + 113, + 113, + 113, + 113, + 113, + 114, + 115, + 116, 117, 118, 119, @@ -175,11 +99,8 @@ Array [ 124, 125, 126, - 127, 128, - 129, 130, - 131, 132, 134, 136, @@ -203,37 +124,108 @@ Array [ 172, 174, 176, - 178, - 180, - 182, - 184, - 186, - 188, - 190, - 192, - 194, - 196, - 198, - 200, - 202, - 204, - 206, - 208, - 210, - 212, - 214, + 177, + 177, + 176, + 175, + 174, + 172, + 170, + 168, + 166, + 164, + 162, + 160, + 158, + 156, + 154, + 152, + 150, + 148, + 146, + 144, + 142, + 140, + 138, + 136, + 134, + 132, + 131, + 130, + 129, + 128, + 127, + 126, + 125, + 124, + 124, + 124, + 124, + 124, + 124, + 124, + 124, + 124, + 124, + 124, + 125, + 126, + 127, + 128, + 129, + 130, + 131, + 132, + 133, + 134, + 135, + 136, + 137, + 138, + 139, + 141, + 143, + 145, + 147, + 149, + 151, + 153, + 155, + 157, + 159, + 161, + 163, + 165, + 167, + 169, + 171, + 173, + 175, + 177, + 179, + 181, + 183, + 185, + 187, + 189, + 191, + 193, + 195, + 197, + 199, + 201, + 203, + 205, + 207, + 209, + 211, + 213, 215, - 216, 217, - 218, 219, - 220, 221, - 222, 223, - 224, 225, - 226, 227, 228, 229, @@ -256,30 +248,62 @@ Array [ 246, 247, 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, - 248, + 249, + 250, + 251, + 252, + 253, + 254, + 255, + 256, + 257, + 258, + 259, + 260, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 261, + 260, + 259, + 258, + 257, + 256, + 255, + 254, + 253, + 252, + 251, + 250, + 249, 248, 247, 246, @@ -399,86 +423,63 @@ Array [ 132, 131, 130, - 129, - 128, - 127, - 126, - 125, - 124, - 123, - 122, - 121, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 120, - 121, - 122, - 123, - 124, - 125, - 126, - 127, - 128, - 129, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, + 130, 130, 131, 132, @@ -534,49 +535,48 @@ Array [ 182, 183, 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 184, - 183, - 182, - 181, - 180, - 179, - 178, - 177, - 176, - 175, + 185, + 186, + 187, + 188, + 189, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, + 190, ] `; diff --git a/test/__snapshots__/uva.test.ts.snap b/test/__snapshots__/uva.test.ts.snap index 7571861..1d4ec46 100644 --- a/test/__snapshots__/uva.test.ts.snap +++ b/test/__snapshots__/uva.test.ts.snap @@ -2,19 +2,19 @@ exports[`uva test default PATIENT basal with gla 30 should generate flat sgv 1`] = ` Object { - "Gp": 174.37007296953632, - "Gt": 131.17997187028692, - "I_": 40.61860038487993, - "Il": 1.9763325953633464, - "Ip": 2.0309722602744666, - "Isc1": 55.027252745582075, - "Isc2": 49.58499694665628, + "Gp": 172.16999363425157, + "Gt": 129.36710057913723, + "I_": 41.14442017759129, + "Il": 2.003990855337264, + "Ip": 2.0572694126441236, + "Isc1": 55.718153844257, + "Isc2": 50.207567162989385, "Qgut": 0, "Qsto1": 0, "Qsto2": 0, "W": 0, - "X": 3.1046599063967197, - "XL": 40.61196071438584, + "X": 3.6306029496153656, + "XL": 41.136798965515716, "Y": 0, "Z": 0, } @@ -22,246 +22,246 @@ Object { exports[`uva test default PATIENT basal with gla 30 should generate flat sgv 2`] = ` Array [ - 100.00004341832874, - 100.00063926373056, - 100.00252725636639, - 100.00601669402415, - 100.01099554434907, - 100.01710944569565, - 100.02389868149535, - 100.03087838192683, - 100.0375807372491, - 100.04357557416272, - 100.04847929650376, - 100.05195768468967, - 100.05372546128412, - 100.05354415428017, - 100.0512190784006, - 100.04659588782322, - 100.03955696133411, - 100.03001777658238, - 100.01792337074566, - 100.00324494910879, - 99.98597668011982, - 99.96613269998977, - 99.94374433900344, - 99.91885757384973, - 99.89153070455808, - 99.8618322504741, - 99.8298390567432, - 99.79563460072384, - 99.75930748641643, - 99.72095011421546, - 99.68065751294073, - 99.63852632108264, - 99.59465390442364, - 99.5491375976088, - 99.50207405778079, - 99.45355871902687, - 99.40368533707495, - 99.35254561439477, - 99.30022889659169, - 99.2468219317042, - 99.19240868472603, - 99.137070200355, - 99.08088450762277, - 99.02392656067454, - 98.96626821054504, - 98.90797820331426, - 98.84912220052556, - 98.78976281820653, - 98.72995968125352, - 98.66976949032609, - 98.60924609874533, - 98.5484405972067, - 98.48740140440381, - 98.42617436191524, - 98.36480283193691, - 98.30332779664771, - 98.24178795817886, - 98.18021983831892, - 98.11865787723063, - 98.0571345305815, - 97.99568036460026, - 97.93432414866939, - 97.87309294514667, - 97.81201219618362, - 97.75110580737015, - 97.69039622808954, - 97.62990452851439, - 97.56965047321262, - 97.50965259136608, - 97.4499282436311, - 97.39049368569407, - 97.3313641285923, - 97.27255379588557, - 97.21407597777647, - 97.15594308228424, - 97.09816668358509, - 97.04075756763615, - 96.98372577520162, - 96.92708064240244, - 96.87083083890991, - 96.81498440390303, - 96.75954877990684, - 96.70453084462774, - 96.64993694089699, - 96.59577290483124, - 96.54204409231502, - 96.48875540390526, - 96.43591130825416, - 96.38351586414286, - 96.33157274121228, - 96.2800852394755, - 96.22905630768929, - 96.17848856065962, - 96.12838429555133, - 96.07874550726802, - 96.02957390296397, - 95.98087091574678, - 95.93263771762501, - 95.88487523175206, - 95.83758414401395, - 95.79076491400568, - 95.74441778543745, - 95.6985427960097, - 95.65313978679241, - 95.60820841114281, - 95.5637481431919, - 95.51975828592852, - 95.47623797890783, - 95.43318620560923, - 95.3906018004654, - 95.34848345558467, - 95.30682972718574, - 95.26563904176257, - 95.22490970199634, - 95.18463989242984, - 95.1448276849179, - 95.10547104386747, - 95.06656783127913, - 95.02811581160095, - 94.99011265640497, - 94.95255594889579, - 94.91544318826004, - 94.87877179386403, - 94.84253910930778, - 94.80674240634183, - 94.77137888865293, - 94.73644569552462, - 94.70193990537818, - 94.6678585391983, - 94.63419856384891, - 94.60095689528258, - 94.56813040164788, - 94.53571590629858, - 94.50371019070745, - 94.47210999728838, - 94.44091203212962, - 94.41011296764101, - 94.3797094451177, - 94.34969807722266, - 94.32007545039117, - 94.29083812715818, - 94.26198264841159, - 94.2335055355732, - 94.2054032927092, - 94.17767240857171, - 94.15030935857365, - 94.1233106066981, - 94.09667260734413, - 94.07039180711031, - 94.04446464651771, - 94.01888756167344, - 93.9936569858765, - 93.96876935116714, - 93.9442210898211, - 93.92000863578976, - 93.89612842608788, - 93.87257690212988, - 93.84935051101608, - 93.82644570676982, - 93.80385895152651, - 93.78158671667651, - 93.7596254839621, - 93.73797174652995, - 93.71662200994041, - 93.69557279313406, - 93.67482062935754, - 93.65436206704872, - 93.63419367068265, - 93.61431202157934, - 93.59471371867444, - 93.57539537925342, - 93.55635363965035, - 93.53758515591257, - 93.51908660443166, - 93.50085468254194, - 93.4828861090872, - 93.46517762495685, - 93.44772599359194, - 93.43052800146229, - 93.41358045851524, - 93.39688019859713, - 93.38042407984825, - 93.36420898507163, - 93.3482318220773, - 93.33248952400193, - 93.3169790496054, - 93.30169738354407, - 93.2866415366224, - 93.27180854602315, - 93.25719547551716, - 93.24279941565266, - 93.228617483926, - 93.2146468249331, - 93.20088461050338, - 93.18732803981628, - 93.1739743395007, - 93.16082076371889, - 93.14786459423406, - 93.13510314046367, - 93.12253373951788, - 93.11015375622416, - 93.0979605831388, - 93.08595164054525, - 93.07412437644042, - 93.06247626650887, - 93.05100481408573, - 93.03970755010897, - 93.02858203306093, - 93.01762584889984, - 93.00683661098209, - 92.99621195997503, - 92.98574956376117, - 92.97544711733413, - 92.96530234268641, - 92.95531298868976, - 92.94547683096825, - 92.93579167176468, - 92.92625533979991, - 92.91686569012683, - 92.90762060397758, - 92.89851798860602, - 92.88955577712426, - 92.88073192833473, - 92.87204442655724, - 92.86349128145203, - 92.85507052783805, - 92.84678022550807, - 92.83861845903957, - 92.83058333760269, - 92.82267299476476, - 92.81488558829199, - 92.80721929994823, - 92.79967233529167, - 92.79224292346885, - 92.7849293170066, - 92.77772979160234, - 92.77064264591222, - 92.76366620133795, - 92.75679880181231, - 92.75003881358316, + 100.00004322991686, + 100.00063492353028, + 100.00250189626965, + 100.00593128856623, + 100.01078205750811, + 100.01666662064541, + 100.02309014171705, + 100.0295325805898, + 100.03549230499027, + 100.04050767395145, + 100.04416666216194, + 100.04611008372085, + 100.04603137865107, + 100.04367454087162, + 100.038831046713, + 100.03133626887137, + 100.02106566209093, + 100.0079308973572, + 99.99187605773699, + 99.97287396968255, + 99.95092271781185, + 99.92604237335155, + 99.89827195365011, + 99.8676666208005, + 99.83429512048515, + 99.79823745705112, + 99.7595827971124, + 99.71842759135265, + 99.6748739024279, + 99.62902792576206, + 99.5809986894409, + 99.53089691922526, + 99.4788340548246, + 99.42492140392375, + 99.36926942097155, + 99.31198709837709, + 99.25318145847004, + 99.19295713534116, + 99.13141603645782, + 99.06865707473256, + 99.00477596249046, + 98.93986505952898, + 98.874013268178, + 98.80730596894692, + 98.73982499098422, + 98.67164861217178, + 98.60285158423002, + 98.53350517872221, + 98.4636772503155, + 98.39343231408644, + 98.32283163405013, + 98.25193332044589, + 98.18079243363499, + 98.10946109275176, + 98.03798858751037, + 97.96642149179964, + 97.89480377790431, + 97.82317693037456, + 97.75158005872632, + 97.68005000829865, + 97.60862146871827, + 97.5373270795314, + 97.46619753265912, + 97.39526167141297, + 97.3245465858815, + 97.25407770455755, + 97.18387888212902, + 97.11397248340091, + 97.04437946335194, + 96.97511944336169, + 96.90621078366898, + 96.83767065214292, + 96.7695150894652, + 96.70175907083494, + 96.63441656431722, + 96.56750058596371, + 96.50102325183946, + 96.43499582709119, + 96.36942877219582, + 96.30433178652639, + 96.23971384937164, + 96.17558325854382, + 96.11194766670592, + 96.04881411554557, + 95.9861890679199, + 95.92407843808986, + 95.86248762015903, + 95.8014215148259, + 95.74088455455517, + 95.68088072726606, + 95.62141359863392, + 95.56248633309325, + 95.50410171362756, + 95.4462621604253, + 95.38896974847749, + 95.33222622418715, + 95.2760330210573, + 95.22039127451895, + 95.16530183595795, + 95.11076528599406, + 95.05678194706363, + 95.00335189535245, + 94.95047497212309, + 94.89815079447743, + 94.8463787655921, + 94.79515808446234, + 94.74448775518688, + 94.69436659582371, + 94.6447932468453, + 94.59576617921861, + 94.54728370213424, + 94.49934397040658, + 94.4519449915656, + 94.40508463265867, + 94.35876062678074, + 94.31297057934735, + 94.26771197412715, + 94.22298217904604, + 94.17877845177605, + 94.13509794512082, + 94.09193771220758, + 94.04929471149647, + 94.00716581161504, + 93.96554779602776, + 93.92443736754669, + 93.88383115269161, + 93.84372570590578, + 93.80411751363316, + 93.76500299826324, + 93.72637852194828, + 93.68824039029786, + 93.65058485595571, + 93.61340812206211, + 93.57670634560678, + 93.54047564067514, + 93.5047120815916, + 93.46941170596352, + 93.4345705176278, + 93.40018448950413, + 93.36624956635681, + 93.33276166746806, + 93.29971668922462, + 93.26711050762101, + 93.23493898068054, + 93.2031979507966, + 93.17188324699664, + 93.14099068712999, + 93.11051607998176, + 93.08045522731493, + 93.05080392584154, + 93.02155796912554, + 92.9927131494183, + 92.96426525942861, + 92.93621009402885, + 92.90854345189842, + 92.88126113710616, + 92.85435896063355, + 92.8278327418391, + 92.80167830986676, + 92.77589150499796, + 92.75046817995036, + 92.72540420112318, + 92.70069544979151, + 92.67633782324991, + 92.65232723590735, + 92.62865962033419, + 92.60533092826248, + 92.58233713154122, + 92.55967422304681, + 92.53733821755117, + 92.51532515254712, + 92.49363108903366, + 92.47225211226083, + 92.45118433243651, + 92.43042388539524, + 92.40996693323069, + 92.38980966489257, + 92.36994829674896, + 92.35037907311523, + 92.33109826675053, + 92.31210217932231, + 92.2933871418409, + 92.27494951506365, + 92.2567856898709, + 92.23889208761368, + 92.2212651604346, + 92.20390139156262, + 92.18679729558225, + 92.16994941867868, + 92.15335433885878, + 92.13700866614982, + 92.1209090427755, + 92.10505214331094, + 92.08943467481723, + 92.07405337695563, + 92.05890502208327, + 92.04398641532991, + 92.02929439465697, + 92.01482583089975, + 92.00057762779278, + 91.98654672197982, + 91.9727300830081, + 91.95912471330833, + 91.94572764816051, + 91.93253595564647, + 91.91954673658921, + 91.90675712448008, + 91.89416428539411, + 91.88176541789403, + 91.8695577529234, + 91.85753855368932, + 91.84570511553548, + 91.83405476580587, + 91.82258486369903, + 91.81129280011439, + 91.80017599748992, + 91.78923190963285, + 91.77845802154205, + 91.76785184922447, + 91.75741093950428, + 91.74713286982636, + 91.73701524805367, + 91.727055712259, + 91.71725193051195, + 91.70760160066054, + 91.69810245010872, + 91.6887522355894, + 91.6795487429333, + 91.67048978683466, + 91.66157321061281, + 91.65279688597126, + 91.64415871275327, + 91.63565661869518, + 91.62728855917702, + 91.61905251697097, + 91.61094650198781, + 91.6029685510215, + 91.59511672749233, + 91.58738912118845, + 91.57978384800616, ] `; diff --git a/test/inputTest.ts b/test/inputTest.ts index 5abb4df..3f861df 100644 --- a/test/inputTest.ts +++ b/test/inputTest.ts @@ -273,7 +273,7 @@ export const testGenerator = ( WEIGHT: 250 / 3, AGE: 51, GENDER: 'Male', - TZ: 'Europe/Helsinki', + TZ: 'UTC', }; const noiseActivities = []; const basalActivities = []; diff --git a/test/liver.test.ts b/test/liver.test.ts index 5c39d9f..4ccad09 100644 --- a/test/liver.test.ts +++ b/test/liver.test.ts @@ -9,13 +9,7 @@ describe('Liver test', () => { jest.useRealTimers(); }); it.each([[[30, 10]], [[20, 8]], [[40, 14]]])('test liver %p', ([isf, cr]) => { - const r = liver( - isf, - cr, - { physical: 1, alcohol: 0 }, - 250 / 3, - 'Europe/Helsinki', - ); + const r = liver(isf, cr, { physical: 1, alcohol: 0 }, 250 / 3, 'UTC'); expect(r).toMatchSnapshot(); }); }); diff --git a/test/simulator.test.ts b/test/simulator.test.ts index efb5650..9c82e21 100644 --- a/test/simulator.test.ts +++ b/test/simulator.test.ts @@ -71,7 +71,7 @@ describe('simulator test', () => { WEIGHT: 250 / 3, AGE: 51, GENDER: 'Male', - TZ: 'Europe/Rome', + TZ: 'UTC', }; const log = []; @@ -438,7 +438,7 @@ describe('simulator test', () => { WEIGHT: 250 / 3, AGE: 51, GENDER: 'Male', - TZ: 'Europe/Rome', + TZ: 'UTC', }; const log = []; diff --git a/test/uva.test.ts b/test/uva.test.ts index 96328aa..9845149 100644 --- a/test/uva.test.ts +++ b/test/uva.test.ts @@ -36,7 +36,7 @@ describe('uva test default PATIENT', () => { AGE: 40, GENDER: 'Male', WEIGHT: 250 / 3, - TZ: 'Europe/Rome', + TZ: 'UTC', }; test('basal with gla 30 should generate flat sgv', async () => {