Click here to Skip to main content
15,895,283 members

Welcome to the Lounge

   

For discussing anything related to a software developer's life but is not for programming questions. Got a programming question?

The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.

 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Joe Woodbury9-Jan-18 14:24
professionalJoe Woodbury9-Jan-18 14:24 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Chris Maunder9-Jan-18 14:31
cofounderChris Maunder9-Jan-18 14:31 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Joe Woodbury9-Jan-18 14:35
professionalJoe Woodbury9-Jan-18 14:35 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
kalberts10-Jan-18 0:00
kalberts10-Jan-18 0:00 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Super Lloyd9-Jan-18 12:50
Super Lloyd9-Jan-18 12:50 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
kalberts9-Jan-18 13:21
kalberts9-Jan-18 13:21 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Chris Maunder9-Jan-18 14:23
cofounderChris Maunder9-Jan-18 14:23 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
kalberts10-Jan-18 0:34
kalberts10-Jan-18 0:34 
Eeeeh...

kW per hour per hour? In which situations does that unit occur?
When does kW per hour occur? A constantly rising (or falling) power, at a rate of x kW/h?
And then you want to a unit for how much, in kW, the power has risen in one hour.
You don't want to simply call it kW, these are not 'absolute' kilowatts, but a change in power, and that is a change per hour over a period of an hour, which is a different kind of kW unit.
Then you want the unit of the increase in power for each minute, right?

You come across the strangest units if you look around Smile | :)
When I was a student, we did some filter calculations where I (after years of wondering) saw how a frequency correction could be given by a time value (European FM pre-emphashis is 50 us, US radios use 75 us - or is it the other way around?), but I never got it under my skin; it is just a strange artifact of unit arithmetics!

If you change that 60 to NumberOfMinutesPerHour, the question is: Are these really the same MinutesPerHour as when you measure 'absolute' time progression? Or, do these MinutesPerHour have a slightly different semantics from the wall clock's minutes per hour (similar to a kW value indicating a change in kiloWattPerHourPerHour is different from an instantaneous, or constant, power kilowatt value)? Maybe it should be called NumberOfMinutesPerHourWhenCalculatingChangesInPowerOverTime?

When we updated our programming guidelines, the project leader of our project immediately granted an exception from the 80 char maximum line length: Our rules for how to construct 'const' names (this was K&R C) led to serveral cases of identifiers of length >80.

Finally, there is the famous Xerox Fortran manual quote:
"The primary purpose of the DATA statement is to give names to constants;
instead of referring to pi as 3.141592653589793 at every appearance, the
variable pi can be given that value with a DATA statement and used instead
of the longer form of the constant. This also simplifies modifying the
program, should the value of pi change."

GeneralRe: MILLISEC_PER_SEC is never needed Pin
Chris Maunder10-Jan-18 8:06
cofounderChris Maunder10-Jan-18 8:06 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
kalberts9-Jan-18 13:23
kalberts9-Jan-18 13:23 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
PIEBALDconsult9-Jan-18 13:28
mvePIEBALDconsult9-Jan-18 13:28 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
kalberts9-Jan-18 13:32
kalberts9-Jan-18 13:32 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
PIEBALDconsult9-Jan-18 13:36
mvePIEBALDconsult9-Jan-18 13:36 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Chris Maunder9-Jan-18 14:24
cofounderChris Maunder9-Jan-18 14:24 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Jörgen Andersson9-Jan-18 21:59
professionalJörgen Andersson9-Jan-18 21:59 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
den2k889-Jan-18 21:23
professionalden2k889-Jan-18 21:23 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
kalberts10-Jan-18 0:52
kalberts10-Jan-18 0:52 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
den2k8810-Jan-18 0:58
professionalden2k8810-Jan-18 0:58 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Dar Brett10-Jan-18 3:11
Dar Brett10-Jan-18 3:11 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
ddyer10-Jan-18 5:36
ddyer10-Jan-18 5:36 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Robert Tax10-Jan-18 5:38
Robert Tax10-Jan-18 5:38 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Davyd McColl10-Jan-18 7:20
Davyd McColl10-Jan-18 7:20 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Gerry Schmitz11-Jan-18 6:05
mveGerry Schmitz11-Jan-18 6:05 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
Member 1215099311-Jan-18 9:34
Member 1215099311-Jan-18 9:34 
GeneralRe: MILLISEC_PER_SEC is never needed Pin
jschell14-Jan-18 5:52
jschell14-Jan-18 5:52 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.