To solve the optimization problem described, we'll use the Gurobi Python library. The goal is to minimize the objective function $4x_0 + 5x_1$, where $x_0$ represents milligrams of potassium and $x_1$ represents milligrams of magnesium, subject to several constraints related to digestive support indices and cognitive performance indices.

Given constraints:
- Digestive support index for potassium: 23
- Cognitive performance index for potassium: 24
- Digestive support index for magnesium: 14
- Cognitive performance index for magnesium: 28
- Combined digestive support index $\geq$ 39
- Combined cognitive performance index $\geq$ 125
- $x_0 - 8x_1 \geq 0$
- Combined digestive support index $\leq$ 58
- Combined cognitive performance index $\leq$ 219

Since both $x_0$ and $x_1$ can be fractional, we don't need to specify them as integer variables.

Here's how the problem translates into Gurobi code:

```python
from gurobipy import *

# Create a new model
m = Model("Optimization_Problem")

# Define variables
x0 = m.addVar(name="milligrams_of_potassium", lb=0, ub=GRB.INFINITY)
x1 = m.addVar(name="milligrams_of_magnesium", lb=0, ub=GRB.INFINITY)

# Objective function: Minimize 4*x0 + 5*x1
m.setObjective(4*x0 + 5*x1, GRB.MINIMIZE)

# Constraints
# Combined digestive support index >= 39 and <= 58
m.addConstr(23*x0 + 14*x1 >= 39, name="digestive_support_min")
m.addConstr(23*x0 + 14*x1 <= 58, name="digestive_support_max")

# Combined cognitive performance index >= 125 and <= 219
m.addConstr(24*x0 + 28*x1 >= 125, name="cognitive_performance_min")
m.addConstr(24*x0 + 28*x1 <= 219, name="cognitive_performance_max")

# x0 - 8*x1 >= 0
m.addConstr(x0 - 8*x1 >= 0, name="potassium_magnesium_ratio")

# Optimize model
m.optimize()

# Print solution
if m.status == GRB.OPTIMAL:
    print("Optimal solution found:")
    print(f"Milligrams of Potassium: {x0.x}")
    print(f"Milligrams of Magnesium: {x1.x}")
    print(f"Objective Function Value: {m.objVal}")
else:
    print("No optimal solution found")
```