The way it's supposed to work is that the hull capacity required by a component is [first value] + [total hull capacity] * [second value]. Note, however, that this is then multiplied by the component capacity reductions you can get from technologies.
One of the first specializations you can get in the weapons branch of the military tree is a 10% reduction in the capacity requirement of all weapons components, and there are additional 20% reductions in capacity requirement available in each weapon family right after the first component unlock specific to that sub-branch; capacity requirement reductions stack additively with one another, so if you have a 10% and a 20% reduction the net effect is a 30% reduction, not a 28% reduction.
If you have the 10% capacity requirement reduction from the first weapons specialization tech and you do not have any direct hull capacity bonuses, then the capacity required for a Laser component with 10 and 0.01 for its HullMassScaleMod ValueParams will require 0.9 * (10 + 0.01 * 25) = 9.225 capacity on a Tiny hull, 9.45 capacity on a Small hull, 9.675 capacity on a Medium hull, 9.9 capacity on a Large hull, and 11.25 capacity on a Huge hull. If you have a 10% hull capacity bonus, the requirements will be 9.2475 on a Tiny, 9.495 on a Small, 9.7425 on a Medium, 9.99 on a Large, and 11.475 on a Huge hull. If you have the 10% and the first 20% capacity requirement reductions and a 10% bonus to hull capacity, those numbers become 7.1925, 7.385, 7.5775, 7.77, and 8.925 for Tiny, Small, Medium, Large, and Huge hulls respectively. Note that the hull capacity required by a component is for some reason rounded or truncated to an integer in the component browser in the ship design screen while the unrounded value is used to compute total hull capacity used.