Click here to Skip to main content
15,922,512 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Simple debugging question Pin
jbarton23-May-03 3:39
jbarton23-May-03 3:39 
GeneralRe: Simple debugging question Pin
73Zeppelin23-May-03 3:57
73Zeppelin23-May-03 3:57 
GeneralTransparent control Pin
MemLeak23-May-03 2:46
MemLeak23-May-03 2:46 
GeneralRe: Transparent control Pin
Rage23-May-03 3:00
professionalRage23-May-03 3:00 
GeneralRe: Transparent control Pin
MemLeak23-May-03 3:11
MemLeak23-May-03 3:11 
GeneralRe: Transparent control Pin
basementman23-May-03 4:02
basementman23-May-03 4:02 
GeneralRe: Transparent control Pin
MemLeak23-May-03 4:53
MemLeak23-May-03 4:53 
GeneralAny link to a Free ebook about Drivers Pin
Fad B23-May-03 2:40
Fad B23-May-03 2:40 
GeneralHide passwords... Pin
rohit.dhamija23-May-03 2:11
rohit.dhamija23-May-03 2:11 
GeneralRe: Hide passwords... Pin
G. Steudtel23-May-03 3:12
G. Steudtel23-May-03 3:12 
GeneralRe: Hide passwords... Pin
jhwurmbach23-May-03 3:34
jhwurmbach23-May-03 3:34 
Generalerrors! Pin
flora_k23-May-03 0:59
flora_k23-May-03 0:59 
GeneralRe: errors! Pin
jhwurmbach23-May-03 1:05
jhwurmbach23-May-03 1:05 
GeneralRe: errors! Pin
flora_k23-May-03 1:09
flora_k23-May-03 1:09 
GeneralRe: errors! Pin
jhwurmbach23-May-03 1:38
jhwurmbach23-May-03 1:38 
GeneralRe: errors! Pin
Rage23-May-03 1:47
professionalRage23-May-03 1:47 
GeneralRe: errors! Pin
flora_k23-May-03 2:59
flora_k23-May-03 2:59 
GeneralRe: errors! [modified] Pin
Rage23-May-03 3:09
professionalRage23-May-03 3:09 
GeneralRe: errors! Pin
Rage23-May-03 1:27
professionalRage23-May-03 1:27 
GeneralRecordSets && DataSets Pin
NHM23-May-03 0:14
NHM23-May-03 0:14 
GeneralRe: RecordSets && DataSets Pin
Alexandru Savescu23-May-03 6:05
Alexandru Savescu23-May-03 6:05 
Generalhelp! Pin
flora_k22-May-03 23:56
flora_k22-May-03 23:56 
GeneralRe: help! Pin
Rage23-May-03 1:42
professionalRage23-May-03 1:42 
Let me tell you that your matlab code is not really optimized...

For the following code, you need to put the size of the Trl table in length_y (which has to be declatred as an int).

int Dura = 1000/4096;
int *Trl;
int tmp;
int histogram_ram[4096];
int location;
int perc;
int time;

Trl=(int *)malloc(length_y*sizeof(int));
realTrl=(int *)malloc(length_y*sizeof(int));

for (location=1;location<length_y;location++)
{
   if ((y[location]-sl<0)&&(y[location+1]-sl>0))||((y[location]-sl>0)&&(y[location+1]-sl<0))
   {
      perc = (sl[location] - y[location])/(y[location +1] - y[location]) ;
      time = t[location] + (t[location+1]- t[location])*perc;
      Trl[location]=time;
   }
   else if ((y[location]-sl)==0)
   {
       Trl[location]=t[location];
   }
}

for(location=1;location<length_y-1;location++)
{
    Trl[location]=Trl[location+1]-Trl[location];
}

for (location=0;location<4096;location++)
{
    histogram_ram[location]=0;
}

for (location=1;location<length_y;lcoation++)
{
  tmp=(int)(Trl[location]/Dura+1);
  hitogram_ram[tmp]++;
}


This has not been tested.

~RaGE();
Questionwhat have I deleted? :=&lt; Pin
ilavl22-May-03 23:33
ilavl22-May-03 23:33 
AnswerRe: what have I deleted? :=&lt; Pin
Rickard Andersson2023-May-03 0:04
Rickard Andersson2023-May-03 0:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.