To solve the optimization problem described, we need to define the decision variables and the objective function, as well as any constraints that apply. 

Let's denote:
- \(x_1\) as the amount invested in the airline industry,
- \(x_2\) as the amount invested in the railway industry.

The objective is to maximize profit, given by \(0.30x_1 + 0.10x_2\), since each dollar invested in the airline industry yields $0.30 and each dollar in the railway industry yields $0.10.

Constraints are:
1. The total amount invested cannot exceed $50,000: \(x_1 + x_2 \leq 50000\).
2. A minimum of $10,000 must be invested in the railway industry: \(x_2 \geq 10000\).
3. At least 25% of all money invested must be in the airline industry: \(x_1 \geq 0.25(x_1 + x_2)\).

Now, let's formulate this problem into a linear programming model and then translate it into Gurobi code in Python.

```python
from gurobipy import *

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

# Define the decision variables
x1 = m.addVar(lb=0, name="airline_investment")
x2 = m.addVar(lb=0, name="railway_investment")

# Objective function: Maximize profit
m.setObjective(0.30*x1 + 0.10*x2, GRB.MAXIMIZE)

# Constraints
m.addConstr(x1 + x2 <= 50000, name="total_investment")
m.addConstr(x2 >= 10000, name="minimum_railway")
m.addConstr(x1 >= 0.25*(x1 + x2), name="airline_percentage")

# Optimize the model
m.optimize()

# Print solution
if m.status == GRB.OPTIMAL:
    print("Optimal solution found:")
    print(f"Airline Investment: {x1.x}")
    print(f"Railway Investment: {x2.x}")
    print(f"Total Profit: {m.objVal}")
else:
    print("No optimal solution found")
```