<?xml version="1.0" encoding="US-ASCII"?>
<!-- This is built from a template for a generic Internet Draft. Suggestions for
     improvement welcome - write to Brian Carpenter, brian.e.carpenter @ gmail.com 
     This can be converted using the Web service at http://xml.resource.org/ -->
<!DOCTYPE rfc SYSTEM "rfc2629.dtd">
<!-- You want a table of contents -->
<!-- Use symbolic labels for references -->
<!-- This sorts the references -->
<!-- Change to "yes" if someone has disclosed IPR for the draft -->
<!-- This defines the specific filename and version number of your draft (and inserts the appropriate IETF boilerplate -->
<?rfc sortrefs="yes"?>
<?rfc toc="yes"?>
<?rfc symrefs="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>
<?rfc topblock="yes"?>
<?rfc comments="no"?>
<rfc category="info" docName="draft-yz-nmrg-dtn-flow-simulation-01"
     ipr="trust200902">
  <front>
    <title abbrev="Digital Twin Network">Digital Twin Network Flow
    Simulation</title>

    <author fullname="Hongwei Yang" initials="H." surname="Yang">
      <organization>China Mobile</organization>

      <address>
        <postal>
          <street/>

          <city>Beijing</city>

          <code>100053</code>

          <country>China</country>
        </postal>

        <email>yanghongwei@chinamobile.com</email>
      </address>
    </author>

    <author fullname="Cheng Zhou" initials="C." surname="Zhou">
      <organization>China Mobile</organization>

      <address>
        <postal>
          <street/>

          <city>Beijing</city>

          <code>100053</code>

          <country>China</country>
        </postal>

        <email>zhouchengyjy@chinamobile.com</email>
      </address>
    </author>

    <date day="21" month="October" year="2022"/>

    <area>Networking</area>

    <workgroup>Internet Research Task Force</workgroup>

    <keyword>Digtial Twin; Digital Twin Network; Flow Simulation</keyword>

    <abstract>
      <t>Some important application scenarios of digital twin network, such as
      network new technology experiment, network configuration verification,
      network performance optimization, etc., all require the virtual traffic
      in the twin network to accurately simulate the real traffic in the
      physical network.The real traffic in the physical network is called the
      physical traffic, and the virtual traffic in the twin network is called
      the twin traffic. In order to realize the high-fidelity simulation of
      the physical traffic by the twin traffic, this paper proposes that the
      twin traffic and the physical traffic should satisfy three consistent
      characteristics, and an implementation method of twin flow is
      introduced.</t>
    </abstract>
  </front>

  <middle>
    <section anchor="intro" title="Introduction">
      <t>Digital twin network is a virtual representation of the physical
      network. Such virtual representation of the network is meant to be used
      to analyze, diagnose, emulate, and then control the physical network
      based on data, models, and interfaces. The DTN architecture diagram is
      shown in Figure 1.</t>

      <figure align="center"
              title="Figure1:Reference Architecture of Digital Twin Network">
        <artwork align="center">+---------------------------------------------------------+
|   +-------+   +-------+          +-------+              |
|   | App 1 |   | App 2 |   ...    | App n |   Application|
|   +-------+   +-------+          +-------+              |
+-------------^-------------------+-----------------------+
              |Capability Exposure| Intent Input
              |                   | 
+-------------+-------------------v-----------------------+
|                        Instance of Digital Twin Network |
|  +--------+   +------------------------+   +--------+   |
|  |        |   | Service Mapping Models |   |        |   |
|  |        |   |  +------------------+  |   |        |   |
|  | Data   +---&gt;  |Functional Models |  +---&gt; Digital|   |
|  | Repo-  |   |  +-----+-----^------+  |   | Twin   |   |
|  | sitory |   |        |     |         |   | Network|   |
|  |        |   |  +-----v-----+------+  |   |  Mgmt  |   |
|  |        &lt;---+  |  Basic Models    |  &lt;---+        |   |
|  |        |   |  +------------------+  |   |        |   |
|  +--------+   +------------------------+   +--------+   |
+--------^----------------------------+-------------------+
         |                            |
         | data collection            | control
+--------+----------------------------v-------------------+
|                   Physical Network                      |
|                                                         |
+---------------------------------------------------------+</artwork>
      </figure>

      <t>The digital twin layer forms a network element model by modeling
      physical network elements, and the network element model forms a twin
      network element through instantiation, that is, each physical network
      element in the physical network has a corresponding twin network element
      in the digital twin layer. Similarly, each physical flow of the physical
      network also has a corresponding twin flow at the digital twin
      layer.</t>

      <t>Through the real-time data interaction between the physical network
      and the twin network, the physical network elements, network topology,
      network traffic, network status and other data in the physical network
      are virtualized at the twin network layer. The topology of the physical
      network and the twin network are consistent, The number of NEs is the
      same, and the traffic information is the same.</t>
    </section>

    <section title="Conventions Used in This Document">
      <section title="Terminology">
        <t>DTN Digital Twin Network</t>
      </section>

      <section title="Requirements Language">
        <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
        "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
        "OPTIONAL" in this document are to be interpreted as described in BCP
        14<xref target="RFC2119"/><xref target="RFC8174"/> when, and only
        when, they appear in all capitals, as shown here.</t>
      </section>
    </section>

    <section title="Key characteristics of DTN flow">
      <t>The twin network layer needs to accurately simulate the traffic of
      the physical network to support the normal operation of the network
      application layer.The twin traffic of the twin network layer and the
      physical traffic of the physical network need to satisfy the following
      three characteristics at the same time.</t>

      <t>1) The two traffic forwarding paths are consistent, that is, the twin
      nodes that twin traffic passes through at the twin network layer are
      consistent with the physical nodes that physical traffic passes through
      at the physical network layer;</t>

      <t>2) The network performance of the two types of traffic is consistent,
      that is, the twin traffic and the physical traffic have the same
      performance as network delay, packet loss, and jitter;</t>

      <t>3) The two traffic data characteristics are consistent, that is, the
      data packets of twin traffic and physical traffic have the same key
      characteristics such as traffic rate, quintuple information, data packet
      length, and data packet priority;</t>
    </section>

    <section title="DTN flow implementation method">
      <t>If the twin flow and physical flow are to meet the above three
      characteristics, three problems need to be solved:</t>

      <t>1) The physical network element and the twin network element have
      unique identifiers in the entire network, so as to realize the mutual
      correspondence between the two. The physical traffic passes through
      those physical network elements, and the twin traffic also passes
      through the corresponding twin network element, so as to achieve the
      same forwarding path;</t>

      <t>2) The physical flow is uniformly collected and managed by the Data
      Repository of the twin network layer, and then distributed to each twin
      network element. Because the time for each physical network element to
      complete data collection and data transmission is inconsistent, in order
      to ensure that the twin flow and physical flow have the same performance
      as forwarding delay, packet loss, and jitter, the twin flow must be
      delayed by a fixed time. That is, the twin flow delays the physical flow
      by a fixed time.</t>

      <t>3) The flow data collected by the Data Repository should include the
      key information of physical flow, so that the twin flow and physical
      flow data characteristics are consistent; when the Data Repository
      collects physical flow, it can be collected in full package by package
      or partially collected at a certain sampling rate;</t>

      <figure align="center" title="Figure 2: Twin Flow and Physical Flow">
        <artwork type="ascii-art" xml:space="preserve">  +--------------------------------------------------------------+
  | Digital Twin Network            +----------+                 |
  |                       +---------+ Twin NE 3+----------+      |
  |                       |         +----------+          |      |
  |                       |                               |      |
  | -----------+    +-----+----+    +----------+    +-----+----+ |
  | | Twin NE 1+----+ Twin NE 2+----+ Twin NE 4+----+ Twin NE n| |
  | -----------+    +----------+    +----------+    +----------+ |
  |                            +-----------------+               |
  |                            | Data Repository |               |
  |                            +-----------------+               |
  +--------------------------------------------------------------+
                                  |
  +-------------------------------+------------------------------+
  |               Delay Deterministic Networking                 |
  +-------------------------------^------------------------------+
                                  |
+---------------------------------+---------------------------------+
| Phsical Network                   +------------+                  |
|                        +----------+Physical NE3+----------+       |
|                        |          +------------+          |       |
|                        |                                  |       |
| +------------+   +-----+------+   +------------+   +------+-----+ |
| |Physical NE1+---+Physical NE2+---+Physical NE4+---+Physical NEn| |
| +------------+   +------------+   +------------+   +------------+ |
+-------------------------------------------------------------------+</artwork>
      </figure>

      <t>For the above three problems, use the following three methods to
      solve:</t>

      <t>1) Each physical network element has a system MAC address, because
      the MAC address is unique in the whole network and can be used as the
      identifier of the physical network element. The twin NE ID can be
      extended based on the physical NE ID. For example, an 8-bit custom field
      is added after the MAC address of the physical NE system, for example,
      to identify the device type. The twin NE is identified based on the MAC
      address of the physical NE, which not only realizes the one-to-one
      correspondence between the physical NE and the twin NE, but also
      realizes the unique identification of the twin NE in the entire
      network.</t>

      <t>2) The data transmission network between the physical network element
      and the Data Repository uses a delay deterministic network, such as TSN
      (Time Sensitive Network), DIP (Deterministic Internet Network), etc.
      Since the delays of different physical network elements to transmit data
      to the Data Repository may be different, if a delay deterministic
      network is used, the data transmission delays T1~Tn are fixed and can be
      pre-calculated. After the Data Repository calculates T1~Tn, the maximum
      value Tmax is selected as the reference time. Assume that the data
      collected from each physical network element arrives at the Data
      Repository from t1 to tn. If the data transmission time Tn&lt;Tmax, the
      Data Repository waits for (Tmax-Tn) time before transmitting the data to
      the twin network elements. If Tn =Tmax, then Tmax-Tn=0, the Data
      Repository immediately transmits the data to the twin network elements.
      Because the Data Repository and twin network elements are deployed in
      the same local area network or the same physical entity (such as a
      server), the transmission delay between the Data Repository and each
      twin network element can be ignored. So far, all twin flow is delayed by
      a fixed time Tmax compared to physical flow, but the forwarding delay,
      jitter, packet loss and other performances of the two are the same.</t>

      <t>3) The data collected by the Data Repository needs to contain key
      information of physical flow, such as physical network element MAC
      address, traffic sampling rate, source MAC, destination MAC, protocol
      type, source IP address, destination IP address, protocol number, source
      port number , destination port number, packet priority, packet length,
      packet forwarding delay, etc. The first two parameters are mandatory,
      and the latter fields are optional according to application
      requirements.</t>

      <t>The implementation steps of twin flow are as follows, as shown in
      Figure 3:</t>

      <t>(1) To build a digital twin network, the physical network elements
      and the twin network elements are in one-to-one correspondence through
      the unique identifiers of the entire network, and the number of network
      elements and the topology are consistent;</t>

      <t>(2) The physical network element forms a data set of key flow
      information, such as {network element identification, sampling rate,
      source MAC, destination MAC, protocol type, source IP address,
      destination IP address};</t>

      <t>(3) The Data Repository collects the data sets of each physical
      network element, and calculates the maximum delay Tmax of data
      transmission;</t>

      <t>(4) After the Data Repository collects the data set, it is sent to
      the corresponding twin network element according to the physical network
      element identifier</t>

      <t>(5) Twin network elements generate twin flow according to the
      sampling rate and flow information of the dataset. Because the data
      transmission delay between the physical network element and the Data
      Repository is fixed at Tmax, all the flow of the twin network is delayed
      by Tmax relative to the physical flow. . Because the Data Repository and
      the twin network elements are in the same server or local area network,
      the transmission delay is negligible.</t>

      <figure align="center"
              title="Figure 3: The generation process of twin traffic">
        <artwork type="ascii-art" xml:space="preserve">           +---------+  +-------+  +-----------+  +------+
           | Physical|  |Detnet |  | Data      |  | Twin |
           |   NE    |  |       |  | Repository|  |  NE  |
           +-----+---+  +---+---+  +-----+-----+  +---+--+
                 |          |            |            |
                 |          |            |            |
                 |1.According to the characteristics of
                 |physical NEs, build twin NEs        |
                 +----------+------------+------------&gt;
                 |          |            |            |
                 |          |            |            |
+-------------------------+ |            |            |
| 2. Physical NEs|collect | |            |            |
| key flow information    | |            |            |
| and form a data|set     | |            |            |
+-------------------------+ |            |            |
                 |          |            |            |
                 |          |            |            |
            3.The|dataset is|sent to the Data Repository
                 +----------------------&gt;|            |
                 |          | 4.The Data Repository sendsto
                 |          |  the corresponding twin NE
                 |          | according to the NE identifier
                 |          | of the data|set         |
                 |          |            +-----------&gt;+
                 |          |            |            |
                 |          |            | +----------+---------------+
                 |          |            | | 5.The twin NEs generate  |
                 |          |            | | twin flow|according to   |
                 |          |            | | the data set information |
                 |          |            | +----------+---------------+
                 |          |            |            |</artwork>
      </figure>
    </section>

    <section title="Conclusion">
      <t>This paper realizes high-precision simulation of DTN twin flow, so
      that twin flow and physical flow meet the following three
      characteristics:</t>

      <t>1) The forwarding paths of the two types of flow are the same, that
      is, the nodes they pass through are the same;</t>

      <t>2) The network performance of the two types of flow is the same, that
      is, the two have the same performance as network delay, packet loss, and
      jitter;</t>

      <t>3) The data characteristics of the two types of flow are consistent,
      that is, they have the same key characteristics such as flow rate,
      five-tuple information, data packet length, and data packet
      priority.</t>
    </section>

    <section anchor="Security" title="Security Considerations">
      <t>TBD.</t>
    </section>

    <section anchor="IANA" title="IANA Considerations">
      <t>TBD.</t>
    </section>
  </middle>

  <back>
    <references title="Normative References">
      <?rfc include="reference.RFC.2119"?>

      <?rfc include="reference.RFC.8174"?>
    </references>
  </back>
</rfc>
