The Origin Forum
File Exchange
Try Origin for Free
The Origin Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ | Send File to Tech support
Username:
Password:
Save Password
Forgot your Password? | Admin Options

 All Forums
 Origin Forum
 Origin Forum
 Convert IRIG-Format into Date
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic

fabif

Germany
12 Posts

Posted - 04/15/2013 :  11:02:07 AM  Show Profile  Edit Topic  Reply with Quote  View user's IP address  Delete Topic
My ASCII Files are using the format DDD:hh:mm:ss.
I want to split this IRIG Format and copy the DDD in a new column and a new format like dd.mm.yyyy (e.g. 06/12/1998).

Someone an idea?
Thanks in advance!



Origin Ver. and Service Release (Select Help-->About Origin): 8G
Operating System: Windows 7

greg

USA
1379 Posts

Posted - 04/15/2013 :  12:11:47 PM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
IRIG is a relative Time format, meaning there is no Date information and the underlying data stores Day information as the integer part and time of day as the fractional part as in:
3.1415926535898 = 3days, 3 hours, 23 minutes and 53.605270158 seconds
Given columns that are set as Time or Date, you can freely add Time columns to each other and still get 'time' values and you can freely add a Date and a Time column and still get date values. (Just don't add Date columns!)
So if you fill a column with one particular date and have set that as a Date column, then you can just add your IRIG column to your Date column to make all your IRIG values relative to that Date.
Go to Top of Page

abhishek.khare

United Arab Emirates
9 Posts

Posted - 05/16/2023 :  09:20:26 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Hello there,
I have similar question.
How can I convert IRIG time to seconds?
Thank you in advance.
Regards
Abhishek
Go to Top of Page

YimingChen

1651 Posts

Posted - 05/16/2023 :  10:44:06 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
You can multiply the IRIG time value by 24*60*60.

quote:
Originally posted by abhishek.khare

Hello there,
I have similar question.
How can I convert IRIG time to seconds?
Thank you in advance.
Regards
Abhishek

Go to Top of Page

abhishek.khare

United Arab Emirates
9 Posts

Posted - 05/17/2023 :  12:58:00 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
Thank you Chen, much appreciated.
Another question, if I may ask, how to remove day number from
the IRIG time and have only hh:mm:ss.##?

quote:
Originally posted by YimingChen

You can multiply the IRIG time value by 24*60*60.

quote:
Originally posted by abhishek.khare

Hello there,
I have similar question.
How can I convert IRIG time to seconds?
Thank you in advance.
Regards
Abhishek



Go to Top of Page

YimingChen

1651 Posts

Posted - 05/17/2023 :  09:37:23 AM  Show Profile  Edit Reply  Reply with Quote  View user's IP address  Delete Reply
As the date is simply the integer part of the time value. You may just take the real modulus of the time divided by 1. See below:



James
Go to Top of Page
  Previous Topic Topic Next Topic Lock Topic Edit Topic Delete Topic New Topic Reply to Topic
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
The Origin Forum © 2020 Originlab Corporation Go To Top Of Page
Snitz Forums 2000