The Science of Spicy
Spiciness is not a taste; it is literally a pain signal.
Peppers evolved to produce a chemical compound called capsaicin to deter mammals from eating them (while birds, who don't have capsaicin receptors, can eat the seeds and disperse them). When capsaicin binds to the TRPV1 receptors on your tongue, it tricks your brain into thinking your mouth is physically on fire.
The Scoville Heat Unit (SHU)
Created by Wilbur Scoville in 1912, the SHU measures the concentration of capsaicin. Originally, it was a subjective test of how much sugar water it took to dilute the pepper until the heat was undetectable. Today, we use High-Performance Liquid Chromatography (HPLC) for an exact scientific measurement.
How the Math Works
The tool maps input values across a logarithmic scale of known SHU boundaries.
If you input a raw SHU number (e.g., 50,000), the script iterates against our pepper database to find the closest match. It then calculates a "Tear Factor" multiplier by dividing your input by the baseline heat of a standard Jalapeño (~5,000 SHU). For example, a 2-million SHU Carolina Reaper will output a warning that it is 400x hotter than a Jalapeño, triggering the 'Survival Guide' UI module.
Advanced Theory
Botanical capsaicin concentration is an evolutionary defense mechanism mapped directly onto a geometric progression scale. When mapping these values, we utilize a logarithmic curve rather than linear algebra, because human pain receptors (TRPV1) don't interpret heat linearly. A pepper that is mathematically 10x hotter will often register neurologically as 100x more painful. This calculator accurately simulates that sensory amplification, giving you a terrifyingly precise statistical breakdown of the biological warfare you're about to wage on your own digestive tract.