+ Reply to Thread
Results 1 to 57 of 57

Concerting Time to Degrees

  1. #1
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Concerting Time to Degrees

    Hi Everyone,

    How would someone go about converting time to degrees automatically in excel 2019?

    I have attached a file of what I am trying to do automatically.
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    18:00:00 CANNOT be both 0 and 360 ...

    What about 17:00 and 19:00???
    Last edited by AliGW; 01-10-2024 at 07:51 AM.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Please try in B2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by AliGW View Post
    18:00:00 CANNOT be both 0 and 360 ...
    Thanks for pointing that out.........we are no closer to a solution

  5. #5
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by HansDouwe View Post
    Please try in B2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    WORKED PERFECT!

    You are brilliant!

    The people on this website are the best people on the www!

  6. #6
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Is there a degrees format in excel?
    Last edited by AliGW; 01-10-2024 at 08:00 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  7. #7
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    Set a custom format:

    0"°"

    Or change the formula:

    =MOD((A2-TIME(18,0,0)),1)*360&"°"

    EDIT: ° is ALT+0176 on the numeric keypad.

    Are we any closer to a solution now???
    Attached Files Attached Files

  8. #8
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Also custom formatting without "" does the job: (only 0°)

    Note: ° = Press ALT and type 0176

  9. #9
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    Yes, you're right, Hans.

  10. #10
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    It works in the excel spreadsheet you gave me

    when I try to hold the the "alt" key and type in "0176" or "+0176" I can't do it on my own

    I can copy and paste between spreadsheets and it works

    wonder why it isn't working on my own
    Last edited by AliGW; 01-10-2024 at 08:26 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  11. #11
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    I don't have round numbers for the time most of the time and it's giving me a long decimal

    The round function isn't working

    See attached file
    Attached Files Attached Files

  12. #12
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    You need to make sure that the numeric keypad (NumLock) is set to ON.

    ROUND works fine:

    =ROUND(MOD((A2-TIME(18,0,0)),1)*360,0)&"°"
    Attached Files Attached Files

  13. #13
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    BEAUTIFULLLLLLLLLLLLLLLLL

    I had the ",1" in the wrong place
    Last edited by AliGW; 01-10-2024 at 08:30 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  14. #14
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    Glad to have helped.

    If that takes care of your original question, please choose Thread Tools from the menu link above and mark this thread as SOLVED.

    Also, if you have not already done so, you may not be aware that you can thank anyone who offered you help towards a solution for your issue by clicking the small star icon (* Add Reputation) located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of each of those who offered help.

  15. #15
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Thanks...I hope everyone got my add reputation I did
    Last edited by AliGW; 01-10-2024 at 09:04 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  16. #16
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    I can't do it on my own
    May be you are using a MAC? ALT0176 works only on Windows.

    Thanks for the feedback and rep . Glad to have helped.

  17. #17
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    If the OP is on a Mac, then their profile should show this (e.g. 2019 Mac).

  18. #18
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    I am using windows no idea why it's working over there and not over here.

    Ok I have another issue to solve. So I added another column and the purpose is to divide the week into degrees as well.
    I plan to do it with the month and year as well.......but one thing at a time

    I made a couple attempts to manipulate the formula. Namely changing the time value from 18 to 90 that didn't work, dividing by 5 that only works for a day.
    The column H should get the data from column D that is the complete date and time of the year.

    Here is the math for column H

    COLUMN H:
    1 WEEK
    5 DAYS PER WEEK
    24 HOURS PER DAY
    60 MIN PER HOUR

    360 DEGREES PER WEEK

    0.05 DEGREES PER MINUTE
    3 DEGREES PER HOUR
    72 DEGREES PER DAY
    360 DEGREES PER WEEK

    Any help would be appreciated

    I have attached the file of my attempt

    Thanks,

    Ivan
    Attached Files Attached Files

  19. #19
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    This would involve converting the date to a number, then getting the start date of the year week to be zero and Friday at 6:00 pm to be 360

  20. #20
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Thanks for the feedback and reputation, glad to have helped. .

    If you want 72 degrees per day, startting with date A2 and time C2:

    Please try this and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    But if you start Monday 6:00 PM with 0°, then you will reach 360° on Saturday, because Saturday is 360/72 = 5 days after Monday.

    If you want reach 360° on Friday, you should replace in the formula 72 with 90 (90 = 360/4), because Friday is 4 days after Monday.
    Attached Files Attached Files

  21. #21
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by HansDouwe View Post
    Thanks for the feedback and reputation, glad to have helped. .

    If you want 72 degrees per day, startting with date A2 and time C2:

    Please try this and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    But if you start Monday 6:00 PM with 0°, then you will reach 360° on Saturday, because Saturday is 360/72 = 5 days after Monday.

    If you want reach 360° on Friday, you should replace in the formula 72 with 90 (90 = 360/4), because Friday is 4 days after Monday.
    No problem thanks for the help.

    Ok so we need to explain a little bit more here what's going on this kind of works but it only worked for the first week then the degrees keep going higher instead of resetting after a week.

    So I am trying to do this for the day, week, month, year

    column G "IDEG" works perfect the day's start at 6:00 pm est and that is 0 degrees and they end at 5:00 pm est which is 345 degs and they start again at 0 degrees so this works perfect
    column H "WDEG" is a week which is 360 degrees and it starts sunday at 6:00 pm and ends Friday at 5:00 pm which is 345 degrees, then resets to 0 degrees every sunday
    column I "MDEG" is a month which is 360 degrees and it starts on 6:00 pm on the first of the month and ends at 6:00 pm the last day of the month, it should reset to 0 degrees every month
    column J "YDEG" is a year which is 360 degrees and it starts on 6:00 pm on the first day of the year and ends at 6:00 pm the last day of the year, so the sheet should go from 0 to 360 the entire year and then reset the next year

    I have attached a spreadsheet with more than a months data in a new column IDATA (2)

    I hope I am starting the problem clearly? I can further elaborate if needed.
    Attached Files Attached Files
    Last edited by HajdukZD; 01-14-2024 at 07:27 PM.

  22. #22
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    The day ends at 5:59:59.99... PM which is 359.99.. degrees.
    I say for convenience. The day ends at 6 PM which is 360 degrees.

    The week ends Friday at 5:00 pm which is 345 degrees
    . Why does the week not ends at Friday 6 PM which is 360 degrees?
    In that case Friday 5:00 PM is 357 degrees (not 345 degrees), because than we should counting 3 degrees pro hour,


    the week starts at Sunday 6:00 pm
    So Monday 6:00 PM is 72 degrees. Is that OK?


    The month starts on 6:00 pm on the first of the month and ends at 6:00 pm the last day of the month
    What should the month formula return between the last day of the month 6:00 PM and the first day of the next month 6:00 PM?
    For example The first day of the month at 9:00 AM.

    Not every month is counting in the degrees in the same speed, because not every month has the same length.
    Is that OK?

    Not every year is counting the degrees in the same speed, because not every year has the same length.
    [A leap year is 366 days and other years are 365 days]
    Is that OK.

    What should the year formula return between the last day of the year 6:00 PM and the first day of the next year 6:00 PM?

    What should the week formula return between Friday 6 PM and Sunday 6 PM?
    Last edited by HansDouwe; 01-14-2024 at 08:50 PM.

  23. #23
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by HansDouwe View Post
    The day ends at 5:59:59.99... PM which is 359.99.. degrees.
    I say for convenience. The day ends at 6 PM which is 360 degrees.

    . Why does the week not ends at Friday 6 PM which is 360 degrees?

    Yes the above is true 6:00 pm is 360 degrees.......
    In that case Friday 5:00 PM is 357 degrees (not 345 degrees), because than we should counting 3 degrees pro hour,


    So Monday 6:00 PM is 72 degrees. Is that OK? Yes this is ok.

    Yes we are dividing 6:00 pm on sunday until 5:00 pm on Friday.......but we can simpify to 6:00 pm Friday...120 hours is.......and that is 360 degrees........yes 3 degrees per hour

    We shoudl be able to easliy change it to 119 hours if we want to?



    What should the month formula return between the last day of the month 6:00 PM and the first day of the next month 6:00 PM?
    For example The first day of the month at 9:00 AM. I think we should just do the first day of the month at 6:00 pm to make it simpler. It's not going to matter much.

    Not every month is counting in the degrees in the same speed, because not every month has the same length.
    Is that OK? Yes this is ok and expected.

    Not every year is counting the degrees in the same speed, because not every year has the same length.
    [A leap year is 366 days and other years are 365 days]
    Is that OK. no the number of weeks in a year do not change, and we are basing this calculation off of a 5 day week.

    What should the year formula return between the last day of the year 6:00 PM and the first day of the next year 6:00 PM?
    The 5 day weeks in a normal year is 261 so the deg/day is 1.37931
    The 5 day weeks in a leap year is 262 so the deg/day is 1.474046
    neither of these are correct there are 52 weeks in a year and each week has 5 weeks for this calculation
    so 52 * 5 = 260......1/384615 degs per day
    on the leap year there is just an extra Saturday


    Let's do for the year the first day of the year at 6:00 pm to the last day of the year at 6:00 pm. this is 360 degrees.


    What should the week formula return between Friday 6 PM and Sunday 6 PM?
    Friday 6 pm = 360
    Sunday 6 pm = 0

    Did I answer everything correctly?
    The only one that varies is the month......they are differnt lengths
    days, weeks, year is the same length

  24. #24
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Thanks for the answers:

    The month formula ends also at the first day of the month 6:00 PM. That is 360 degrees.
    OK I understand. So if the month has 30 days the formula should counting 360/30 is 12 degrees each day.
    That is easy.

    But I don't understand the annual calculation. In the first place, a leap year can also include an extra working day. That depends on what the first day of the leap year is.
    2024 has 53 Mondays, 53 Tuesdays, 52 Wednesdays, 52 Thursdays and 52 Fridays. Total is 262.

    In addition, I don't understand your year calculation over the working days. Could you give an example of what the annual formula should indicate this year on Monday, January 1st 6 PM, Friday, January 5th 6 PM, Sunday January 7th 6 PM, Friday January 12th 6 PM and Sunday January 14th 6 PM?

    And what should the week formula return between Friday 6 PM and Sunday 6 PM?
    Last edited by HansDouwe; 01-14-2024 at 10:37 PM.

  25. #25
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by HansDouwe View Post
    Thanks for the answers:

    The month formula ends also at the first day of the month 6:00 PM. That is 360 degrees.
    OK I understand. So if the month has 30 days the formula should counting 360/30 is 12 degrees each day.
    That is easy.

    But I don't understand the annual calculation. In the first place, a leap year can also include an extra working day. That depends on what the first day of the leap year is.

    In addition, I don't understand your year calculation over the working days. Could you give an example of what the annual formula should indicate this year on Monday, January 1st 6 PM, Friday, January 5th 6 PM, Sunday January 7th 6 PM, Friday January 12th 6 PM and Sunday January 14th 6 PM?
    Yeah you are right the leap year can start and end in the middle of the week so we would have extra working days.
    Monday, January 1st 6 PM - 0 degrees
    Friday, January 5th 6 PM - 4.918033 degrees
    Sunday January 7th 6 PM - 4.918033 degrees
    Friday January 12th 6 PM - 9.836066 degrees
    Sunday January 14th 6 PM - 9.836066 degrees

    These are like the 0/360 for the days when it hits 6PM it is 0 and 360
    Same for the weeks

    And what should the week formula return between Friday 6 PM and Sunday 6 PM?
    The formula should ignore the time between Friday 6PM and Sunday 6PM.
    It should return nothing since that's how the data is structured in the excel spreadsheet.
    Last edited by HajdukZD; 01-14-2024 at 10:44 PM.

  26. #26
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    I believe my math is correct.....let's see

  27. #27
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    OK, you don't have times between friday 6 PM and Sunday 6 PM in your sheet. Right?

    Could you also answer my questions about the annual formula?

  28. #28
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    I don't understand why you count the same degrees for the first week as for the second week.
    The first week only has 4 days (no Sunday on Monday), the second week has 5 days.

    In addition, you now count 360/365 degrees per working day. This means you only end up at 256 degrees after 52 weeks.

    Now that you want to stop the degrees clock for 48 hours every week for the annual formula, it is better to make the formula such that we end up at 360 degrees exactly on the last working day of the year at 6 PM. Regardless of whether it is a leap year or not. A year can contain 260, 261 or 262 working days, but if I have to count from January 1, 6:00 PM to December 31, 6:00 PM, that is 364 days in a regular year or 365 days in a leap year. And those years can contain 260 or 261 working days (depending on the day the year begins.) Is that OK?

    Should the monthly clock run during the weekends or should it also run faster during the week, so that it can be stopped during the weekend?
    Last edited by HansDouwe; 01-15-2024 at 01:36 AM.

  29. #29
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    I was still thinking about the monthly clock and the yearly clock.
    The weekly clock lets you start at 6 PM for the first working day of the week and end up at 6 PM on Friday exactly 5 days later.

    Then it also seems logical to me to have the monthly clock start at 6 PM of the last day of the previous month (and to run until 6 PM of the last (working) day of the month.
    The same for the annual clock.

    How do you think you about that?
    Last edited by HansDouwe; 01-15-2024 at 01:42 AM.

  30. #30
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by HansDouwe View Post
    I don't understand why you count the same degrees for the first week as for the second week.
    The first week only has 4 days (no Sunday on Monday), the second week has 5 days.

    This is just the way my data is in this spreadsheet, the year started on a monday, but it should not change the weekly degrees.
    The daily and weekly degrees are always the same, 24 horus in a day = 360 degrees, 5 days in a week = 360 degrees
    The monthly and daily have some variance

    In addition, you now count 360/365 degrees per working day. This means you only end up at 256 degrees after 52 weeks.

    Now that you want to stop the degrees clock for 48 hours every week for the annual formula, it is better to make the formula such that we end up at 360 degrees exactly on the last working day of the year at 6 PM. Regardless of whether it is a leap year or not. A year can contain 260, 261 or 262 working days, but if I have to count from January 1, 6:00 PM to December 31, 6:00 PM, that is 364 days in a regular year or 365 days in a leap year. And those years can contain 260 or 261 working days (depending on the day the year begins.) Is that OK? this appears ok

    Should the monthly clock run during the weekends or should it also run faster during the week, so that it can be stopped during the weekend?
    The monthly clock should stop during the weekends, we only want the monthly clock to run during working days, from 6:00 pm sunday to 6:00 pm Friday
    same with the yearly clcok

  31. #31
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by HansDouwe View Post
    I was still thinking about the monthly clock and the yearly clock.
    The weekly clock lets you start at 6 PM for the first working day of the week and end up at 6 PM on Friday exactly 5 days later.

    Then it also seems logical to me to have the monthly clock start at 6 PM of the last day of the previous month (and to run until 6 PM of the last (working) day of the month.
    The same for the annual clock.

    How do you think you about that?
    I agree with you here.
    I am racking my brain on this one it's harder than I thiought
    If we can get the degrees from column D that would be the best and the formula for column D is column A+column C

  32. #32
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Custom format cells 0° or 0.00°

    IDEG: Day = 18:00:00 - 18:00:00 Please try:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    WDEG: Week = SUN 18:00:00 - FRI 18:00:00:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    MDEG: Month = last day previous month 18:00:00 - last day month 18:00:00 (and does not count FRI 18:00:00 - SUN 18:00:00):
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    YDEG: Year = last day previous year 18:00:00 - last day year 18:00:00 (and does not count FRI 18:00:00 - SUN 18:00:00):
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by HansDouwe; 01-16-2024 at 05:30 AM.

  33. #33
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    WOW this is a great attempt! I am trying to get the logic of the formulas.

    Unfortunately the WDEG isn't working it goes until 522 degrees then resets, the deg count should reset at sunday at 6:00 pm = 0 deg

    The MDEG and YDEG are giving me errors my excel 2019 doesn't like the formula #NAME?

    I will play around a little bit see if I an fix it ............WOW you did great with these formulas
    Attached Images Attached Images
    Last edited by AliGW; 01-16-2024 at 12:23 PM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  34. #34
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    The MDEG and YDEG are giving me errors my excel 2019 doesn't like the formula #NAME?
    LET is only available in 2021 and 365.

    Try:

    =(NETWORKDAYS(1+EOMONTH(D2+1/4,-1),D2+1/4)-1+MOD(D2+1/4,1))/NETWORKDAYS(1+EOMONTH(D2+1/4,-1),EOMONTH(D2+1/4,0))*360

    and:

    =(NETWORKDAYS(1+EOMONTH(D2+1/4,-1),D2+1/4)-1+MOD(D2+1/4,1))/NETWORKDAYS(1+EOMONTH(D2+1/4,-MONTH(D2+1/4)),EOMONTH(D2+1/4,12-MONTH(D2+1/4)))*360
    Last edited by AliGW; 01-16-2024 at 12:27 PM.

  35. #35
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Excel is giving me this for the MDEG
    =_xlfn.LET(_xlpm.t,D2+1/4,(NETWORKDAYS(1+EOMONTH(_xlpm.t,-1),_xlpm.t)-1+MOD(_xlpm.t,1))/NETWORKDAYS(1+EOMONTH(_xlpm.t,-1),EOMONTH(_xlpm.t,0))*360)
    And this for the YDEG
    =_xlfn.LET(_xlpm.t,D2+1/4,(NETWORKDAYS(1+EOMONTH(_xlpm.t,-1),_xlpm.t)-1+MOD(_xlpm.t,1))/NETWORKDAYS(1+EOMONTH(_xlpm.t,-MONTH(_xlpm.t)),EOMONTH(_xlpm.t,12-MONTH(_xlpm.t)))*360)

    It looks like certain forumals aren't available in this version of excel

    It looks like it's the LET function and t funciton I will test it out more

  36. #36
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    See post #34!!!

  37. #37
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    WOW this formula works...........wow great job!

    Our math is wrong somewhere.........we get errors in the degrees see attached spreadsheet.......I have to think about this a while .......we may want the month and years to begin at midnight and the day and week to start at sunday at 6:00 pm......I think this will clear up the errors.........
    This is it we need the month and year degs to start at midnight.......
    the day and week degrees have to start sunday at 6:00 pm and end friday at 6:00 pm.
    So the day degrees work with the current formula
    the week degrees don't work it doesn't reset properly
    the monthly and yearly degrees have to start at midnight and end at midnight........


    WE ARE SOOOOO CLOSEEEEEEE

    please see attached spreadsheet
    Attached Files Attached Files
    Last edited by AliGW; 01-16-2024 at 12:50 PM.

  38. #38
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    I can't help with the maths - sorry.

  39. #39
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Quote Originally Posted by AliGW View Post
    I can't help with the maths - sorry.
    You helped plenty thank you so much!

  40. #40
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Thanks for the feed back and rep . Glad to have helped.

    Now de finishing touche,

    the monthly and yearly degrees have to start at midnight and end at midnight........
    OK. Does this rule still apply?
    The monthly clock should stop during the weekends, we only want the monthly clock to run during working days, from 6:00 pm Sunday to 6:00 pm Friday
    The error in the weekly clock on Sunday evening is clear to me and I will correct it.

  41. #41
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Yes the monthlyl close should stop on weekends..........so it should run from Midnight on the 1st until Friday 6:00 pm, then pause and start up again on Sunday 6:00 pm, and run until midnight on the last day of the month
    same with the yearly, it should start on Midnight on the 1st, and run until Friday 6 pm, then pause until sunday 6:00 pm before resuming.
    Thsi was my mistake on the math at the beginning......AliGWs equations work over here
    Last edited by AliGW; 01-17-2024 at 02:50 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  42. #42
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    OK. The requirements are clear to me. I'll fix that Wednesday night.

  43. #43
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    I am exciteddddddddddddddddddddddddddd
    Last edited by AliGW; 01-18-2024 at 09:19 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  44. #44
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    Here are the new formulas belonging to these conditions:

    IDEG: Day = 18:00:00 - 18:00:00

    WDEG: Week = SUN 18:00:00 - FRI 18:00:00

    MDEG: Month = first day month 00:00:00 - last day month 24:00:00
    (and does not count FRI 18:00:00 - SUN 18:00:00

    YDEG: Year = first day year 00:00:00 - last day year 24:00:00
    (and does not count FRI 18:00:00 - SUN 18:00:00)

    IDEG: No change
    WDEG: Please try:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    MDEG: Please try:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    `
    YDEG: Please try:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by HansDouwe; 01-17-2024 at 11:32 PM.

  45. #45
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    The weekly function is working!!!! perfectly as well

    however my version of excel doesn't let me use the "LET" function
    here are the formulas that ALIGW gave but that do not reset properky
    MDEG
    =(NETWORKDAYS(1+EOMONTH(D2+1/4,-1),D2+1/4)-1+MOD(D2+1/4,1))/NETWORKDAYS(1+EOMONTH(D2+1/4,-1),EOMONTH(D2+1/4,0))*360
    YDEG
    =(NETWORKDAYS(1+EOMONTH(D2+1/4,-1),D2+1/4)-1+MOD(D2+1/4,1))/NETWORKDAYS(1+EOMONTH(D2+1/4,-MONTH(D2+1/4)),EOMONTH(D2+1/4,12-MONTH(D2+1/4)))*360

    I will try to take a look to see if I can modify the formulas to work in excel 2019.......

    But yesssssss the WDEGs work! Halfway done!

    Thank you!!!
    Last edited by AliGW; 01-18-2024 at 09:20 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  46. #46
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    2019 does not have LET, as I noted in post #34.

    Administrative Note re. Forum Guideline #2:

    Please don't quote whole posts,
    especially when you are responding to the one immediately preceding your own - it's just clutter and rarely necessary.

    If you are responding out of sequence, it is usually enough just to mention the helper's user name (e.g @AliGW).

    If you do need to quote, limit the quoted section just to the section to which you wish to draw your helper's attention or a direct question to which you wish to respond.

    For normal conversational replies, try using the QUICK REPLY box below or the REPLY button instead of REPLY WITH QUOTE.

  47. #47
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    The last post wasn't a quote so I don't know what is this post about

  48. #48
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,914

    Re: Concerting Time to Degrees

    It doesn't need a quote as it was referring to YOUR post immediately before it (post #45), where you had unnecessarily quoted the whole of post #44. I have removed some of the unnecessary quoting in this thread.

    Once again, if you are answering the post immediately BEFORE your own, there is NO NEED AT ALL to quote it.

  49. #49
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    These formulas without LET works in Excel 2019:

    MDEG Please try:
    Please Login or Register  to view this content.
    YDEG Please try:
    Please Login or Register  to view this content.
    Attached Files Attached Files

  50. #50
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    This is very accurate.......this is close enough to work.......the first month starts at 12 deg but should start at 0 deg but that corrects itself in the second month.
    Can we get the first month to start at 0 deg?
    6 hours doesn't matter much over the year specially with the rounding.

    Can we add in a column for the quarters? So there would be 360 degrees every 3 months?

    But thank you!!!

  51. #51
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    The first of the month MDEG also starts at 0 degrees.
    The MDEG rule is:
    first day month 00:00:00 - last day month 24:00:00
    (and does not count FRI 18:00:00 - SUN 18:00:00).
    January 1, 2024 is a Monday and the MDEG of Monday January 1, 2024 0:00 returns 0 degrees.

    Your table does not start Monday January 1, 2024 0:00, but your table start Monday January 1, 2024 18:00
    Last edited by HansDouwe; 01-20-2024 at 03:20 AM.

  52. #52
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Yeah you are right 18 hours is 12 degrees...............

    Can we add in a quarterly clock? Where we divide the year up in quarters so every 3 months?

    3 months = 360 degrees. There would be 4 of them every year.

    I attached the spreadsheet and added the column in
    Attached Files Attached Files
    Last edited by HajdukZD; 01-20-2024 at 10:17 AM.

  53. #53
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    Hi can someone (Hans!) help me covert the QDEG column into degrees?

    I believe I was able to calculate the time passed in the quarter and it should reset every quarter.

    Please see the attached file.

    Thanks in advance
    Attached Files Attached Files

  54. #54
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    This equation kind of does it but it isn't correct it's a continuous clock

    =IF(MONTH(A1)<=3, ((A1-DATE(YEAR(A1),1,1))/90)*360, IF(MONTH(A1)<=6, ((A1-DATE(YEAR(A1),4,1))/91)*360, IF(MONTH(A1)<=9, ((A1-DATE(YEAR(A1),7,1))/92)*360, ((A1-DATE(YEAR(A1),10,1))/92)*360)))

  55. #55
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,433

    Re: Concerting Time to Degrees

    QDEG:

    Please try:
    Please Login or Register  to view this content.
    Attached Files Attached Files

  56. #56
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    thank you sir will check it out

  57. #57
    Registered User
    Join Date
    10-15-2023
    Location
    New York, New York
    MS-Off Ver
    2019
    Posts
    88

    Re: Concerting Time to Degrees

    seems to work I tried to give you some more reputation it's not letting me ..............thanks again!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] How to Convert DD (Decimal Degrees) to DMS (Degrees Minutes Seconds) in Excel via Function
    By Reahmatullah Ktk in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 04-07-2022, 04:28 PM
  2. Best way to convert Degrees Minutes and Seconds to Decimal of Degrees (and Vice Versa)
    By Aussie_Student in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 08-05-2017, 02:12 AM
  3. Replies: 4
    Last Post: 07-26-2016, 09:06 AM
  4. [SOLVED] convert decimal degrees to degrees minutes seconds
    By Chris r in forum Excel General
    Replies: 6
    Last Post: 12-06-2013, 06:24 AM
  5. Replies: 2
    Last Post: 05-04-2013, 07:33 AM
  6. Replies: 4
    Last Post: 09-13-2012, 11:21 AM
  7. Converting Lat/Long (Degrees Minutes Seconds) to Decimal Degrees
    By Jeremy Rayne in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-24-2008, 06:02 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1