diff --git a/server.py b/server.py
index 87ae679..1031912 100644
--- a/server.py
+++ b/server.py
@@ -32,7 +32,7 @@ def create_patient(patient_id, attending_email, user_age):
 class Patient(MongoModel):
     patient_id = fields.CharField(primary_key=True)
     attending_email = fields.EmailField()
-    user_age = fields.IntegerField()
+    user_age = fields.FloatField()
     is_tachycardic = fields.ListField(field=fields.BooleanField())
     heart_rate = fields.ListField(field=fields.IntegerField())
     heart_rate_time = fields.ListField(field=fields.DateTimeField())
@@ -91,11 +91,37 @@ def send_tachycardic_email(patient_id, heart_rate, hr_timestamp,
 
 def is_tachycardic(age, heart_rate):
 
-    if age < 1:
+    if age <= 2/365:
         if heart_rate > 159:
             return True
         else:
             return False
+    elif age <= 6/365:
+        if heart_rate > 166:
+            return True
+        else:
+            return False
+    elif age <= 3/52:
+        if heart_rate > 182:
+            return True
+        else:
+            return False
+    elif age <= 2/12:
+        if heart_rate > 179:
+            return True
+        else:
+            return False
+    elif age <= 5/12:
+        if heart_rate > 186:
+            return True
+        else:
+            return False
+    elif age <= 364/365:
+        if heart_rate > 169:
+            return True
+        else:
+            return False
+
     elif age <= 2:
         if heart_rate > 151:
             return True

The program should be able to handle situations where the age is less than 1
Right now, the age is specified in years, so it cannot discern tachycardia for patients who are less than 1 year old, which have different tachycardia cutoffs for different age ranges between 0 and 1. The program should be modified to have age be a float instead of an integer, and to have the right tachycardia cutoffs for fractional ages less than 1.
diff --git a/test_server.py b/test_server.py
index db9e23d..cc6ef66 100644
--- a/test_server.py
+++ b/test_server.py
@@ -11,8 +11,18 @@ def test_create_patient():
 
 
 @pytest.mark.parametrize("age, heart_rate, expected_tachycardic", [
-    (0, 159, False),
-    (0, 160, True),
+    (2/365, 159, False),
+    (2/365, 160, True),
+    (6/365, 166, False),
+    (6/365, 167, True),
+    (3/52, 182, False),
+    (3/52, 183, True),
+    (2/12, 179, False),
+    (2/12, 180, True),
+    (5/12, 186, False),
+    (5/12, 187, True),
+    (364/365, 169, False),
+    (364/365, 170, True),
     (1, 151, False),
     (1, 152, True),
     (2, 151, False),

pip install -r requirements.txt
parse_log_pytest
requirements.txt
pytest
3.9
requirements.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
blinker==1.9.0
certifi==2025.1.31
charset-normalizer==3.4.1
click==8.1.8
DateTime==5.5
docutils==0.21.2
exceptiongroup==1.2.2
execnet==2.1.1
Flask==3.1.0
idna==3.10
importlib_metadata==8.6.1
iniconfig==2.1.0
itsdangerous==2.2.0
Jinja2==3.1.6
MarkupSafe==3.0.2
packaging==24.2
pep8==1.7.1
pluggy==1.5.0
pymodm==0.4.3
pymongo==3.13.0
pytest==8.3.5
pytest-cache==1.0
pytest-pep8==1.0.6
python-http-client==3.3.7
pytz==2025.2
requests==2.32.3
sendgrid==6.11.0
starkbank-ecdsa==2.2.0
statistics==1.0.3.5
tomli==2.2.1
urllib3==2.3.0
Werkzeug==3.1.3
zipp==3.21.0
zope.interface==7.2

name: heart_rate_sentinel_server
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=3.0.16=h5eee18b_0
  - pip=25.0=py39h06a4308_0
  - python=3.9.21=he870216_1
  - readline=8.2=h5eee18b_0
  - setuptools=75.8.0=py39h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - tzdata=2025a=h04d1e81_0
  - wheel=0.45.1=py39h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - blinker==1.9.0
      - certifi==2025.1.31
      - charset-normalizer==3.4.1
      - click==8.1.8
      - datetime==5.5
      - docutils==0.21.2
      - exceptiongroup==1.2.2
      - execnet==2.1.1
      - flask==3.1.0
      - idna==3.10
      - importlib-metadata==8.6.1
      - iniconfig==2.1.0
      - itsdangerous==2.2.0
      - jinja2==3.1.6
      - markupsafe==3.0.2
      - packaging==24.2
      - pep8==1.7.1
      - pluggy==1.5.0
      - pymodm==0.4.3
      - pymongo==3.13.0
      - pytest==8.3.5
      - pytest-cache==1.0
      - pytest-pep8==1.0.6
      - python-http-client==3.3.7
      - pytz==2025.2
      - requests==2.32.3
      - sendgrid==6.11.0
      - starkbank-ecdsa==2.2.0
      - statistics==1.0.3.5
      - tomli==2.2.1
      - urllib3==2.3.0
      - werkzeug==3.1.3
      - zipp==3.21.0
      - zope-interface==7.2
prefix: /opt/conda/envs/heart_rate_sentinel_server

test_server.py::test_is_tachycardic[0.01643835616438356-166-False] test_server.py::test_is_tachycardic[0.057692307692307696-182-False] test_server.py::test_is_tachycardic[0.16666666666666666-179-False] test_server.py::test_is_tachycardic[0.4166666666666667-186-False] test_server.py::test_is_tachycardic[0.9972602739726028-169-False]
test_server.py::test_create_patient
test_server.py::test_is_tachycardic[0.005479452054794521-159-False] test_server.py::test_is_tachycardic[0.005479452054794521-160-True] test_server.py::test_is_tachycardic[0.01643835616438356-167-True] test_server.py::test_is_tachycardic[0.057692307692307696-183-True] test_server.py::test_is_tachycardic[0.16666666666666666-180-True] test_server.py::test_is_tachycardic[0.4166666666666667-187-True] test_server.py::test_is_tachycardic[0.9972602739726028-170-True] test_server.py::test_is_tachycardic[1-151-False] test_server.py::test_is_tachycardic[1-152-True] test_server.py::test_is_tachycardic[2-151-False] test_server.py::test_is_tachycardic[2-152-True] test_server.py::test_is_tachycardic[3-137-False] test_server.py::test_is_tachycardic[3-138-True] test_server.py::test_is_tachycardic[4-137-False] test_server.py::test_is_tachycardic[4-138-True] test_server.py::test_is_tachycardic[5-133-False] test_server.py::test_is_tachycardic[5-134-True] test_server.py::test_is_tachycardic[7-133-False] test_server.py::test_is_tachycardic[7-134-True] test_server.py::test_is_tachycardic[8-130-False] test_server.py::test_is_tachycardic[8-131-True] test_server.py::test_is_tachycardic[11-130-False] test_server.py::test_is_tachycardic[11-131-True] test_server.py::test_is_tachycardic[12-119-False] test_server.py::test_is_tachycardic[12-120-True] test_server.py::test_is_tachycardic[15-119-False] test_server.py::test_is_tachycardic[15-120-True] test_server.py::test_is_tachycardic[16-100-False] test_server.py::test_is_tachycardic[16-101-True] test_server.py::test_is_tachycardic[35-100-False] test_server.py::test_is_tachycardic[35-101-True] test_server.py::test_get_average_heart_rate test_server.py::test_get_interval_heart_rate
server.py
server.py