You are not logged in.
For wihch x
ax^2+bx+c , a>0 is minimum?
Let {is} means"must be"
i. ax^2+bx+c {is} min =>
ii. ax^2+bx {is} min
iii. a(x^2+(b/a)x) {is} min
iv. x^2+(b/a)x {is} min =>
v. x^2+2(b/2a)x+(b/2a)^2 {is} min
vi. (x+b/2a)^2 {is} min, but
vii. p^2>=0, p∈R =>
viii. (x+b/2a)=0
x=-b/2a
So when x=-b/2a ax^2+bx+c has a minimum.
If a<0 in iii we'll divide by -|a|, so x=-b/2a is maximum.
That was joke
Actually I don't know how to solve it without solving it.
I'm just guessing...
X1/2= (+-sqr(89)-3)/4?
x+y=34 =>
y=34-x
Substitute in 1:
Let {is} means "must be"
x^2+(34-x)^2 {is} min =>
x^2+34^2-68x+x^2 {is} min =>
2x^2-68x {is} min =>
2(x^2 - 34x) {is} min =>
x^2 - 34x {is} min =>
x^2 - 2.17.x {is} min =>
(here is the thin moment...)
x^2-2.17x+17^2 {is} min =>
(x-17)^2 {is} min =>
(x-17)^2=0
x=17
y=34-17=17
I'm not sure, but I think:
Here's the Mathematica code:
(* PROGRAM CALCULATING THE SQUARE SUM CHAINS AND TESTING THEIR CIRCULARITY
Based on Georgiev's square sum chain creating algoritm
By Krasimir Geogiev
December, 2005 *)
(*____________________________________________________________*)
(* data *)
n := 17
k := 2
(* /data *)
(*____________________________________________________________*)
(* function defining *)
sq[x_] := If[x^(1/2) == Floor[x^(1/2)], 1, 0]
(* this function gives 1 when x is perfect square and 0 when it isn't. *)
sqcei[x_] := Ceiling[(x+sq[x])^(1/2)]^2
(* this function gives the smallest perfect square which is greater than x. *)
(* /function defining *)
(*____________________________________________________________*)
(* calculations *)
a[1] := k
Do[b[i] = 0, {i, 1, n^3}]
b[k] := 1
Do[
p = sqcei[a[i - 1]] - a[i - 1];
j = 0;
While[j == 0,
If[b[p] == 0,
b[p] = 1;
a[i] = p;
j = 1,
p = sqcei[p + a[i - 1]] - a[i - 1]
]], {i, 2, n}]
(* /calculations *)
(*____________________________________________________________*)
(* output *)
t=Table[a[i],{i,1,n}]
max = Max[t]
iscir=If[sq[a[n] + k] == 1, 1, 0]
(* /output*)
(*____________________________________________________________*)
here you choose n and k.
t is the chain
max is max number in the chain
iscir is 1 if the chain sequence is circular and 0 if not.
I've simplified the output. In my program actually it is:
(* output *)
Print["The chain:"]
t = Table[a[i], {i, 1, n}]
Print["Length:"]
n
Print["Maximal number:"]
Max[t]
Print["Graphical plot:"]
ListPlot[t, PlotJoined -> True]
isO[x_] := If[sq[a[x] + k] == 1, 1, 0]
Print["if j <= n chain is circular:"]
tt = Table[isO[i], {i, 1, n}]
Print["Graphical plot of the circular test:"]
Plot[isO[Floor[x]], {x, 1, n + 1}]
(* /output*)
Yes. And i'm asking because his name is like someone from East Europe.
Yes,yes!
I know C very little.
Sorry, but I'm young and the first language i've learned was VBS.
If someone can translate the functions to C I'll be grateful.
The third function is correct.
I'll tell you. I asked myself same thing when I started doing the program. But my mistake was that i started writting on Visual Basic. And I had to define some functions:
------------------------------------------------------------------------------------------------------------------
Function IsPerfectSquare(x) 'it gives 1 if x is square and 0 if not.
If Sqr(x) = Math.Round(Sqr(x)) Then
IsPerfectSquare = 1
Else
IsPerfectSquare = 0
End If
End Function
Function Ceiling(x) 'gives the smallest integer, greater or equal to x
If x > Math.Round(x) Then
Ceiling = Math.Round(x) + 1
ElseIf x <= Math.Round(x) Then
Ceiling = Math.Round(x)
End Function
Function PerfectSquareCeiling(x) 'gives the smallest perfect square that is greater than x
PerfectSquareCeiling = Ceiling(Sqr(x + IsPerfectSquare(x))) ^ 2
End Function
------------------------------------------------------------------------------------------------------------------
The sum of two numbers is perfect square if
IsPerfectSquare(a+b)==1.
I wrote my program on Mathematica language and it has some extra properties:
here's my algoritm:
Let sqsei(x) give the smallest perfect square, greater than x.
a[1]=k-arbitary
How to find a[f]?
1.We calculate sqsei[a[f-1]]-a[f-1]. Let this be k.
2.If k is different with all numbers a[1],a[2],...,a[f-1] then a[f]=k.
3.If not, the new value of k must be sqsei[k+a[f-1]]-a[f-1] and we repeat step 3.
If a[f]+k=sqsei(a[f]) then the square chain is also circular.
I generalized my algoritm and inproved my program. Now it the first member don't have to be 1.
Why not
w=(pw/2-m)/(pn+1)-m
It's just a matter of chance.
You make an operation. Then you determine how will it change all and if it's useful or useless.
You have great site!
It should be write:
guess 5: 6275
Growing...
{1, 3, 6, 10, 15, 21, 4, 5, 11, 14, 2, 7, 9, 16, 20, 29, 35, 46, 18, 31, 33, 48, 52, 12, 13, 23, 26, 38, 43, 57, 24, 25, 39, 42, 22, 27, 37, 44, 56, 8, 17, 19, 30, 34, 47, 53, 28, 36, 45, 55, 66, 78, 91, 105, 64, 80, 41, 40, 60, 61, 83, 86, 58, 63, 81, 88, 108, 117, 79, 65, 104, 92, 77, 67, 54, 90, 106, 119, 50, 71, 73, 96, 100, 69, 75, 94, 102, 123, 133, 156, 168}
Length-91
MaxNumber-168
Here's a result:
{1, 3, 6, 10, 15, 21, 4, 5, 11, 14, 2, 7, 9, 16, 20, 29, 35, 46, 18, 31, 33, 48, 52, 12, 13, 23, 26, 38, 43, 57, 24, 25, 39, 42, 22, 27, 37, 44, 56, 8}
Length-40
MaxNumber-57!
Ha,ha
I've made a program for my algoritm!
So the other solutions are not solutions.
That's because I calculated them by hand.
Now I'll do some progarmming...
You beat me! :0
sqr(Phi)=1.272019650...