Microgrid sizing methods answer different mathematical questions. Exhaustive grid search finds the best feasible point in a declared discrete set. Derivative-free methods explore continuous or mixed search spaces without gradients but need convergence and repeatability evidence. MILP can prove global optimality for a linearized formulation within solver tolerances. None is automatically “best” without matching the model, constraints, and decision stage.
Key takeaways
- A sampled search can make a strong, exact claim about evaluated candidates while making no claim about unsampled capacities.
- Derivative-free does not mean invalid or random: HOMER Pro officially offers both a grid search and a proprietary derivative-free optimizer.
- MILP global optimality applies to the mathematical formulation actually solved, including its linearizations and temporal resolution—not automatically to the physical project.
- The most useful audit trail records the candidate domain, constraints, solver or search settings, infeasible designs, and hard dispatch hours.
Write the optimization problem before naming an algorithm
A microgrid optimizer chooses a design vector x—often PV kW, battery kWh, battery kW, generator kW, and sometimes discrete unit counts or controller choices. For each candidate, a chronological dispatch model determines fuel, unmet load, curtailment, storage use, replacement timing, and lifecycle cost.
A useful abstract statement is: minimize NPC(x), subject to hourly energy balance, battery power and SOC bounds, generator limits, and planning constraints such as maximum unmet load or minimum renewable fraction. The objective and constraints define the decision. The search method only determines how candidate solutions are explored.
| Method family | Search action | Legitimate guarantee | Main audit question |
|---|---|---|---|
| Exhaustive sampled grid | Evaluate every combination in a finite declared candidate set. | Lowest objective among feasible evaluated points. | Were the bounds and step sizes wide and fine enough? |
| Derivative-free search | Use objective evaluations to move through a search space without analytic gradients. | Method-specific convergence or stopping result; not automatically a global proof. | Were seeds, starts, bounds, stopping rules, and repeat runs documented? |
| MILP | Solve a linear objective and linear constraints with continuous and integer variables using branch-and-bound/cut methods. | Global optimum of the formulated MILP within the reported solver gap and tolerances. | Do linearization, integer choices, chronology, and solver gap represent the real decision? |
What an exhaustive constraint sweep proves
Suppose the candidate sets contain eight PV sizes, eight battery-energy sizes, and five generator sizes. The coarse search contains 8 × 8 × 5 = 320 designs. If the engine simulates all 320, rejects every design that violates the supported feasibility rules, and sorts the survivors by NPC, the first survivor is provably the least-cost feasible point in that 320-design set.
That last phrase matters. A 175 kW PV point cannot prove that 168.4 kW would not be cheaper if 168.4 kW was never evaluated. A boundary optimum can also indicate that the search ceiling is too low. Grid search is not weak because it is discrete; it is weak only when its domain is hidden or treated as continuous truth.
MicrogridModeler exhaustively evaluates its declared PV × battery-energy × genset grid, then performs deterministic coordinate refinement around the best feasible coarse point. Battery power and optional wind capacity are included in refinement. The incumbent is retained, so refinement cannot worsen the best evaluated NPC. The reported neighborhood spread is a resolution diagnostic, not a formal continuous optimality gap.
- Publish every axis, minimum, maximum, and step or candidate value.
- Report the number evaluated and the number feasible.
- Flag when the best point lands at a search boundary.
- Re-run with expanded bounds and finer steps before treating capacity as decision-grade.
Sources for this section: MicrogridModeler public methodology
Why “HOMER is only heuristic” is inaccurate
HOMER Pro’s current official documentation describes two algorithms. Its original grid search simulates all feasible configurations defined by the search space. HOMER Optimizer uses a proprietary derivative-free algorithm to search for the least-cost system. A fair comparison must name which one is being used.
Derivative-free optimization is useful when the objective is non-smooth, simulation-based, or inconvenient to differentiate. Its existence does not prove a local-optimum failure, and a competitor should not imply one without a controlled benchmark. The right questions are whether bounds, stopping criteria, reproducibility, and repeated-start behavior are available for review.
HOMER also simulates each configuration chronologically and discards infeasible systems under the specified constraints. Therefore the defensible distinction is not “HOMER ignores physics while a modern tool enforces it.” It is which search mode, dispatch rules, constraints, and evidence package best fit the study.
Sources for this section: HOMER Pro: How HOMER Works · HOMER Pro product overview
What MILP global optimality does—and does not—mean
A mixed-integer linear program can combine continuous capacities and dispatch variables with binary decisions such as generator commitment. When every objective term and constraint is linear, a solver can bound the best possible solution and report a relative or absolute optimality gap.
That is a stronger mathematical statement than a finite grid result over unsampled continuous capacities. It is still conditional. Representative days may omit a storage-critical weather sequence. Piecewise-linear efficiency may approximate a nonlinear curve. A single-node formulation may ignore feeder voltage. An optimal answer to the wrong boundary is still the wrong engineering answer.
REopt.jl is a useful public reference because its source exposes a formal optimization model for distributed energy resources. MicrogridModeler currently uses REopt as a cross-check path, while the local engine remains a transparent chronological sampled search. The two are complementary evidence, not interchangeable labels.
Sources for this section: NREL REopt.jl source and model
A five-part audit protocol for any optimizer
Before accepting a least-cost system, reconstruct the claim. The goal is not to demand one universal algorithm; it is to make the result falsifiable and repeatable.
- Freeze the same 8,760 load, resource, component, cost, project-life, and replacement assumptions.
- Write every feasibility constraint and its tolerance, including unmet load, reserve, SOC, and renewable requirements.
- Record the sampled domain or solver formulation, bounds, integer choices, tolerances, stopping rule, and run count.
- Inspect the hours that bind the design: peak net load, minimum SOC, generator start, curtailed energy, and any unmet load.
- Perturb the winning capacity, expand boundaries, and cross-check a small case with an independent engine or hand calculation.
Bottom line: optimize the claim, not the adjective
“Heuristic,” “deterministic,” and “global” are not rankings. They describe different properties. A transparent finite sweep can be excellent for fast, reproducible screening. A derivative-free optimizer can search a difficult simulation efficiently. A MILP can provide a formal solver gap for a carefully linearized planning model.
The citation-worthy answer states the objective, candidate domain or formulation, constraints, chronology, stopping rule, and exact guarantee. That is why MicrogridModeler publishes “best feasible evaluated candidate” instead of claiming an unbounded exact optimum.
Keep exploring
Sources and review notes
This article is grounded in the cited technical sources and the stated modeling assumptions. Recheck project inputs, equipment data, and local requirements before using it for design.
FAQ
Is grid search a global optimization method?
It is globally exhaustive over the finite grid that is actually evaluated. It does not prove the optimum of unsampled continuous capacities unless the decision space is itself restricted to that discrete set.
Does derivative-free optimization always get stuck in a local optimum?
No. “Derivative-free” describes how a method searches without analytic gradients. Global behavior depends on the specific algorithm, bounds, starts, stopping rules, and problem. A failure claim requires a controlled benchmark.
Does MILP guarantee the physically best microgrid?
MILP can prove the best solution to its mathematical formulation within solver tolerances. The physical usefulness still depends on time resolution, linearization, data quality, network scope, and whether the constraints represent the real project.
Interrogate the search yourself
Open a reference project, change a constraint or search bound, and inspect which designs remain feasible.
