Variants resolve themselves
A car's motor, wheels and battery each come in variants, and you want range, top speed and weight for every combination.
→ Write range = battery.capacity / power_at_speed(speed) once, as if there's one car. Declare the variants separately, where they live. At calculation time the result comes back resolved per configuration, in km — the formula never mentions a variant.