Home технология Time interval

Time interval



Definition

The time that is short to almost zero is called instant, which means instant. The time interval can be regarded as a line segment, which must have a beginning and an end.

Division

The moments are: the beginning of the first few seconds; the end of the first few seconds; the end of the first few seconds; the beginning of the next few seconds.

The time intervals are: within the first few seconds; within a few seconds; within the first few seconds; within the next few seconds; several to several seconds.

Time interval refers to the period of time between two different instants. The kinematics of a point uses the vector radius method, the rectangular coordinate method and the natural method to study the movement of a point with respect to a certain reference system, including the point The equations of motion, trajectories, speeds and accelerations.

Time interval generally corresponds to distance, displacement, and other process quantities.

Function

Algorithm

The following is the .net (C#) time difference algorithm, with relevant instructions.

///

/// Calculate the time interval between two dates /// undefinedundefinedundefinedundefined

description

1.DateTime value The type represents a specific date and time from 0:00:00 on January 1, 0001 AD to 23:59:59 on December 31, 9999 AD. Therefore, you can use the DateTime value type to describe any time within the imaginary range. A DateTime value represents a specific moment

2. The TimeSpan value contains many properties and methods for accessing or processing a TimeSpan value

The following list covers some of them :

Add: Add to another TimeSpan value.

Days: Returns the TimeSpan value calculated in days.

Duration: Get the absolute value of TimeSpan.

Hours: Returns the TimeSpan value calculated in hours

Milliseconds: Returns the TimeSpan value calculated in milliseconds.

Minutes: Returns the TimeSpan value calculated in minutes.

Negate: Returns the opposite of the current instance.

Seconds: Returns the TimeSpan value calculated in seconds.

Subtract: Subtract another TimeSpan value from it.

Ticks: Returns the number of ticks of the TimeSpan value.

TotalDays: Returns the number of days represented by the TimeSpan value.

TotalHours: Returns the number of hours represented by the TimeSpan value.

TotalMilliseconds: Returns the number of milliseconds represented by the TimeSpan value.

TotalMinutes: Returns the number of minutes represented by the TimeSpan value.

TotalSeconds: Returns the number of seconds represented by the TimeSpan value.

This article is from the network, does not represent the position of this station. Please indicate the origin of reprint
TOP