code wiki / (root) / nx_food_chem_react.nx

nx_food_chem_react.nx

buildroot/runtime/nx_food_chem_react.nx

5232 B131 linesdepth 2pulls 2 transitivereach 1 importersview sourcekind librarytopic food
docsdependenciesstructsconstsfunctions

about

nx_food_chem_react.nx -- FOOD-SCIENCE SUITE / COOKING CHEMISTRY rung. Predicts which browning/transformation reaction occurs from the actual conditions (temperature, pH, reactants, oxygen) -- Maillard vs caramelization vs enzymatic browning -- and gives the real thresholds, where a recipe just says "cook until golden". All INTEGER threshold rules (temp in C, pH x1000). Grounded chemistry: - Maillard: amino acids (protein) + REDUCING sugars, dry heat >= ~140 C (below that little browning); alkaline pH accelerates it. - Caramelization: sugar pyrolysis, NO protein needed; per-sugar onset (fructose ~110, glucose/sucrose ~160, maltose ~180 C). - Enzymatic browning: polyphenol oxidase (PPO) on cut produce + O2; stopped by acid (pH<~3), heat (>=70 C denatures PPO), antioxidant (vitamin C), or excluding O2 (submersion). THE exceed: it CLASSIFIES the browning correctly from conditions (a seared steak = Maillard, caramel = caramelization, a cut apple = enzymatic) and prescribes prevention -- generalising beyond a fixed recipe step. Grounding (cited; researcher-groundable): maillard_reaction_amino_reducing_sugar_140C caramelization_onset_temperatures_by_sugar polyphenol_oxidase_enzymatic_browning_control genealogy_id: food_chemistry_reactions + nishi_food_science_suite

dependencies 1 imports · 1 importers

nx_syscalls.nx nx_food_chem_react.nx nx_food_chem_react_test.nx

imports: nx_syscalls.nx

imported by: nx_food_chem_react_test.nx

structs

94struct NxCookScenario

consts

28const FCR_MAGIC_7000: i64 = 7000
32const FCR_MAILLARD_TEMP_C: i64 = 140 // dry-heat onset
33const FCR_PPO_INHIBIT_PH: i64 = 3000 // pH < 3.0 (acid) stops PPO
34const FCR_PPO_DENATURE_C: i64 = 70 // >= 70 C denatures PPO (blanch)
35const FCR_ALKALINE_PH: i64 = 7000 // pH > 7 accelerates Maillard
39const FCR_NONE: i64 = 0
40const FCR_MAILLARD: i64 = 1
41const FCR_CARAMELIZATION: i64 = 2
42const FCR_ENZYMATIC_BROWNING: i64 = 3
44const FCR_SUGAR_FRUCTOSE: i64 = 0
45const FCR_SUGAR_GLUCOSE: i64 = 1
46const FCR_SUGAR_SUCROSE: i64 = 2
47const FCR_SUGAR_MALTOSE: i64 = 3

functions

52func fcr_caramelization_temp(sugar_id: i64) -> i64
60func fcr_maillard(has_protein: i64, has_reducing_sugar: i64, temp_c: i64) -> i64
69func fcr_maillard_rate(temp_c: i64, ph_milli: i64) -> i64
called by 1: main
76func fcr_caramelizes(sugar_id: i64, temp_c: i64) -> i64
called by 1: main calls 1: fcr_caramelization_temp
81func fcr_enzymatic_browning(has_ppo: i64, o2_present: i64, ph_milli: i64,
106func nx_cook_scenario_new() -> *NxCookScenario
called by 1: main calls 1: sys_mmap
121func fcr_predict_browning(s: *NxCookScenario) -> i64