|
Thnx for the reply.Ill chk it out.
|
|
|
|
|
Hi.I'm researching on an algorithm about the counting car on traffic. We're using to camera to catch and count the cars but I have some problems about this.
The problem is we know the coordinates of cars on the way. For example 4 cars with their coordinates in 1st frame. At 2nd frame lets say 1 car goes out from the camera view point and new car comes in. At 3rd frame no car goes out and 2 car come in to the view point.
So the video will like this;
First Frame = 4 Car ---------4 new
Second Frame = 4 Car ------1 new
Third Frame = 6 Car --------2 new
----------------------------------
Total Passed Cars =---------7 CARS
With our calculation we know that 7 car passed from way. But the problem is camera cant recognize which car is from old frame.
I want a suggestion from you. Any ideas about to solve this? Please help me...
|
|
|
|
|
Sounds like you either need to upgrade your frame rate so you can track the cars incrementally, that is, their motion between frames is less than a car length so you can infer the same car because it was in the previous frame and couldn't have moved more than a certain distance between frames. If you can find partial cars, you can track them entering and exiting the frame as well. Otherwise, it seems you need a way to uniquely identify the cars in the frame. Color (assuming you're capturing color) could be used but that's, obviously, not robust since cars can be the same color and it's prone to lighting problems. Even if you can identify features of the cars, it's not entirely robust since tens of thousands of identical (at least from an exterior perspective) roll off the assembly lines each year.
If you don't have the data, you're just another a**hole with an opinion.
|
|
|
|
|
BTW, you didn't say how you were detecting cars and the camera setup or what kind of literature search you'd done. There are thousands of items on the web about the topic.
If you don't have the data, you're just another a**hole with an opinion.
|
|
|
|
|
I have am trying to find the difference between factor and coefficient. Searching shows they both are used a lot but I have been unable to find a good comparison of the two (various online dictionary definitions aren't a lot of help). What I have been able to find implies they are the same - the coefficient of friction (ratio of tangential force to the perpendicular normal force) and drag factor (total acceleration force divided by weight). Each results in a multiplicative number. What am I missing? What is the difference?
|
|
|
|
|
AFAIK, a coefficient is used for a multiplicative constant while factor has a more general meaning (i.e. multiplicative operand).
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[My articles]
|
|
|
|
|
Hey guys,
How do you compare two values and say that value 1 is X% larger than value 2 or value 1 is x fold larger than value 2?
Thanks!
It is said that the most complex structures built by mankind are software systems. This is not generally appreciated because most people cannot see them. Maybe that's a good thing because if we saw them as buildings, we'd deem many of them unsafe.
|
|
|
|
|
Ian Uy wrote: How do you compare two values and say that value 1 is X% larger than value 2
double value1 = 150.0
double value2 = 100.0
double difference = value1 - value2;
double percentageIncrease = (difference / value2) * 100;
It would be said that value1 is 50% larger than value2.
Ian Uy wrote: value 1 is x fold larger than value 2
Technically, "x fold larger" is a suffix you add to a number to say "multipled by."
double value1 = 200.0;
double value2 = 50.0;
double foldIncrease = value1 / value2;
It would be said that value1 is four-fold larger than value2.
Enjoy,
Robert C. Cartaino
modified on Tuesday, August 19, 2008 4:48 PM
|
|
|
|
|
Uhmm. I have a problem. The two values are MILES APART and I can't find a calculator powerful enough to compute the percentage increase.
Value 1 = 1.36 x 10^58
Value 2 = 2.36 x 10^19,709
Is there any mathematical technique or approach to simplify this?
It is said that the most complex structures built by mankind are software systems. This is not generally appreciated because most people cannot see them. Maybe that's a good thing because if we saw them as buildings, we'd deem many of them unsafe.
|
|
|
|
|
Ian Uy wrote: Value 2 = 2.36 x 10^19,709
Is there any mathematical technique or approach to simplify this?
The rules for addition/subtraction/multiplication/division of scientific notation are not difficult. Here is an article on Scientific Notation[^] which covers how to multiply and divide powers of ten. Here is another one[^] which also covers addition and subtraction.
|
|
|
|
|
Yeah, I already did that before asking. However, I am not sure if its correct.
To subtract value 1 from value 2, I need to move value 1's decimal point (19709-58)=19651 times to the right? this will produce a relatively small number. And if I subtract that small number to value 2, the result will not be different. It is still 2.36 x 10^19,709. Right?
It is said that the most complex structures built by mankind are software systems. This is not generally appreciated because most people cannot see them. Maybe that's a good thing because if we saw them as buildings, we'd deem many of them unsafe.
|
|
|
|
|
Ian Uy wrote: this will produce a relatively small number. And if I subtract that small number to value 2, the result will not be different. It is still 2.36 x 10^19,709. Right?
Pretty much. Consider your numbers.
Value 2 = 2.36 x 10^19,709
There are about 1.0 x 10^80 atoms in the known universe. If we discovered that there were actually a billion other universes out there, there would still only be 1.0 x 10^89 atoms in all of them combined. So your number (2.36 x 10^19,709) is what would be known in the mathematical community as "big... really big."
Relatively speaking (compared to your first number)...
Value 1 = 1.36 x 10^58 ...is really, really small. Pretty much, for all intents and purposes, practically zero.
So your question boils down to something like, "If I take all the matter in the in the known universe -- every tree, every person, every planet, every sun, every black hole contained in all 100-billion known galaxies -- and manage to sneeze into a parallel dimension, what percentage did I decrease the weight of the universe? And you would still be way off from your example.
Enjoy,
Robert C. Cartaino
|
|
|
|
|
Comparing the larger number to the smaller, it is (2.36/1.36)*10^19651 larger. 10^19728 is just less than 2^64K. This can be expressed exactly by an extended arithmetic binary number 64K BITS long, or 8K BYTES long, or 2048 DWORDS long.
|
|
|
|
|
Thank you for taking the time to answer my question. I understand it now.
It is said that the most complex structures built by mankind are software systems. This is not generally appreciated because most people cannot see them. Maybe that's a good thing because if we saw them as buildings, we'd deem many of them unsafe.
|
|
|
|
|
Ian Uy wrote: Value 1 = 1.36 x 10^58
Value 2 = 2.36 x 10^19,709
Is there any mathematical technique or approach to simplify this?
In that case Value2 - Value1 = Value2 accurate to 19,651 decimal places.
Of course, one would have to question whether percentage increase is a meaningful method of displaying the difference.
Peter
"Until the invention of the computer, the machine gun was the device that enabled humans to make the most mistakes in the smallest amount of time."
|
|
|
|
|
Ian Uy wrote: Is there any mathematical technique or approach to simplify this?
Sure!
Given V1 = 1.36 x 10^58 and V2 = 2.36 x 10^19709,
and %Increase = [(V2 - V1)/V1] x 100:
1. (V2 - V1)/V1 = V2/V1 - V1/V1 = V2/V1 - 1
2. V2/V1 = 10^(log V2 - log V1)
3. Subtract 1, then multiply by 100 to get %
so,
1. (2.36 x 10^19709 - 1.36 x 10^58)/1.36 x 10^58 =
(2.36 x 10^19709/1.36 x 10^58) - 1
2. V2/V1 = 10^(log( 2.36 x 10^19709 ) - log( 1.36 x 10^58)) =
10^ (19709.00864 - 58.13354) = 10^ 19650.87510
3. % = (10^19650.87510 -1) x 100.
You're still going to have a hell of a time getting a computer to calculate a number that large, but the use of logarithms reduces the size of the intermediate results to a manageable magnitude.
"A Journey of a Thousand Rest Stops Begins with a Single Movement"
|
|
|
|
|
Roger Wright wrote: You're still going to have a hell of a time getting a computer to calculate a number that larg
I beg to differ, it does not take that long. I made the calculations (I am only reporting the digit count of the various values, but I can report the actual values if desired):
14.984 msec to calculate (14,984 seconds for 1000 loops).
Chars in 10^56 = 57
Chars in 136*10^56 (=V1) = 63
Chars in 10^19707 = 19708
Chars in 236*10^19707 (=V2) = 19714
Chars in (V2-V1) = 19714
Chars in quotient of (V2-V1)/V1 = 19652
Chars in remainder of (V2-V1)/V1 = 63
Chars in quotient of V2/V1 = 19652
Chars in remainder of V2/V1 = 63
Dave Augustine.
|
|
|
|
|
How to implement TREND function of MS Excel in c#.net
thanks
|
|
|
|
|
See, for instance, [^], [^], [^].
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
[Image resize DLL]
|
|
|
|
|
Hi ALL
I request some one can help me in generating the different combinations with the given string.
I am having string "ABC" and it need to generate the combinations with the same length string
Example: I am having string like "ABC" and generates Combinations
"ABC"
"ACB"
"BAC"
"BCA"
"CAB"
"CBA"
Same way if I choose 4 length string "ABCD" it should generate like below.
"ABCD"
"ABDC"
"ACBD"
"ACDB"
"ADBC"
"ADCB"
"BACD"
"BADC"
"BCAD"
"BCDA"
"BDAC"
"BDCA"
......should generate sixteen combinations..
length of the string can be dinamic(can be 5 , 6 or more).
Please can some one help me to build algorithm to generate this type of combinations in c#.
Thanks in Advance
Nivas
|
|
|
|
|
SatyaVas wrote: ......should generate sixteen combinations..
There are 24 combinations in this case. It's 4! (4 factorial).
The C++ standard library already contains functions to do this. This code will pull it off:
#include "stdafx.h"
#include <iostream>
#include <algorithm>
void main()
{
using namespace std;
char initial[] = "ABCD";
char *pEnd = initial + sizeof(initial)/sizeof(initial[0])-1;
do
{
cout << initial << endl;
}
while (next_permutation(initial, pEnd));
}
If you look at the source code that implements next_permutation you can easily write a C# version.
Steve
|
|
|
|
|
|
does anyone have a good formula for calculating azimuth between two city lat and lons
thanks
|
|
|
|
|
winburn wrote: does anyone have a good formula for calculating azimuth between two city lat and lons
Google is your friend. Try the following search terms (without quotes).
formula latitude longitude azimuth
|
|
|
|
|
Good Day,
Given a pseudo code below:
<br />
main()<br />
{<br />
for(int i=0;i<n;i++)><br />
{<br />
x[i]=func1(func2(x[i]));<br />
}<br />
}<br />
<br />
func1(x[])<br />
{<br />
for(int i=0;i<length(x);i++)><br />
}<br />
<br />
func2(x[])<br />
{<br />
for(int i=0;i<length(x);i++)><br />
}<br />
How can I compute for the Asymptotic notation? I know that the loop in main() is O(n) and both func1 and func2 are O(n). But How can I combine the 3? Can I even combine the 3 to get O(N^3)? or it will be just O(3N)?
Thanks!
It is said that the most complex structures built by mankind are software systems. This is not generally appreciated because most people cannot see them. Maybe that's a good thing because if we saw them as buildings, we'd deem many of them unsafe.
|
|
|
|