text stringlengths 0 27.6k | python int64 0 1 | DeepLearning or NLP int64 0 1 | Other int64 0 1 | Machine Learning int64 0 1 | Mathematics int64 0 1 | Trash int64 0 1 |
|---|---|---|---|---|---|---|
I have a image with horizontal and vertical lines. In fact, this image is the BBC website converted to horizontal and vertical lines.
My problem is that I want to be able to find all the rectangles in the image. I want to write a computer program to find all the rectangles.
Does anyone know how to do this or suggest id... | 0 | 1 | 0 | 1 | 0 | 0 |
clock http://img710.imageshack.us/img710/2623/circlock.jpg
I do not know how to determine the top of the needle of the clock. If you determine the coordinates of them, I can think of the time of the clock.
Please help me solve this problem. Thank you very much!
| 0 | 0 | 0 | 0 | 1 | 0 |
Can anyone point me to a library or module with a decent integer relation implementation (most likely PSLQ)?
My target platform is .NET (C#), but if there's source code in C/C++, Java, whatever, even a semi-comprehensible algorithm, that would help me a lot. All I was able to find on Google was some unreadable Mathema... | 0 | 0 | 0 | 0 | 1 | 0 |
ok, I'm writing a little code snippet to get the ISO date-format value for yesterday.
code:
var dateString = new Date();
var yesterday = dateString.getFullYear();
yesterday += "-"+dateString.getMonth()+1;
yesterday += "-"+dateString.getDate()-1;
The above code outputs 2009-111-23. It is clearly not treatin... | 0 | 0 | 0 | 0 | 1 | 0 |
Im facing a scenario where in ill have to compute some huge math expressions. The expressions in themselves are simple, ie have just the conventional BODMAS fundamental but the numbers that occur as operands are very large, to the tune of 1000 digit numbers. I do know of the BigInteger class of the java.math module but... | 0 | 0 | 0 | 0 | 1 | 0 |
There is a Table of pairs , which defines pieces bounds.
And we are using straightforward algorithm:
y = f(x)
Calculate index n in Table using x
Get Yn and Yn+1, compute linear interpolation Y
Y is the answer.
So i think, there must be more efficient method, could you please point me?
| 0 | 0 | 0 | 0 | 1 | 0 |
I have this class:
public class Fibonacci
{
public static int Calculate( int x )
{
if (x <= 0)
{
return 0;
}
else
{
return Calculate(x - 1) + Calculate(x - 2);
}
}
}
Per a tutorial I'm doing if one inputs 6 one should get 8 as an expec... | 0 | 0 | 0 | 0 | 1 | 0 |
Is there an easy markup language for math equations?
I am developing an application for undergrads and I was looking for something less complex than LaTex and easier to write than MathML.
| 0 | 0 | 0 | 0 | 1 | 0 |
Reading a book on algorithms. Can someone explain the meaning of the mathematical symbol ∃?
| 0 | 0 | 0 | 0 | 1 | 0 |
I have a calculation which isn't working and I cannot work out why!
int numHoursInWeek;
int numDays;
int averageSalary;
int total_seconds_in_year = ((numHoursInWeek * 60 * 60) * numDays);
NSLog(@"average sal in pence=%i", (averageSalary * 100));
NSLog(@"num seconds in year=%i", total_seconds_in_year);
NSLog(@"cost p... | 0 | 0 | 0 | 0 | 1 | 0 |
HI,
I want to customize the WMD editor (or wmd-new) to convert TeX equations like $\frac{2}{3}$ to Google Charts API images ()
Is it possible to customize how the HTML is generated?
| 0 | 0 | 0 | 0 | 1 | 0 |
I saw the help in Matlab, but they have provided an example without explaining how to use the parameters in the 'classregtree' function. Any help to explain the use of 'classregtree' with its parameters will be appreciated.
| 0 | 0 | 0 | 1 | 0 | 0 |
How to find solution to overdetermined systems in Macsyma, Scilab, Octave?
| 0 | 0 | 0 | 0 | 1 | 0 |
I have a gray-scale image and I want to make a function that
closely follows the image
is always grater than it the image
smooth at some given scale.
In other words I want a smooth function that approximates the maximum of another function in the local region while over estimating the that function at all points.
... | 0 | 0 | 0 | 0 | 1 | 0 |
I am trying to find references about different designs of metamorphic generators can someone point me to the right direction. I have gone through some papers in ACM but couldn't find what I am looking for.
| 0 | 1 | 0 | 0 | 0 | 0 |
Given three 3D points (A,B, & C) how do I calculate the normal vector? The three points define a plane and I want the vector perpendicular to this plane.
Can I get sample C# code that demonstrates this?
| 0 | 0 | 0 | 0 | 1 | 0 |
I have been working for two years in software industry. Some things that have puzzled me are as follows:
There is lack of application of mathematics in current software industry.
e.g.: When a mechanical engineer designs an electricity pole , he computes the stress on the foundation by using stress analysis techniques(... | 0 | 0 | 0 | 0 | 1 | 0 |
I am trying to solve a problem which I have reduced down to counting the number of integer solutions to a number of linear inequalities. I need to be able to count the number of solutions for any number of variables c_1, ..., c_n, but for n=3 the equations could be written as:
The equations. http://silicon.appspot.com/... | 0 | 0 | 0 | 0 | 1 | 0 |
Consider you have a set of objects X (e.g., A, B, C, D) that you wish to divide into non-empty subsets that cover all of X. Mathematically, a partition of the set.
So, at first you might treat them as all different, {{A}, {B}, {C}, {D}}. Alternatively, you could separate them into vowels and consonants, i.e. {{A}, {B,... | 0 | 0 | 0 | 0 | 1 | 0 |
I need to implement a bit of AI to figure out how to hit a target with projectile motion.
I found this over at wikipedia:
Angle required to hit coordinate
Which looks like just the thing I need, especially since I have the added problem launching the projectile from above zero height. However, my maths skills aren't g... | 0 | 1 | 0 | 0 | 0 | 0 |
I have a 3D surface ( such as a cone). It is projected to a 2D plan in the form of contour, meaning that different Z will have different lines on 2D plan. The problem is from the contour, how to recover the 3D surface by using interpolation? We only know about the z difference between different contor lines.
| 0 | 0 | 0 | 0 | 1 | 0 |
I have a set of 5 values from experiment, E1, ..., E5 and results from 10000 different simulations, sim_A_B_C.out . From each simulation I get S1, ..., S5 .
I want to study the correlation between experimental and simulated values. So I would like to perform linear regression for each set in a script that loops for the... | 0 | 0 | 0 | 0 | 1 | 0 |
I am writing a program to try to solve a math problem. I need to generate a unique list of all of the numbers that add up to another number. For example, all of the unqiue combinations of 4 numbers that add up to 5 are:
5 0 0 0
4 1 0 0
3 2 0 0
3 1 1 0
2 2 1 0
2 1 1 1
This is easy to brute force in perl but I am wor... | 0 | 0 | 0 | 0 | 1 | 0 |
I have a string that looks like this:
"0.4794255386042030002732879352156"
which is approximately the sin(0.5). I would like to format the string to look a much nicer
"4.794255386042e-1"
How can I achieve this? Remember I am dealing with strings and not numbers (float, double). Also I need to round to keep the number ... | 0 | 0 | 0 | 0 | 1 | 0 |
I have a function,
P(x0, x1, ..., xn)
that takes 100 integers as input and gives as output an integer. P is a slow function to evaluate(it can range from 30 seconds to a couple of minutes).
I need to know which values of points will maximize the yielded value from P.
What techniques can I use to accomplish this? I know... | 0 | 0 | 0 | 0 | 1 | 0 |
In the XKCD comic 195 a design for a map of the Internet address space is suggested using a Hilbert curve so that items from a similar IP adresses will be clustered together.
Given an IP address, how would I calculate its 2D coordinates (in the range zero to one) on such a map?
| 0 | 0 | 0 | 0 | 1 | 0 |
A small (3x3, 4x4) tic-tac-toe can be easily solved by considering all the cases. But for example, you have a 30x30 tic-tac-toe. What algorithm would you use to decide the next best move in that case?
Minimax + alpha-beta pruning is one way that I know.
Is there some other way that is more efficient/not more efficien... | 0 | 1 | 0 | 0 | 0 | 0 |
I don't have much experience in machine learning, pattern recognition, data mining, etc. and in their underlying theory and systems.
I would like to develop an artificial model of the time it takes a human to make a move in a given Sudoku puzzle.
So what I'm looking for as an output from the machine learning process is... | 0 | 0 | 0 | 1 | 0 | 0 |
After extensive research and fun learning about Google's mapping api, I am building a digital antenna map application. At this point, the next step in the project plan is to build a memory-map replication of the google map that is locating digital tv stations based upon input from the user's address. So, I am using thi... | 0 | 0 | 0 | 0 | 1 | 0 |
I'm using long double in a C program to compute 2D images of the Mandelbrot Set but wish to have further precision to zoom deeper.
Are there any performance gains to be had from an arbitrary precision maths library that can restrict the amount of precision as required, rather than leaping from long double precision str... | 0 | 0 | 0 | 0 | 1 | 0 |
If I apply Binet Formula and Recursive formula for finding the fibonaci series, there is a discrepancy in result. Why?
Basically I am a student and it's our assignment to implement the fibonacci series. So while making the experiment I came across this situation.
Thanks in advance
| 0 | 0 | 0 | 0 | 1 | 0 |
What would be an intelligent way to store text, so that it can be intelligently parsed and translated later on.
For example, The employee is outstanding as he can identify his own strengths and weaknesses and is comfortable with himself.
The above could be the generic text which is shown to the user prior to evaluation... | 0 | 1 | 0 | 0 | 0 | 0 |
I am trying to understand the method transition that falls in the Matrix Class. I am using it to copy pieces of a bitMapData. But I need to better understand what transitions do.
I have a tilesheet that has 3 images on it. all 30x30 pixels. the width of the total bitmap is 90pxs.
The first tile is green, the second i... | 0 | 0 | 0 | 0 | 1 | 0 |
How can I find the distance between 2 System.Drawing.Point?
I googled and didn't find it...
Dim p1 As New Point(0, 10)
Dim p2 As New Point(10, 10)
Dim distance = ??
In this case, it should be 10, but what about here?
Dim p1 As New Point(124, 942)
Dim p2 As New Point(34, 772)
Dim distance = ??
Thanks!
| 0 | 0 | 0 | 0 | 1 | 0 |
i want to do arithmetic operation on jsp . I am using struts tag lib tag
following is the code :
<s:set name="value1" value ="%{0.0}" />
<s:set name="value2" value ="%{0.0}" />
<s:set name="percent" value ="%{0.0}" />
<s:iterator>
<s:set name="value1" value ="%{#value1+ someIntegerValue1}... | 0 | 0 | 0 | 0 | 1 | 0 |
differencePercentage = Math.round(((Pay.init / Pay.current) * 100) - 100);
and that gives me the difference in percent between initial and current pay, but it's reversed. When it's positive i.e. pay is above the initial value it says -X%, and when it's below it says X%.
Is there any obvious way I'm not seeing to polari... | 0 | 0 | 0 | 0 | 1 | 0 |
If I have 5 Vertices in 3D coordinate space how can I determined the ordering of those Vertices. i.e clockwise or anticlockwise.
If I elaborate more on this,
I have a 3D model which consists of set of polygons. Each polygon is collection of vertices and I want to calculate the norm of the polygon surface. To calculate ... | 0 | 0 | 0 | 0 | 1 | 0 |
Does anyone know how to calculate the error of quantizing from 16bit to 8bit?
I have looked at the Wikipedia article about Quantization, but it doesn't explain this.
Can anyone explain how it is done?
Lots of love,
Louise
Update: My function looks like this.
unsigned char quantize(double d, double max) {
return (unsi... | 0 | 0 | 0 | 0 | 1 | 0 |
I need to write an essay or a research for the subject Artificial Intelligence. There are many possible topics I can choose from plus we are also allowed to write about any other topic of interest.
One of the topics is Semantic Web. I would like to write about use of AI algorithms in relation with Semantic Web.
Could y... | 0 | 1 | 0 | 0 | 0 | 0 |
I was recently diagnosed with a cascading dissociative disorder that causes retrograde amnesia in addition to an existing case of possible anterograde amnesia. Many people have tried to remind me of how great a programmer I was before -- Right now I get the concepts and the idioms, but I want to teach myself whether I ... | 0 | 1 | 0 | 0 | 0 | 0 |
I need guidance in how I should compute the GoogleShare of several terms.
For example, take the following base terms:
"Tom Cruise" = 12,000,000 pages
"John Travolta" = 4,900,000 pages
Now if we add a second term:
"Tom Cruise" + "Scientology" = 784,000 pages
"John Travolta" + "Scientology" = 331,000 pages
So the Goo... | 0 | 0 | 0 | 0 | 1 | 0 |
I searched, can't find anything: How do I do this?
I enter $x = 'tlagre';
I want it to return every single letter combination, down to four.
i.e. - "tlagr" "gratl" "lat" "rat"
I've found some that can do this but none will do every number of letters (they all just do the exact same # of letters as given in $x
| 0 | 0 | 0 | 0 | 1 | 0 |
I am still a beginner but I want to write a character-recognition-program. This program isn't ready yet. And I edited a lot, therefor the comments may not match exactly. I will use the 8-connectivity for the connected component labeling.
from PIL import Image
import numpy as np
im = Image.open("D:\\Python26\\PYTHON-PR... | 0 | 1 | 0 | 0 | 0 | 0 |
When I was in high school and learning about matrices, we were shown a technique that would help in a situation like this:
There are a number of chess players in a league, and they need to determine a ranking for all of them, but don't have enough time for every player to play every other person. If it ends up that Pla... | 0 | 0 | 0 | 0 | 1 | 0 |
I would like to plot the "greasy" test signal in Matlab, and then plot a Gauss function in the same plot. The script below does that.
But I would like to be able to place the Gauss function at a certain position, so I see that others often use CIRCSHIFT to move plots.
When I use it I can move the Gauss function to the ... | 0 | 0 | 0 | 0 | 1 | 0 |
$onethird = 1.0/3;
$fivethirds = 1.0/3+1.0/3+1.0/3+1.0/3+1.0/3;
$half = 1.0/2;
$threehalf = 1.0/2+1.0/2+1.0/2;
var_dump($onethird + $fivethirds == $half + $threehalf);
which outputs false,but as we all know:5/3+1/3=2=3/2+1/2
How to fix this problem?
| 0 | 0 | 0 | 0 | 1 | 0 |
I saw this question, which focuses on the "Brittney Spears" problem. But I have a bit of a different question. How does the algorithm determine which words or phrases need to be ranked? For instance, if I send out a tweet that says "Michael Jackson died", how does it know to pull out "Michael Jackson" but not "died"... | 0 | 1 | 0 | 0 | 0 | 0 |
I have this code:
package math;
import java.io.IOException;
import java.util.Scanner;
public class Main
{
public static void main(String[] args) throws IOException
{
System.out.println("Hi, I will beat Java's Math.sqrt(double) method");
System.out.println("Both ways of calculation will be done... | 0 | 0 | 0 | 0 | 1 | 0 |
I'm trying to figure out how many possible ways there are to combine various elements form this string.
"{Hello|Hi|Hey} {world|earth}{!|.|?}"
Where one item (separated by a pipe/|) is selected at random from each group ({}) and combined into a single string.
So the above "template" could produce:
Hello world.
Hi earth... | 0 | 0 | 0 | 0 | 1 | 0 |
I am currently parsing a bunch of mails and want to get words and other interesting tokens out of mails (even with spelling errors or combination of characters and letters, like "zebra21" or "customer242"). But how can I know that "0013lCnUieIquYjSuIA" and "anr5Brru2lLngOiEAVk1BTjN" are not words and not relevant? How... | 0 | 1 | 0 | 0 | 0 | 0 |
I noticed that translating radians to degrees and vice versa is like translating a percentage to a whole number and vice versa. For example, to get 60 percent of 345 you do the following
60 * 345/100
to convert 60 degrees to radians you do
60 * 3.14/180
There is a pattern there BUT... we use 100 to compare percentage... | 0 | 0 | 0 | 0 | 1 | 0 |
MS calculator on windows 7 has a "programmers" mode. When I type in (in binary): 1111111111111111111111111111111111111111111111111111111111111111
and then click "Dec", the binary turns into -1. When I click Oct, the value turns into
1777777777777777777777
However, whenever I use an online converter, it doesn't work. ... | 0 | 0 | 0 | 0 | 1 | 0 |
I am creating a ping pong game. And I want to create the ability to control the direction of the ball based on the impact on the paddle. If the ball is coming down at vy = 4; vx = 4;
and the paddle is moving to the left at vx = -5; I want the ball to slightly change its course depending on how fast the paddle is moving... | 0 | 0 | 0 | 0 | 1 | 0 |
Given an array of prime factors of a natural number, how can I find the total number of divisors using LINQ upon the original array? I've already figured out most of this problem, but I'm having trouble with my LINQ statement.
Math Background:
The prime factors of a number are the prime integers that divide evenly in... | 0 | 0 | 0 | 0 | 1 | 0 |
I happened upon these values in my ColdFusion code but the Google calculator seems to have the same "bug" where the difference is non-zero.
416582.2850 - 411476.8100 - 5105.475 = -2.36468622461E-011
http://www.google.com/search?hl=en&rlz=1C1GGLS_enUS340US340&q=416582.2850+-+411476.8100+-+5105.475&aq=f&oq=&aqi=
JavaCast... | 0 | 0 | 0 | 0 | 1 | 0 |
In mathematics the identity (1 + sqrt(2))^2 = 3 + 2*sqrt(2) holds true. But in floating point (IEEE 754, using single precision i.e. 32 bits) calculations it's not the case, as sqrt(2) doesn't have an exact representation in binary.
So does using a approximated value of sqrt(2) provide different results for left and r... | 0 | 0 | 0 | 0 | 1 | 0 |
Just curious. When I bounce a ball off the walls of the stage using the following technique.
if(y > sRef.stageHeight || y < 0)
{
yDir = yDir * -1;
}
else if ( x > sRef.stageWidth || x < 0)
{
xDir = xDir * -1;
}
x += xspeed * xDir;
y += yspeed * yDir;
The above seems fine and works well. But If I choose t... | 0 | 0 | 0 | 0 | 1 | 0 |
I have heard of this algorithm, but is this algorithm good to use it with Bayesian Belief networks? Hugin is based on it and I'm looking for a book / article on this algorithm.
| 0 | 1 | 0 | 0 | 0 | 0 |
How would you go about creating a vector class in Delphi? I would prefer to put all math related stuff into a DLL. Should I use a record or a class implementing an interface?
Pros of record approach:
Fast and lightweight
Value type
Operator overloading
Cons of record approach:
Implementation cannot be hidden in DLL ... | 0 | 0 | 0 | 0 | 1 | 0 |
I am trying to display EXIF exposure time as a fraction of seconds but I am not getting expected result, probably a small mistake.
I have found two routines that do the calculation but both bring diffrent and wrong result.
The value I am having problem is: "0.0806451612903226" value is of type Extended.
DecimalToFract... | 0 | 0 | 0 | 0 | 1 | 0 |
Consider a Viterbi decoder on an additive model. It spends its time doing additions and comparisons. Now, consider two: one with C/C++ float as the data type, and another with int. On modern chips, would you expect int to run significantly faster than float? Or will the wonders of pipelining (and the absence of multipl... | 0 | 0 | 0 | 0 | 1 | 0 |
What will the code below be if value is 2 and counter is 11? What would $rating be?
$rating = (@round($rs[value] / $rs[counter],1)) * 10;
The complete code is below.
function getRating(){
$sql= "select * from vote";
$result=@mysql_query($sql);
$rs=@mysql_fetch_array($result);
$rating = (@round($rs[val... | 0 | 0 | 0 | 0 | 1 | 0 |
I need a mathematical function/formula/expression to take a number as parameter and find the lowest number ending with certain digits that is larger than the parameter.
For instance, if the ending digits should be 88 these are some examples of what I want:
f(0) = 0
f(87) = 88
f(88) = 88
f(89) = 188 //NB: NOT 88*2=176
... | 0 | 0 | 0 | 0 | 1 | 0 |
I have the following function that rounds a number to the nearest number ending with the digits of $nearest, and I was wondering if there is a more elegant way of doing the same.
/**
* Rounds the number to the nearest digit(s).
*
* @param int $number
* @param int $nearest
* @return int
*/
function roundNearest($... | 0 | 0 | 0 | 0 | 1 | 0 |
Kindly give me some hint of matrix multiplication using MTL 2. Or any ref. or link for the documentation of MTL 2.
| 0 | 0 | 0 | 0 | 1 | 0 |
Hellow Stack Overflow people. I'd like some suggestions regarding the following problem. I am using Java.
I have an array #1 with a number of Strings. For example, two of the strings might be: "An apple fell on Newton's head" and "Apples grow on trees".
On the other side, I have another array #2 with terms like (Fruits... | 0 | 1 | 0 | 0 | 0 | 0 |
I develop a Python-based drawing program, Whyteboard (https://launchpad.net/whyteboard)
I'm developing features to allow the user to rotate and scale a polygon that they draw. Here's my problem:
I have a Polygon class containing a list of all points, which is "closed off" at the end. Users can select drawn shapes in my... | 0 | 0 | 0 | 0 | 1 | 0 |
I am trying to construct an equilateral triangle with the following code, but I am not seeing what I would expect to.
I would expect to see a triangle drawn to the stage, but I don't see one.
I think there must be something wrong in terms of the location of the tri sprite on the screen.
public class test_drawing_triang... | 0 | 0 | 0 | 0 | 1 | 0 |
Does anyone know a way to locate rectangles to best fit a certain area? The rectangles can be scaled up to a certain limit, but they should keep their proportions.
I basically want to rebuild Mac OS' Exposé:
Picture
Thanks,
eWolf
| 0 | 0 | 0 | 0 | 1 | 0 |
I want to find a value of z at y = 12 and x = 3.5, given the below example data. How can I do this in C++?
y = 10
x = [1,2, 3,4, 5,6]
z = [2.3, 3.4, 5.6, 7.8, 9.6, 11.2]
y = 20
x = [1,2, 3,4, 5,6]
z = [4.3, 5.4, 7.6, 9.8, 11.6, 13.2]
y = 30
x = [1,2, 3,4, 5,6]
z = [6.3, 7.4, 8.6, 10.8, 13.6, 15.2]
My current Pyth... | 0 | 0 | 0 | 0 | 1 | 0 |
Scenario
I am attempting to implement supervised learning over a data set within a Java GUI application. The user will be given a list of items or 'reports' to inspect and will label them based on a set of available labels. Once the supervised learning is complete, the labelled instances will then be given to a learni... | 0 | 0 | 0 | 1 | 0 | 0 |
What does dimensionality reduction mean exactly?
I searched for its meaning, I just found that it means the transformation of raw data into a more useful form. So what is the benefit of having data in useful form, I mean how can I use it in a practical life (application)?
| 0 | 1 | 0 | 1 | 0 | 0 |
short sho1, sho2;
printf("Enter two shorts.
");
scanf("%hd %hd", &sho1, &sho2);
printf("%hd^%hd is %hd.
", sho1, sho2, sho1^sho2);
When I enter '2 2', I get this output:
2^2 is 0.
How come? I'm using the MinGW GCC compiler in Eclipse, in case that's of any importance.
| 0 | 0 | 0 | 0 | 1 | 0 |
Well as the questions says...
An equation might be more meaningful in its math-notated form than it is in code. Being able to put math in comments could improve readabibity on my projects.
In .NET btw.
| 0 | 0 | 0 | 0 | 1 | 0 |
I attached image:
(source: piccy.info)
So in this image there is a diagram of the function, which is defined on the given points.
For example on points x=1..N.
Another diagram, which was drawn as a semitransparent curve,
That is what I want to get from the original diagram,
i.e. I want to approximate the original f... | 0 | 0 | 0 | 0 | 1 | 0 |
I'm no professional programmer and I don't study it. I'm an aerospace student and did a numeric method for my diploma thesis and also coded a program to prove that it works.
I did several methods and implemented several algorithms and tried to show the proofs why different situations needed their own algorithm to solve... | 0 | 0 | 0 | 0 | 1 | 0 |
I have a 3D Plane defined by two 3D Vectors:
P = a Point which lies on the Plane
N = The Plane's surface Normal
And I want to calculate any vector that lies on the plane.
| 0 | 0 | 0 | 0 | 1 | 0 |
I need help converting this code from this thread: How to Rotate a 2D Array of Integers
to PHP arrays.
int [,] newArray = new int[4,4];
for (int i=3;i>=0;--i) {
for (int j=0;j<4;++j) {
newArray[j,3-i] = array[i,j];
}
}
Also, will this code work if the blocks are off-center?
| 0 | 0 | 0 | 0 | 1 | 0 |
Based on information in Chapter 7 of 3D Programming For Windows (Charles Petzold), I've attempted to write as helper function that projects a Point3D to a standard 2D Point that contains the corresponding screen coordinates (x,y):
public Point Point3DToScreen2D(Point3D point3D,Viewport3D viewPort )
{
double screenX... | 0 | 0 | 0 | 0 | 1 | 0 |
The theory is this: I have a circle C of radius R and centre S. Inside this circle, I want to place N (a "big" number) points such that the density of points in the vicinity V of a point P is equal everywhere in the circle for all points. As N goes to infinity and the vicinity goes to P, the density function in both po... | 0 | 0 | 0 | 0 | 1 | 0 |
Working programmer looking for a math refresher or just developing mathematical thinking. Saw J Language http://www.jsoftware.com/jwiki/Books
The book "Math for the Layman" claims that the J language makes math easier to learn by providing interactive tools and simpler notation than conventional math. Can someone confi... | 0 | 0 | 0 | 0 | 1 | 0 |
I'm working on java program that can compute the differentiation of any given mathematical expression.
When User types the expression say Sin(Cos(x^2)) I need to check whether it is mathematically valid or not.
Of course we can do it by manual code writing but that would be tedious work.
Can I do it using regex packag... | 0 | 0 | 0 | 0 | 1 | 0 |
I have a list of video segment durations I need to add up to get the total duration.
The series is like this:
0:33
4:30
6:03
2:10
...etc
I need to add up the minutes and seconds to get a total video duration.
Here's the modified function of my accepted answer:
function getTotalDuration ($durations) {
$total = 0;... | 0 | 0 | 0 | 0 | 1 | 0 |
I have a simple C# function:
public static double Floor(double value, double step)
{
return Math.Floor(value / step) * step;
}
That calculates the higher number, lower than or equal to "value", that is multiple of "step". But it lacks precision, as seen in the following tests:
[TestMethod()]
public void FloorTest(... | 0 | 0 | 0 | 0 | 1 | 0 |
I tend to use math functions of constant expressions for convinience and coherence (i.e log(x)/log(2) instead of log(x)/0.3...). Since these functions aren't actually a part of the language itself, neither are they defined in math.h (only declared), will the constant ones get precalculated at compile time, or will they... | 0 | 0 | 0 | 0 | 1 | 0 |
I'm analyzing financial data and would like to find the inflection points of a line. I know I can do this using derivatives, but first I need an equation. Is there a way to generate an equation based off of a series of numbers. I would need to do this programmaticly.
| 0 | 0 | 0 | 0 | 1 | 0 |
I have an application which decides whether a human is handwaving,running or walking.
The idea is i have segmented an action,say handwave,to its poses. Let's say
Example;
for human1:pose7-pose3-pose7-..... represents handwave
for human3:pose1-pose7-pose1-..... represents handwave
for human7:pose1-pose1-pose7-..... rep... | 0 | 0 | 0 | 1 | 0 | 0 |
I know that if we have some data representing some wave, for example image line values,
we can use fourier transform to get frequency function of that wave.
But we have N values at points x=0...N-1
And we get only N frequencies at the output.
So I want to analyze the wave everywhere in the range [0, N-1]
For example... | 0 | 0 | 0 | 0 | 1 | 0 |
I challenge you to write a mathematical expression evaluator that respects PEMDAS (order of operations: parentheses, exponentiation, multiplication, division, addition, subtraction) without using regular expressions, a pre-existing "Eval()"-like function, a parsing library, etc.
I saw one pre-existing evaluator challen... | 0 | 0 | 0 | 0 | 1 | 0 |
I have a product that sells in a strange way.
The formula to get the current price is:
total_products_sold * 0.05
I need a function that will return the total sales value, given a total_products_sold value.
This needs to figure out all past pricing, using the above formula.
e.g. if I sold 3 products, the total sales a... | 0 | 0 | 0 | 0 | 1 | 0 |
I have just started programming with Java and noticed I might need to improve my math skills if i'm to do anything worthwhile with it. I just noticed that some of the exercises should be easy for someone with a solid understanding in math as there seems to be some math formulae running the show. I finished high school ... | 0 | 0 | 0 | 0 | 1 | 0 |
I am hand tagging twitter messages as Positive, Negative, Neutral. I am try to appreciate is there some logic one can use to identify of the training set what proportion of message should be positive / negative and neutral ?
So for e.g. if I am training a Naive Bayes classifier with 1000 twitter messages should the pr... | 0 | 1 | 0 | 0 | 0 | 0 |
Well
It's not a big question, obviously.
But you see, an application that is using a database on the servers, and is installed on multiple clients. Is called Client/Server application.
And an application that is constituted by two parts: Host (or server) part, and the client part.
They are both called client/server app... | 0 | 1 | 0 | 0 | 0 | 0 |
As a student of computational linguistics, I frequently do machine learning experiments where I have to prepare training data from all kinds of different resources like raw or annotated text corpora or syntactic tree banks. For every new task and every new experiment I write programs (normally in Python and sometimes J... | 0 | 1 | 0 | 1 | 0 | 0 |
I'm trying to achieve something like the following in C++:
class MyVector; // 3 component vector class
MyVector const kA = /* ... */;
MyVector const kB = /* ... */;
MyVector const kC = /* ... */;
MyVector const kD = /* ... */;
// I'd like to shorten the remaining lines, ideally making it readable but less code/ope... | 0 | 0 | 0 | 0 | 1 | 0 |
Is there a research paper/book that I can read which can tell me for the problem at hand what sort of feature selection algorithm would work best.
I am trying to simply identify twitter messages as pos/neg (to begin with). I started out with Frequency based feature selection (having started with NLTK book) but soon re... | 0 | 1 | 0 | 0 | 0 | 0 |
Sorry if my question sounds dumb. But some time small things create big problem for you and take your whole time to solve it. But thanks to stackoverflow where i can get GURU advices. :)
So here is my problem. i search for a word in a string and put 0 where that word occur.
For example : search word is DOG and i have s... | 0 | 0 | 0 | 0 | 1 | 0 |
I've three sets of data such as:
x y
4 0
6 60
8 0
Does anyone know any (efficient) Java codes that can give me back the values of a, b, and c (the coefficients)?
| 0 | 0 | 0 | 0 | 1 | 0 |
I have a problem where I have a set of numbers eg.
5, 7, 7, 8, 8, 8, 7, 20, 23, 23, 24, 24, 24, 25
In the above set, there is two "clusters" of numbers, I want to write a program to find the centers of these clusters. Could you call them attractors as in Fractal theory?
So the program would, I guess, find that the set ... | 0 | 0 | 0 | 0 | 1 | 0 |
Recently, a correspondent mentioned float.as_integer_ratio(), new in Python 2.6, noting that typical floating point implementations are essentially rational approximations of real numbers. Intrigued, I had to try π:
>>> float.as_integer_ratio(math.pi);
(884279719003555L, 281474976710656L)
I was mildly surprised not to... | 0 | 0 | 0 | 0 | 1 | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.