Git Product home page Git Product logo

Comments (2)

Sissima avatar Sissima commented on September 27, 2024

Hi,

You can find a definition of butterfly trafic on Nirgam simulator and then code it similarly on Noxim.
It is defined as:
//////////////////////////////////
int traffic_patterns::trafficButterfly(int tileID, int num_rows, int num_cols)
{

int nbits = (int)log2ceil((double)(num_rows*num_cols));
int dnode = 0;
for (int i=1; i<nbits-1; i++)
    setBit(dnode, i, getBit(tileID, i));
setBit(dnode, 0, getBit(tileID, nbits-1));
setBit(dnode, nbits-1, getBit(tileID, 0));
if (dnode>=num_rows*num_cols)
{
    dnode=num_rows*num_cols-1;
}

return dnode;

}
/////////////////////////////////
This give you the following result in the case of 4x4 mesh 2D:

-1--5--4--8-
-3--2--6--10-
-5--9--13--12-
-7--11--15--14-
-8--4--5--1-
-10--6--2--3-
-12--13--9--5-
-14--15--11--7-

Hoping help you.
Regards,

from noxim.

stdoo avatar stdoo commented on September 27, 2024

Thanks a lot. I plot it out, and it is not like a butterfly.

from noxim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.