-
Notifications
You must be signed in to change notification settings - Fork 0
/
pe85.nb
347 lines (334 loc) · 12.6 KB
/
pe85.nb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
(* Content-type: application/vnd.wolfram.mathematica *)
(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)
(* CreatedBy='Mathematica 12.1' *)
(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[ 158, 7]
NotebookDataLength[ 12788, 339]
NotebookOptionsPosition[ 11632, 313]
NotebookOutlinePosition[ 12322, 334]
CellTagsIndexPosition[ 12279, 331]
WindowFrame->Normal*)
(* Beginning of Notebook Content *)
Notebook[{
Cell[CellGroupData[{
Cell[BoxData[{
RowBox[{
RowBox[{"formula", "=",
RowBox[{
RowBox[{"Sum", "[",
RowBox[{
RowBox[{
RowBox[{"(",
RowBox[{"M", "-", "m", "+", "1"}], ")"}], "*",
RowBox[{"(",
RowBox[{"N", "-", "n", "+", "1"}], ")"}]}], ",",
RowBox[{"{",
RowBox[{"m", ",", "1", ",", "M"}], "}"}], ",",
RowBox[{"{",
RowBox[{"n", ",", "1", ",", "N"}], "}"}]}], "]"}], "//",
"FullSimplify"}]}], "\[IndentingNewLine]"}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"num", "[",
RowBox[{"M_", ",", "N_"}], "]"}], ":=",
RowBox[{
FractionBox["1", "4"], " ", "M", " ",
RowBox[{"(",
RowBox[{"1", "+", "M"}], ")"}], " ", "N", " ",
RowBox[{"(",
RowBox[{"1", "+", "N"}], ")"}]}]}], "\[IndentingNewLine]",
RowBox[{"Solve", "[",
RowBox[{
RowBox[{
RowBox[{"num", "[",
RowBox[{"x", ",", "y"}], "]"}], "\[Equal]",
RowBox[{"2", "*",
RowBox[{"10", "^", "6"}]}]}], ",", "x", ",", "PositiveReals"}],
"]"}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"Solve", "[",
RowBox[{
RowBox[{
RowBox[{"num", "[",
RowBox[{"x", ",", "x"}], "]"}], "\[Equal]",
RowBox[{"2", "*",
RowBox[{"10", "^", "6"}]}]}], ",", "x", ",", "PositiveReals"}], "]"}],
"\[IndentingNewLine]"}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"f", "[", "y_", "]"}], ":=",
RowBox[{
RowBox[{"-",
FractionBox["1", "2"]}], "+",
RowBox[{
FractionBox["1", "2"], " ",
SqrtBox[
FractionBox[
RowBox[{"32000000", "+", "y", "+",
SuperscriptBox["y", "2"]}],
RowBox[{"y", " ",
RowBox[{"(",
RowBox[{"1", "+", "y"}], ")"}]}]]]}]}]}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"func", "[", "y_", "]"}], ":=",
RowBox[{
RowBox[{"f", "[", "y", "]"}], "//", "Round"}]}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"ntnm", "[", "x_", "]"}], ":=",
RowBox[{"{",
RowBox[{"x", ",",
RowBox[{"func", "[", "x", "]"}], ",",
RowBox[{"num", "[",
RowBox[{"x", ",",
RowBox[{"func", "[", "x", "]"}]}], "]"}], ",",
RowBox[{"Abs", "[",
RowBox[{
RowBox[{"num", "[",
RowBox[{"x", ",",
RowBox[{"func", "[", "x", "]"}]}], "]"}], "-",
RowBox[{"2", "*",
RowBox[{"10", "^", "6"}]}]}], "]"}]}], "}"}]}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"data", "=",
RowBox[{"Table", "[",
RowBox[{
RowBox[{"ntnm", "[", "n", "]"}], ",",
RowBox[{"{",
RowBox[{"n", ",", "1", ",", "53"}], "}"}]}], "]"}]}],
";"}], "\[IndentingNewLine]",
RowBox[{"Show", "[",
RowBox[{"{",
RowBox[{
RowBox[{"ListPlot", "@",
RowBox[{"(",
RowBox[{
RowBox[{
RowBox[{"#", "[",
RowBox[{"[",
RowBox[{"1", ";;", "2"}], "]"}], "]"}], "&"}], "/@", "data"}],
")"}]}], ",",
RowBox[{"Plot", "[",
RowBox[{
RowBox[{"f", "[", "x", "]"}], ",",
RowBox[{"{",
RowBox[{"x", ",", "1", ",", "53"}], "}"}]}], "]"}]}], "}"}],
"]"}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"res", "=",
RowBox[{"MinimalBy", "[",
RowBox[{"data", ",", "Last"}], "]"}]}], ";"}], "\[IndentingNewLine]",
RowBox[{"Times", "@@",
RowBox[{"res", "[",
RowBox[{"[",
RowBox[{"1", ",",
RowBox[{"1", ";;", "2"}]}], "]"}], "]"}]}]}], "Input",
CellChangeTimes->{{3.843913356165278*^9, 3.8439133804113636`*^9}, {
3.843913428192658*^9, 3.8439134480166807`*^9}, {3.8439136049945107`*^9,
3.843913645169319*^9}, {3.8439138104573154`*^9, 3.8439138941532574`*^9}, {
3.8439175712409973`*^9, 3.8439176174869685`*^9}, {3.8439176835161514`*^9,
3.8439176850494237`*^9}, 3.8439177234302874`*^9, 3.843918220817179*^9},
CellLabel->
"In[326]:=",ExpressionUUID->"08a8dd23-1a12-4fd4-8b21-6c8e95e03489"],
Cell[BoxData[
RowBox[{
FractionBox["1", "4"], " ", "M", " ",
RowBox[{"(",
RowBox[{"1", "+", "M"}], ")"}], " ", "N", " ",
RowBox[{"(",
RowBox[{"1", "+", "N"}], ")"}]}]], "Output",
CellChangeTimes->{{3.8439175864429135`*^9, 3.843917617688497*^9},
3.8439182450527306`*^9},
CellLabel->
"Out[326]=",ExpressionUUID->"dce7c935-0d38-490f-8471-10a053818b10"],
Cell[BoxData[
RowBox[{"{",
RowBox[{"{",
RowBox[{"x", "\[Rule]",
TemplateBox[{
RowBox[{
RowBox[{"-",
FractionBox["1", "2"]}], "+",
RowBox[{
FractionBox["1", "2"], " ",
SqrtBox[
FractionBox[
RowBox[{"32000000", "+", "y", "+",
SuperscriptBox["y", "2"]}],
RowBox[{"y", " ",
RowBox[{"(",
RowBox[{"1", "+", "y"}], ")"}]}]]]}]}],
RowBox[{"y", ">", "0"}]},
"ConditionalExpression"]}], "}"}], "}"}]], "Output",
CellChangeTimes->{{3.8439175864429135`*^9, 3.843917617688497*^9},
3.8439182450607095`*^9},
CellLabel->
"Out[328]=",ExpressionUUID->"77474442-c385-40de-92f7-b3e5f949463a"],
Cell[BoxData[
RowBox[{"{",
RowBox[{"{",
RowBox[{"x", "\[Rule]",
InterpretationBox[
TemplateBox[{"Root",
TemplateBox[{"\"52.7\"",
DynamicBox[
FEPrivate`FrontEndResource[
"FEExpressions", "NumericalApproximationElider"]]}, "RowDefault"],
TagBox[
RowBox[{"Root", "[",
RowBox[{
RowBox[{
RowBox[{
RowBox[{"-", "8000000"}], "+",
SuperscriptBox["#1", "2"], "+",
RowBox[{"2", " ",
SuperscriptBox["#1", "3"]}], "+",
SuperscriptBox["#1", "4"]}], "&"}], ",", "2"}], "]"}],
Short[#, 7]& ], 52.68530929444888},
"NumericalApproximation"],
Root[-8000000 + #^2 + 2 #^3 + #^4& , 2, 0]]}], "}"}], "}"}]], "Output",
CellChangeTimes->{{3.8439175864429135`*^9, 3.843917617688497*^9},
3.843918245064727*^9},
CellLabel->
"Out[329]=",ExpressionUUID->"9bba1fe0-e830-47a3-b85b-63279fee1f1f"],
Cell[BoxData[
GraphicsBox[{{{}, {
{RGBColor[0.368417, 0.506779, 0.709798], PointSize[
0.011000000000000001`], AbsoluteThickness[1.6], PointBox[CompressedData["
1:eJxdzrkuRFEYwPETlVKhUCgQERER+85c+76NfQljGRERRCQKzUlUOvECPMo8
gkfxCIbzm8Ykk39+33fPubfx7C5frAoh9JX/v02/79xfso/MILX6natT4yvX
pJZeuDa1IXJdavbM9alvT9yQ+vXITamfD9xsf88t3nfLre6/4Tbvv+b21MIV
dzh/yZ32Re5y/oK79Vx77M+41/tPuc99Be63P+EBPdZB33PEQ6nxkIf5gEd4
n0ed3+Mx3uVxrTjne3Y48/y2ezlwmPD8lj2XNu0n7TlyKW8/Zc+RSxv20/Yc
OVT2M+bryhmHWfM15cBhTlftOa6YzytHjsvmC8qx4iVdNP/X8vwH0/hUyQ==
"]]}, {
{RGBColor[0.368417, 0.506779, 0.709798], PointSize[
0.011000000000000001`], AbsoluteThickness[1.6]}, {}}, {
{RGBColor[0.368417, 0.506779, 0.709798], PointSize[
0.011000000000000001`], AbsoluteThickness[
1.6]}, {}}}, {{}, {}}}, {{{}, {},
TagBox[
{RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6],
Opacity[1.], LineBox[CompressedData["
1:eJwVlHk81QkXxgkvmRrbdSXLpUt2ylJ2D1nysy9xZclOdvfal0RhXkR8JmVL
aCrJkpS1QjKKsZc2aiZRWUeWTJj3vn+cz/eP53Oec54/zpH0Drf328XCwnKO
Wf9na/3TzFQVfqSZjrStX0lFr2aw4OJtfliOuf1YVEgFz7ycOLWdH8UccaMe
4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5ftHI21zrJDA/OnzGfcUc1uW2UiWPCIzSiihL6+YwyCLd
n2klUOor78XPQmA1+FpnWgOBQ0mW0zR+AsxHHTBYRsCl5uLXT0cIfK5a17oX
R8BycbVNWYuAaonSom8MAf3DLtmxOgQSY8AlFEVAqllScTcILEZfDE0KZ7K7
MVTRnMDHqc1NC38CaW/Gl+muBEbk+dl2HAhEiWl1tbsT4Ens5HpgRyDAsyyf
3ZPAmGY1PcyGOW/GT7XQlwDfq276B4IAeWWd0RrKZIGp5DNDAlwarsa7Igjs
3d4wOW9A4EfsY5IFnekXSR400CPwYTvz/jvmng8D1blaNJm+mE+XjieQtMXS
FsXM1XvO1ikskYBf6/jgYXUCLb1NB5uTCRjrFZouHSZQs1t4498UAjnKipK1
KgT+Bxjsjok=
"]]},
Annotation[#, "Charting`Private`Tag$40699#1"]& ]}, {}}},
AspectRatio->NCache[GoldenRatio^(-1), 0.6180339887498948],
Axes->{True, True},
AxesLabel->{None, None},
AxesOrigin->{0, 0},
DisplayFunction->Identity,
Frame->{{False, False}, {False, False}},
FrameLabel->{{None, None}, {None, None}},
FrameTicks->{{Automatic, Automatic}, {Automatic, Automatic}},
GridLines->{None, None},
GridLinesStyle->Directive[
GrayLevel[0.5, 0.4]],
Method->{
"OptimizePlotMarkers" -> True, "OptimizePlotMarkers" -> True,
"CoordinatesToolOptions" -> {"DisplayFunction" -> ({
Identity[
Part[#, 1]],
Identity[
Part[#, 2]]}& ), "CopiedValueFunction" -> ({
Identity[
Part[#, 1]],
Identity[
Part[#, 2]]}& )}},
PlotRange->{{0, 53.}, {0, 578.}},
PlotRangeClipping->True,
PlotRangePadding->{{
Scaled[0.02],
Scaled[0.02]}, {
Scaled[0.02],
Scaled[0.05]}},
Ticks->{Automatic, Automatic}]], "Output",
CellChangeTimes->{{3.8439175864429135`*^9, 3.843917617688497*^9},
3.843918245128552*^9},
CellLabel->
"Out[334]=",ExpressionUUID->"d7322218-eab3-4cfb-a3e3-d236c5057001"],
Cell[BoxData["2772"], "Output",
CellChangeTimes->{{3.8439175864429135`*^9, 3.843917617688497*^9},
3.843918245133542*^9},
CellLabel->
"Out[336]=",ExpressionUUID->"0225fa42-4d98-4123-8e17-2ec3e70dc9fc"]
}, Open ]]
},
WindowSize->{1920, 1037},
WindowMargins->{{-8, Automatic}, {Automatic, -8}},
FrontEndVersion->"12.1 for Microsoft Windows (64-bit) (March 14, 2020)",
StyleDefinitions->Notebook[{
Cell[
StyleData[StyleDefinitions -> "AS.nb"]]}, WindowSize -> {776, 872},
WindowMargins -> {{264, Automatic}, {17, Automatic}}, Visible -> False,
FrontEndVersion -> "12.1 for Microsoft Windows (64-bit) (March 14, 2020)",
StyleDefinitions -> "PrivateStylesheetFormatting.nb"],
ExpressionUUID->"914be5c2-3eeb-4c43-8ca3-f3984b45b7d1"
]
(* End of Notebook Content *)
(* Internal cache information *)
(*CellTagsOutline
CellTagsIndex->{}
*)
(*CellTagsIndex
CellTagsIndex->{}
*)
(*NotebookFileOutline
Notebook[{
Cell[CellGroupData[{
Cell[580, 22, 3795, 115, 493, "Input",ExpressionUUID->"08a8dd23-1a12-4fd4-8b21-6c8e95e03489"],
Cell[4378, 139, 374, 10, 70, "Output",ExpressionUUID->"dce7c935-0d38-490f-8471-10a053818b10"],
Cell[4755, 151, 743, 22, 106, "Output",ExpressionUUID->"77474442-c385-40de-92f7-b3e5f949463a"],
Cell[5501, 175, 988, 26, 56, "Output",ExpressionUUID->"9bba1fe0-e830-47a3-b85b-63279fee1f1f"],
Cell[6492, 203, 4913, 101, 253, "Output",ExpressionUUID->"d7322218-eab3-4cfb-a3e3-d236c5057001"],
Cell[11408, 306, 208, 4, 47, "Output",ExpressionUUID->"0225fa42-4d98-4123-8e17-2ec3e70dc9fc"]
}, Open ]]
}
]
*)