> Hello, in real world this is sooo easy: > > h = 105,5 mm > w = h *0.36 > > In groff world 105.5 and 0.36 needs to come in centimeters, > then some correction needs to be applied.
Well, in the simple case above, 0.36 does *not* need to come in centimeters. It is a simple numerical factor. The "h" already contains the centimeters. So the solution would be .nr h 10.55c .nr w \nh*36/100 .\" .tm \nh \nw In general: multiply first, then divide. If you get an overflow, multiply in smaller pieces and add the results (0.36 = 3/10 + 6/100). For example: .nr w (\nh*3/10)+(\nh*6/100)