Search:
Type: Posts; User: jemidiah
Search:
Search took 0.05 seconds.

https://en.wikipedia.org/wiki/Binomial

To find the height of the four isosceles triangles, draw a right triangle from the vertex to the center of the base to the midpoint of one of the sides. If the sides have length A and the overall...

Why do you VB* people do everything the hard way? Weakly typed languages for the win. :)
(Though to be fair, the .NET IDE is really quite nice.)

Ah, that's far too complicated to hope for an analytic solution. There's also a problem of uniquenessthere are surely quite a few values of your three variables which "on average" with purely...

More details are needed to give an exact solution; you'll probably end up wanting something like the inverse of a cumulative distribution function.

I find the code in post #4 very difficult to interpreta lot of it doesn't seem to make much sense. The code in post #5 looks pretty close, but I think it should instead be...
'Assume the Sides...

They're not symbolforsymbol the same, but yes, they're equal, since 3c is (c3), and 12c6a is (6a12c). I had checked to make sure. You can also have Wolfram Alpha check for symbolic equality,...

You're correct, and Wolfram Alpha agrees.

Minor mistake: "mx = (x2  x1) / circ2Rad" should be pulled out of the If statement and put right before it. mx is not getting properly reset in the x1=x2 case, which only shows up in the a=0 (or...

Note quite. Again the issue is the SSA case, which comes down to the noninvertibility of the sine function on the range 0 to 180. In particular, given a, A, and B, you can compute sin(b), but sin is...

You can't do much with just 1 side and its opposite angle. There are certainly many solutions give just those two pieces of information. You should be able to pick a second angle arbitrarily (subject...

This is getting at the standard similarity/congruence tests for triangles. Here they are:
AAA: three angles determine the corresponding sides up to an overall scale factor. Since the angles add up...

This isn't really a math question. It should be in one of the languagespecific forums. There are also a zillion code examples of the zillion and one sorting algorithms out there, though they may not...

Minor thing: I noticed a typo in my second graph's equation from post #8. I had written y = −x² + 21x + 11 instead of y = −x² + 21x + 22. This didn't affect the default Wolfram Alpha view of the...

Well, y is 0 at the xintercepts, since the xintercepts are on the xaxis, and the xaxis is precisely the line consisting of points whose ycoordinate is 0.
Perhaps this will help? Consider the...

I think I'd have to see the question to know what you're trying to do. You again said you needed to "solve for x", and I've told you how to solve for x in terms of y. If you mean you need to solve...

You wrote an expression, not an equation, so what do you mean by it "seems insoluble without a value for y"?
To take a simpler example, start with y=x^2. Doing the same operation, i.e. saying x^2...

Well, if you want to solve your equation for x in terms of y, you'll have to use the quadratic formula, and there are two "branches" of solutions in general (the function is not invertible in...

Oh, I agree my solution is easy to implement with a for loop, it's just cleaner and (potentially) faster to use a linked list/queue style data structure, at least if there are often many unused spots...

Yeah, I'm not a big fan of the two methods you suggested either. The first would make earlier entities *much* more likely to be chosen than later ones, while the second would make the last entity...

That article is nice and brief, and it gives some notion of what the parts of Heron's formula individually "mean". It does something quite similar to what my proof does, but with the incircle rather...

@boops boops: for what it's worth, I made an effort to avoid Heron's formula since it seemed like its use just pushes the problem farther down the linewhy is Heron's formula true? On the other hand...

First, here's why the circumcenter exists. Take two sides of a triangle and consider their perpendicular bisectors. Since the sides are not parallel, neither are the perpendicular bisectors, so they...

Just to be clear, my comment about precision was directed at how precisely you wanted to draw "the maximum sized scale triangle within the bounding rectangle [subject to some given angles]", rather...

The complexity of what you want depends a lot on how precise you want it all to be and what you're willing to say is "good enough". For instance, your "acute" case in post #1 allows nonacute...

@dday9: cool beans.
Totally understandable, though in this case there was a very easy check besides looking at the original source code. The matrix form of the operation needed to have...

I see one big mistake still in #3, namely the " x" should be "+ x". That would produce extremely erratic results.
I disagree with passel in that I think the integerbased coordinates for your...

You seem to be referring to the fact that the rows of Pascal's triangle, when plotted after normalization, look very much like a normal distribution, especially as you take longer and longer rows....

Ah, my mistake. That makes the computation easier. Since 0 < N < 100, we may evidently assume every such sequence terminates, since a nonterminating sequence occurs with 0 probability. Each sequence...

Unless I'm really, really misunderstanding your question, it's not (N/100)M times. For instance, at N=100, this gives M, but as you say it should obviously give infinity. As I understand it, you...

x is a value between 0 and 1 (a float), but you're making it an int. You could also make x use percentages, I suppose.

You want what's called a "linear interpolation". If p and q are two numbers and x is a parameter between 0 and 1, you can get values in between p and q based on x using the standard formula F(x) =...

I agree with passel. The guys each have $9 at the end, the bellhop has $2, and the manager has $25. 9*3 = 27 = 2+25, which makes perfect sense. The "$1 discrepancy" is just coming from confusing +...

I had a more iterative approach in mind for the lexer. That is, you run through the code character by character adding tokens to a queue as you go. It's fundamentally similar to what you're doing,...

RPN probably isn't an option here since that would force users to enter unusual syntax.
The shuntingyard algorithm is probably what you're after here. The example and description at the link are...

I feel I should have a disclaimer at the top of this post. Namely, you probably shouldn't have to write your own parser nowadays and should instead be able to use someone else's; if you do have to...

I don't work in VB anymore, though the Python translation of that code fails on the example I gave earlier, and the VB version should be similar. Specifically, given
def dec2frac(f):
u =...

The trouble is your code is assuming the decimal representation infinitely repeats. For instance, for 6/5 = 1.2, you're assuming it's really 1.2222222... = 11/9. But it's not, it's 1.200000.... I...

I can't really understand your revised version, sorry. What I know so far: if A (the random number) is > 0.9, compute N = ceil((1+log10(1A))/log10(0.9)), which is the smallest N such that 0.1*0.9^N...

Say x is the random number. If x < 0.1, you want to know when 0.1*0.9^y = x (essentially); this occurs for y = log_(0.9) (x/0.1) = (1+log10(x))/log10(0.9). For instance, if x = 0.0324, this gives...

Click Here to Expand Forum to Full Width
