MicroTimeProcessUnit in simulation of collision

MicroTimeProcessUnit
———————————————
When I was a high school student, I made a program to simulate physical models with faniuy(going), but We have a big problem in that program that we can’t process collision when the models’s elastic constant is too big. when two objects with big elastic constant collide togeter, they will explode.
 
so, we build this MicroTimeProcessUnit to solve this problem.
and we make this:

———————————————

MainCode:

void display(void)
{
   for(step=0;step<STEP;step++)
   {
      ProcessSpring();

      ProcessOrNot();

      if (collision_ornot==true)
      {
         for (nProcess=0;nProcess<NPROCESS;nProcess++)
         {
            dt=fabs(dt/2);
            if (collision_ornot==true) dt=-dt;
            PowerOfTime(dt);
            ProcessOrNot();
         }

         ProcessCollision();
         dt=1;
      }

      PowerOfTime(dt);

      collision_ornot=false;
   } 

   Show();

}

 

———————————————

Still improving…

———————————————

chick here to download the workplace of this program in VC++6.0 [Do not uses FlashGet]

 
Advertisements
This entry was posted in 未分类. Bookmark the permalink.

4 Responses to MicroTimeProcessUnit in simulation of collision

  1. Sheng says:

    深奥了…
    实在看不懂…

  2. Sissi says:

    see my blog URL, and you know who I am,
    my MSN:sissilei@hotmail.com
    it is a big surprise to find your space!
    I forgot I could get your contact information from Aaron Yang.

  3. Fan says:

    你的手机换号了吗?发短信怎么没回呢?

  4. Shicong says:

    哎呀,你终于肯冒个泡泡了~~~还有啊,blog里面能不能介绍一点你的生活啊什么的,让你给我发邮件说说也不肯,怎么老觉得你把blog当草稿纸了~~~
    E-mail & MSN: aaronyang1987@hotmail.com

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s