-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbilliardRust.nb
2959 lines (2917 loc) · 162 KB
/
billiardRust.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
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
(* Content-type: application/vnd.wolfram.mathematica *)
(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)
(* CreatedBy='Mathematica 14.0' *)
(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[ 158, 7]
NotebookDataLength[ 166107, 2951]
NotebookOptionsPosition[ 165199, 2928]
NotebookOutlinePosition[ 165594, 2944]
CellTagsIndexPosition[ 165551, 2941]
WindowFrame->Normal*)
(* Beginning of Notebook Content *)
Notebook[{
Cell[CellGroupData[{
Cell[BoxData[{
RowBox[{
RowBox[{
RowBox[{
"libraryPath", " ", "=", " ",
"\"\<PATH TO LIBRARY/libbilliard.dylib\>\""}], ";"}], " ",
RowBox[{"(*", " ",
RowBox[{"CHANGE", " ", "THIS"}], " ", "*)"}]}], "\[IndentingNewLine]",
RowBox[{"billmin", "=",
RowBox[{"LibraryFunctionLoad", "[",
RowBox[{"libraryPath", ",", "\"\<minimize\>\"", ",",
RowBox[{"{",
RowBox[{
"Real", ",", " ", "Real", ",", " ", "Integer", ",", " ", "Real"}], "}"}],
",", "NumericArray"}], "]"}]}], "\[IndentingNewLine]",
RowBox[{"zout", "=",
RowBox[{"LibraryFunctionLoad", "[",
RowBox[{"libraryPath", ",", "\"\<zoutside\>\"", ",",
RowBox[{"{",
RowBox[{"Real", ",", " ", "Real"}], "}"}], ",", "NumericArray"}],
"]"}]}], "\[IndentingNewLine]",
RowBox[{"zin", "=",
RowBox[{"LibraryFunctionLoad", "[",
RowBox[{"libraryPath", ",", "\"\<zinside\>\"", ",",
RowBox[{"{",
RowBox[{"Real", ",", " ", "Real"}], "}"}], ",", "NumericArray"}],
"]"}]}]}], "Input",
CellChangeTimes->{{3.932596090116107*^9, 3.9325961584091043`*^9}, {
3.932596242782592*^9, 3.932596354046733*^9}, {3.932596422589484*^9,
3.932596424733213*^9}, {3.932640188395731*^9, 3.932640236193696*^9}, {
3.932640305056155*^9, 3.932640326799648*^9}, {3.932640418892548*^9,
3.932640419360991*^9}, {3.932640479405363*^9, 3.932640489718451*^9}, {
3.933518535514233*^9, 3.933518539201284*^9}, {3.937996766289793*^9,
3.937996805034506*^9}, {3.937997126206772*^9, 3.937997156089366*^9}, {
3.937997211058592*^9,
3.93799723442056*^9}},ExpressionUUID->"0817ebeb-316c-4d3c-9a7b-\
f1f8470b4164"],
Cell[BoxData[
InterpretationBox[
RowBox[{
TagBox["LibraryFunction",
"SummaryHead"], "[",
DynamicModuleBox[{Typeset`open$$ = False, Typeset`embedState$$ = "Ready"},
TemplateBox[{
PaneSelectorBox[{False -> GridBox[{{
PaneBox[
ButtonBox[
DynamicBox[
FEPrivate`FrontEndResource["FEBitmaps", "SummaryBoxOpener"]],
ButtonFunction :> (Typeset`open$$ = True), Appearance -> None,
BaseStyle -> {}, Evaluator -> Automatic, Method ->
"Preemptive"], Alignment -> {Center, Center}, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}]],
GraphicsBox[{
Thickness[0.038461538461538464`], {
FaceForm[{
GrayLevel[0.93],
Opacity[1.]}],
FilledCurveBox[{{{1, 4, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}, {
1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}}}, {{{
25.499999999999996`, 2.5}, {25.499999999999996`,
1.3953100000000003`}, {24.604699999999998`,
0.49999999999999994`}, {23.5, 0.49999999999999994`}, {2.5,
0.49999999999999994`}, {1.3953100000000003`,
0.49999999999999994`}, {0.49999999999999994`,
1.3953100000000003`}, {0.49999999999999994`, 2.5}, {
0.49999999999999994`, 23.5}, {0.49999999999999994`,
24.604699999999998`}, {1.3953100000000003`,
25.499999999999996`}, {2.5, 25.499999999999996`}, {23.5,
25.499999999999996`}, {24.604699999999998`,
25.499999999999996`}, {25.499999999999996`,
24.604699999999998`}, {25.499999999999996`, 23.5}, {
25.499999999999996`, 2.5}}}]}, {
FaceForm[{
RGBColor[0.5, 0.5, 0.5],
Opacity[1.]}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{20.5426,
19.116799999999998`}, {16.3832, 21.876199999999997`}, {
16.3832, 20.021499999999996`}, {6.930469999999999,
20.021499999999996`}, {6.930469999999999,
18.212100000000003`}, {16.3832, 18.212100000000003`}, {
16.3832, 16.357399999999995`}, {20.5426,
19.116799999999998`}}}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{5.30508, 13.8391}, {
9.46445, 11.079700000000003`}, {9.46445,
12.933999999999997`}, {18.917199999999998`,
12.933999999999997`}, {18.917199999999998`, 14.7438}, {
9.46445, 14.7438}, {9.46445, 16.598}, {5.30508, 13.8391}}}],
FilledCurveBox[{{{1, 4, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {
0, 1, 0}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3,
3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {1,
3, 3}, {1, 3, 3}, {1, 3, 3}}}, CompressedData["
1:eJxTTMoPSmVmYGBgBGJjIGYCYq4u+eR3VWoOxhkv5j+Qk3SA8fu/r5rKOVHM
Yd2vmNyjZ9Qcrt9QXbW9S8RBg59767IidQcPMYPGaHFhB+Nn61SfiGo4xBwp
T7o2V9Dh0Iolfg6/NBxEHv/x1Xgi4FB1XNNqkqQWnP+axUTQjFkbzn+oO2HB
j/3aDg/Xn5T6WiDoYLs3aJpiqI7DrHN+bO6tQg4zfUR7vF7pQOyfIQyRd9d1
WLL0U1kLoyjEPdm6DpoTXfQX7xBzKPjQejLkhDacL5J4+LL2Gm2HtNnSl4Vf
iELM69J2qPZM3tLnJerQX1oozZugDfHPUxGI/4W1HQ5p3TthoyDi4D7lG1v8
Mi2HgqL9zoEHhB1inOxe3BRG8MH62zXhfIbN1Z82CGhC/GMg4nCm3mN/7TYN
iHlCUPdGakDc/1kUEr46GhD/eYnD+d9iBf/kC0vC+TuCrSL+X5Vy2HGR4R5T
uAbEfxYykPBYp+HQqsCuesZAFhL+rJoQ/2rIQdxTpwkJ7yVycPfD+GDzVqLx
xbUd5HYt2JfqBdWfpA2Jj9mykPDpgYaXtaxDy7yzq86vg8qvlIHE5ylY/Eo7
XAt7o787TxfOB5ufqesQ9PbyxxkPZSDhZ6nrMAGU3u7LQtLLEx2HN2253UbX
ofZ76jis/Pay4oynAsT8QG0HKZMv/gW7FCDyTFpwPsz/MD44/Mw1HFjb1uR9
TVVwWKy880/7FHWIexrkIfLX1RzOMDZZVjHIOaDkh3vSDuj5AwCF11Vc
"]]}}, Background -> GrayLevel[0.93], Axes -> False,
AspectRatio -> 1, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}], Frame -> True, FrameTicks -> None,
FrameStyle -> Directive[
Thickness[Tiny],
GrayLevel[0.7]]],
GridBox[{{
RowBox[{
TagBox["\"Function name: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"minimize\"", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument count: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["4", "SummaryItem"]}]}},
GridBoxAlignment -> {
"Columns" -> {{Left}}, "Rows" -> {{Automatic}}}, AutoDelete ->
False, GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
GridBoxSpacings -> {"Columns" -> {{2}}, "Rows" -> {{Automatic}}},
BaseStyle -> {
ShowStringCharacters -> False, NumberMarks -> False,
PrintPrecision -> 3, ShowSyntaxStyles -> False}]}},
GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}},
AutoDelete -> False,
GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
BaselinePosition -> {1, 1}], True -> GridBox[{{
PaneBox[
ButtonBox[
DynamicBox[
FEPrivate`FrontEndResource["FEBitmaps", "SummaryBoxCloser"]],
ButtonFunction :> (Typeset`open$$ = False), Appearance -> None,
BaseStyle -> {}, Evaluator -> Automatic, Method ->
"Preemptive"], Alignment -> {Center, Center}, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}]],
GraphicsBox[{
Thickness[0.038461538461538464`], {
FaceForm[{
GrayLevel[0.93],
Opacity[1.]}],
FilledCurveBox[{{{1, 4, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}, {
1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}}}, {{{
25.499999999999996`, 2.5}, {25.499999999999996`,
1.3953100000000003`}, {24.604699999999998`,
0.49999999999999994`}, {23.5, 0.49999999999999994`}, {2.5,
0.49999999999999994`}, {1.3953100000000003`,
0.49999999999999994`}, {0.49999999999999994`,
1.3953100000000003`}, {0.49999999999999994`, 2.5}, {
0.49999999999999994`, 23.5}, {0.49999999999999994`,
24.604699999999998`}, {1.3953100000000003`,
25.499999999999996`}, {2.5, 25.499999999999996`}, {23.5,
25.499999999999996`}, {24.604699999999998`,
25.499999999999996`}, {25.499999999999996`,
24.604699999999998`}, {25.499999999999996`, 23.5}, {
25.499999999999996`, 2.5}}}]}, {
FaceForm[{
RGBColor[0.5, 0.5, 0.5],
Opacity[1.]}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{20.5426,
19.116799999999998`}, {16.3832, 21.876199999999997`}, {
16.3832, 20.021499999999996`}, {6.930469999999999,
20.021499999999996`}, {6.930469999999999,
18.212100000000003`}, {16.3832, 18.212100000000003`}, {
16.3832, 16.357399999999995`}, {20.5426,
19.116799999999998`}}}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{5.30508, 13.8391}, {
9.46445, 11.079700000000003`}, {9.46445,
12.933999999999997`}, {18.917199999999998`,
12.933999999999997`}, {18.917199999999998`, 14.7438}, {
9.46445, 14.7438}, {9.46445, 16.598}, {5.30508, 13.8391}}}],
FilledCurveBox[{{{1, 4, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {
0, 1, 0}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3,
3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {1,
3, 3}, {1, 3, 3}, {1, 3, 3}}}, CompressedData["
1:eJxTTMoPSmVmYGBgBGJjIGYCYq4u+eR3VWoOxhkv5j+Qk3SA8fu/r5rKOVHM
Yd2vmNyjZ9Qcrt9QXbW9S8RBg59767IidQcPMYPGaHFhB+Nn61SfiGo4xBwp
T7o2V9Dh0Iolfg6/NBxEHv/x1Xgi4FB1XNNqkqQWnP+axUTQjFkbzn+oO2HB
j/3aDg/Xn5T6WiDoYLs3aJpiqI7DrHN+bO6tQg4zfUR7vF7pQOyfIQyRd9d1
WLL0U1kLoyjEPdm6DpoTXfQX7xBzKPjQejLkhDacL5J4+LL2Gm2HtNnSl4Vf
iELM69J2qPZM3tLnJerQX1oozZugDfHPUxGI/4W1HQ5p3TthoyDi4D7lG1v8
Mi2HgqL9zoEHhB1inOxe3BRG8MH62zXhfIbN1Z82CGhC/GMg4nCm3mN/7TYN
iHlCUPdGakDc/1kUEr46GhD/eYnD+d9iBf/kC0vC+TuCrSL+X5Vy2HGR4R5T
uAbEfxYykPBYp+HQqsCuesZAFhL+rJoQ/2rIQdxTpwkJ7yVycPfD+GDzVqLx
xbUd5HYt2JfqBdWfpA2Jj9mykPDpgYaXtaxDy7yzq86vg8qvlIHE5ylY/Eo7
XAt7o787TxfOB5ufqesQ9PbyxxkPZSDhZ6nrMAGU3u7LQtLLEx2HN2253UbX
ofZ76jis/Pay4oynAsT8QG0HKZMv/gW7FCDyTFpwPsz/MD44/Mw1HFjb1uR9
TVVwWKy880/7FHWIexrkIfLX1RzOMDZZVjHIOaDkh3vSDuj5AwCF11Vc
"]]}}, Background -> GrayLevel[0.93], Axes -> False,
AspectRatio -> 1, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}], Frame -> True, FrameTicks -> None,
FrameStyle -> Directive[
Thickness[Tiny],
GrayLevel[0.7]]],
GridBox[{{
RowBox[{
TagBox["\"Function name: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"minimize\"", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument count: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["4", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument types: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox[
PaneBox[
RowBox[{"{",
RowBox[{
"Real", ",", "Real", ",", "Integer", ",", "Real"}], "}"}],
ImageSize -> {{1, 500}, Automatic}, BaselinePosition ->
Baseline, ContentPadding -> False, FrameMargins -> 0,
StripOnInput -> True], "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Return type: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox[
PaneBox[
"NumericArray", ImageSize -> {{1, 500}, Automatic},
BaselinePosition -> Baseline, ContentPadding -> False,
FrameMargins -> 0, StripOnInput -> True],
"SummaryItem"]}]}, {
RowBox[{
TagBox["\"Library: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"libbilliard.dylib\"", "SummaryItem"]}]}},
GridBoxAlignment -> {
"Columns" -> {{Left}}, "Rows" -> {{Automatic}}}, AutoDelete ->
False, GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
GridBoxSpacings -> {"Columns" -> {{2}}, "Rows" -> {{Automatic}}},
BaseStyle -> {
ShowStringCharacters -> False, NumberMarks -> False,
PrintPrecision -> 3, ShowSyntaxStyles -> False}]}},
GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}},
AutoDelete -> False,
GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
BaselinePosition -> {1, 1}]},
Dynamic[Typeset`open$$], ImageSize -> Automatic]},
"SummaryPanel"],
DynamicModuleValues:>{}], "]"}],
LibraryFunction[
"/Users/nolanking/projects/lib_billiard/target/release/libbilliard.dylib",
"minimize", {Real, Real, Integer, Real}, NumericArray],
Editable->False,
SelectWithContents->True,
Selectable->False]], "Output",
CellChangeTimes->{
3.9335185408571*^9, {3.933518875017688*^9, 3.933518894870737*^9},
3.9335190884358807`*^9, 3.933519162535952*^9, 3.934447870105233*^9, {
3.934448202924694*^9, 3.934448221223118*^9}, 3.934448969601499*^9,
3.934453020561111*^9, 3.9355065294174423`*^9, 3.935506628654714*^9,
3.935506882538547*^9, 3.935508089990285*^9, 3.937306108670595*^9,
3.937306160060873*^9, {3.937306330312579*^9, 3.937306344360024*^9},
3.9373064476798077`*^9, 3.937306854778968*^9, 3.937307210253695*^9,
3.937307437984601*^9, 3.937307546678658*^9, 3.937307701298157*^9,
3.9373081005596533`*^9, 3.937309122160757*^9, 3.9373805409223576`*^9,
3.937380697927469*^9, 3.937381459745623*^9, 3.937381618714484*^9,
3.937997164662998*^9},
CellLabel->"Out[2]=",ExpressionUUID->"63770954-08ef-4808-af5e-9aa6ee6a6581"],
Cell[BoxData[
InterpretationBox[
RowBox[{
TagBox["LibraryFunction",
"SummaryHead"], "[",
DynamicModuleBox[{Typeset`open$$ = False, Typeset`embedState$$ = "Ready"},
TemplateBox[{
PaneSelectorBox[{False -> GridBox[{{
PaneBox[
ButtonBox[
DynamicBox[
FEPrivate`FrontEndResource["FEBitmaps", "SummaryBoxOpener"]],
ButtonFunction :> (Typeset`open$$ = True), Appearance -> None,
BaseStyle -> {}, Evaluator -> Automatic, Method ->
"Preemptive"], Alignment -> {Center, Center}, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}]],
GraphicsBox[{
Thickness[0.038461538461538464`], {
FaceForm[{
GrayLevel[0.93],
Opacity[1.]}],
FilledCurveBox[{{{1, 4, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}, {
1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}}}, {{{
25.499999999999996`, 2.5}, {25.499999999999996`,
1.3953100000000003`}, {24.604699999999998`,
0.49999999999999994`}, {23.5, 0.49999999999999994`}, {2.5,
0.49999999999999994`}, {1.3953100000000003`,
0.49999999999999994`}, {0.49999999999999994`,
1.3953100000000003`}, {0.49999999999999994`, 2.5}, {
0.49999999999999994`, 23.5}, {0.49999999999999994`,
24.604699999999998`}, {1.3953100000000003`,
25.499999999999996`}, {2.5, 25.499999999999996`}, {23.5,
25.499999999999996`}, {24.604699999999998`,
25.499999999999996`}, {25.499999999999996`,
24.604699999999998`}, {25.499999999999996`, 23.5}, {
25.499999999999996`, 2.5}}}]}, {
FaceForm[{
RGBColor[0.5, 0.5, 0.5],
Opacity[1.]}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{20.5426,
19.116799999999998`}, {16.3832, 21.876199999999997`}, {
16.3832, 20.021499999999996`}, {6.930469999999999,
20.021499999999996`}, {6.930469999999999,
18.212100000000003`}, {16.3832, 18.212100000000003`}, {
16.3832, 16.357399999999995`}, {20.5426,
19.116799999999998`}}}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{5.30508, 13.8391}, {
9.46445, 11.079700000000003`}, {9.46445,
12.933999999999997`}, {18.917199999999998`,
12.933999999999997`}, {18.917199999999998`, 14.7438}, {
9.46445, 14.7438}, {9.46445, 16.598}, {5.30508, 13.8391}}}],
FilledCurveBox[{{{1, 4, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {
0, 1, 0}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3,
3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {1,
3, 3}, {1, 3, 3}, {1, 3, 3}}}, CompressedData["
1:eJxTTMoPSmVmYGBgBGJjIGYCYq4u+eR3VWoOxhkv5j+Qk3SA8fu/r5rKOVHM
Yd2vmNyjZ9Qcrt9QXbW9S8RBg59767IidQcPMYPGaHFhB+Nn61SfiGo4xBwp
T7o2V9Dh0Iolfg6/NBxEHv/x1Xgi4FB1XNNqkqQWnP+axUTQjFkbzn+oO2HB
j/3aDg/Xn5T6WiDoYLs3aJpiqI7DrHN+bO6tQg4zfUR7vF7pQOyfIQyRd9d1
WLL0U1kLoyjEPdm6DpoTXfQX7xBzKPjQejLkhDacL5J4+LL2Gm2HtNnSl4Vf
iELM69J2qPZM3tLnJerQX1oozZugDfHPUxGI/4W1HQ5p3TthoyDi4D7lG1v8
Mi2HgqL9zoEHhB1inOxe3BRG8MH62zXhfIbN1Z82CGhC/GMg4nCm3mN/7TYN
iHlCUPdGakDc/1kUEr46GhD/eYnD+d9iBf/kC0vC+TuCrSL+X5Vy2HGR4R5T
uAbEfxYykPBYp+HQqsCuesZAFhL+rJoQ/2rIQdxTpwkJ7yVycPfD+GDzVqLx
xbUd5HYt2JfqBdWfpA2Jj9mykPDpgYaXtaxDy7yzq86vg8qvlIHE5ylY/Eo7
XAt7o787TxfOB5ufqesQ9PbyxxkPZSDhZ6nrMAGU3u7LQtLLEx2HN2253UbX
ofZ76jis/Pay4oynAsT8QG0HKZMv/gW7FCDyTFpwPsz/MD44/Mw1HFjb1uR9
TVVwWKy880/7FHWIexrkIfLX1RzOMDZZVjHIOaDkh3vSDuj5AwCF11Vc
"]]}}, Background -> GrayLevel[0.93], Axes -> False,
AspectRatio -> 1, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}], Frame -> True, FrameTicks -> None,
FrameStyle -> Directive[
Thickness[Tiny],
GrayLevel[0.7]]],
GridBox[{{
RowBox[{
TagBox["\"Function name: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"zoutside\"", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument count: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["2", "SummaryItem"]}]}},
GridBoxAlignment -> {
"Columns" -> {{Left}}, "Rows" -> {{Automatic}}}, AutoDelete ->
False, GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
GridBoxSpacings -> {"Columns" -> {{2}}, "Rows" -> {{Automatic}}},
BaseStyle -> {
ShowStringCharacters -> False, NumberMarks -> False,
PrintPrecision -> 3, ShowSyntaxStyles -> False}]}},
GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}},
AutoDelete -> False,
GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
BaselinePosition -> {1, 1}], True -> GridBox[{{
PaneBox[
ButtonBox[
DynamicBox[
FEPrivate`FrontEndResource["FEBitmaps", "SummaryBoxCloser"]],
ButtonFunction :> (Typeset`open$$ = False), Appearance -> None,
BaseStyle -> {}, Evaluator -> Automatic, Method ->
"Preemptive"], Alignment -> {Center, Center}, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}]],
GraphicsBox[{
Thickness[0.038461538461538464`], {
FaceForm[{
GrayLevel[0.93],
Opacity[1.]}],
FilledCurveBox[{{{1, 4, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}, {
1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}}}, {{{
25.499999999999996`, 2.5}, {25.499999999999996`,
1.3953100000000003`}, {24.604699999999998`,
0.49999999999999994`}, {23.5, 0.49999999999999994`}, {2.5,
0.49999999999999994`}, {1.3953100000000003`,
0.49999999999999994`}, {0.49999999999999994`,
1.3953100000000003`}, {0.49999999999999994`, 2.5}, {
0.49999999999999994`, 23.5}, {0.49999999999999994`,
24.604699999999998`}, {1.3953100000000003`,
25.499999999999996`}, {2.5, 25.499999999999996`}, {23.5,
25.499999999999996`}, {24.604699999999998`,
25.499999999999996`}, {25.499999999999996`,
24.604699999999998`}, {25.499999999999996`, 23.5}, {
25.499999999999996`, 2.5}}}]}, {
FaceForm[{
RGBColor[0.5, 0.5, 0.5],
Opacity[1.]}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{20.5426,
19.116799999999998`}, {16.3832, 21.876199999999997`}, {
16.3832, 20.021499999999996`}, {6.930469999999999,
20.021499999999996`}, {6.930469999999999,
18.212100000000003`}, {16.3832, 18.212100000000003`}, {
16.3832, 16.357399999999995`}, {20.5426,
19.116799999999998`}}}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{5.30508, 13.8391}, {
9.46445, 11.079700000000003`}, {9.46445,
12.933999999999997`}, {18.917199999999998`,
12.933999999999997`}, {18.917199999999998`, 14.7438}, {
9.46445, 14.7438}, {9.46445, 16.598}, {5.30508, 13.8391}}}],
FilledCurveBox[{{{1, 4, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {
0, 1, 0}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3,
3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {1,
3, 3}, {1, 3, 3}, {1, 3, 3}}}, CompressedData["
1:eJxTTMoPSmVmYGBgBGJjIGYCYq4u+eR3VWoOxhkv5j+Qk3SA8fu/r5rKOVHM
Yd2vmNyjZ9Qcrt9QXbW9S8RBg59767IidQcPMYPGaHFhB+Nn61SfiGo4xBwp
T7o2V9Dh0Iolfg6/NBxEHv/x1Xgi4FB1XNNqkqQWnP+axUTQjFkbzn+oO2HB
j/3aDg/Xn5T6WiDoYLs3aJpiqI7DrHN+bO6tQg4zfUR7vF7pQOyfIQyRd9d1
WLL0U1kLoyjEPdm6DpoTXfQX7xBzKPjQejLkhDacL5J4+LL2Gm2HtNnSl4Vf
iELM69J2qPZM3tLnJerQX1oozZugDfHPUxGI/4W1HQ5p3TthoyDi4D7lG1v8
Mi2HgqL9zoEHhB1inOxe3BRG8MH62zXhfIbN1Z82CGhC/GMg4nCm3mN/7TYN
iHlCUPdGakDc/1kUEr46GhD/eYnD+d9iBf/kC0vC+TuCrSL+X5Vy2HGR4R5T
uAbEfxYykPBYp+HQqsCuesZAFhL+rJoQ/2rIQdxTpwkJ7yVycPfD+GDzVqLx
xbUd5HYt2JfqBdWfpA2Jj9mykPDpgYaXtaxDy7yzq86vg8qvlIHE5ylY/Eo7
XAt7o787TxfOB5ufqesQ9PbyxxkPZSDhZ6nrMAGU3u7LQtLLEx2HN2253UbX
ofZ76jis/Pay4oynAsT8QG0HKZMv/gW7FCDyTFpwPsz/MD44/Mw1HFjb1uR9
TVVwWKy880/7FHWIexrkIfLX1RzOMDZZVjHIOaDkh3vSDuj5AwCF11Vc
"]]}}, Background -> GrayLevel[0.93], Axes -> False,
AspectRatio -> 1, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}], Frame -> True, FrameTicks -> None,
FrameStyle -> Directive[
Thickness[Tiny],
GrayLevel[0.7]]],
GridBox[{{
RowBox[{
TagBox["\"Function name: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"zoutside\"", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument count: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["2", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument types: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox[
PaneBox[
RowBox[{"{",
RowBox[{"Real", ",", "Real"}], "}"}],
ImageSize -> {{1, 500}, Automatic}, BaselinePosition ->
Baseline, ContentPadding -> False, FrameMargins -> 0,
StripOnInput -> True], "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Return type: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox[
PaneBox[
"NumericArray", ImageSize -> {{1, 500}, Automatic},
BaselinePosition -> Baseline, ContentPadding -> False,
FrameMargins -> 0, StripOnInput -> True],
"SummaryItem"]}]}, {
RowBox[{
TagBox["\"Library: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"libbilliard.dylib\"", "SummaryItem"]}]}},
GridBoxAlignment -> {
"Columns" -> {{Left}}, "Rows" -> {{Automatic}}}, AutoDelete ->
False, GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
GridBoxSpacings -> {"Columns" -> {{2}}, "Rows" -> {{Automatic}}},
BaseStyle -> {
ShowStringCharacters -> False, NumberMarks -> False,
PrintPrecision -> 3, ShowSyntaxStyles -> False}]}},
GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}},
AutoDelete -> False,
GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
BaselinePosition -> {1, 1}]},
Dynamic[Typeset`open$$], ImageSize -> Automatic]},
"SummaryPanel"],
DynamicModuleValues:>{}], "]"}],
LibraryFunction[
"/Users/nolanking/projects/lib_billiard/target/release/libbilliard.dylib",
"zoutside", {Real, Real}, NumericArray],
Editable->False,
SelectWithContents->True,
Selectable->False]], "Output",
CellChangeTimes->{
3.9335185408571*^9, {3.933518875017688*^9, 3.933518894870737*^9},
3.9335190884358807`*^9, 3.933519162535952*^9, 3.934447870105233*^9, {
3.934448202924694*^9, 3.934448221223118*^9}, 3.934448969601499*^9,
3.934453020561111*^9, 3.9355065294174423`*^9, 3.935506628654714*^9,
3.935506882538547*^9, 3.935508089990285*^9, 3.937306108670595*^9,
3.937306160060873*^9, {3.937306330312579*^9, 3.937306344360024*^9},
3.9373064476798077`*^9, 3.937306854778968*^9, 3.937307210253695*^9,
3.937307437984601*^9, 3.937307546678658*^9, 3.937307701298157*^9,
3.9373081005596533`*^9, 3.937309122160757*^9, 3.9373805409223576`*^9,
3.937380697927469*^9, 3.937381459745623*^9, 3.937381618714484*^9,
3.93799716467309*^9},
CellLabel->"Out[3]=",ExpressionUUID->"8c3ba492-144a-4fdc-a827-ad59671d49de"],
Cell[BoxData[
InterpretationBox[
RowBox[{
TagBox["LibraryFunction",
"SummaryHead"], "[",
DynamicModuleBox[{Typeset`open$$ = False, Typeset`embedState$$ = "Ready"},
TemplateBox[{
PaneSelectorBox[{False -> GridBox[{{
PaneBox[
ButtonBox[
DynamicBox[
FEPrivate`FrontEndResource["FEBitmaps", "SummaryBoxOpener"]],
ButtonFunction :> (Typeset`open$$ = True), Appearance -> None,
BaseStyle -> {}, Evaluator -> Automatic, Method ->
"Preemptive"], Alignment -> {Center, Center}, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}]],
GraphicsBox[{
Thickness[0.038461538461538464`], {
FaceForm[{
GrayLevel[0.93],
Opacity[1.]}],
FilledCurveBox[{{{1, 4, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}, {
1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}}}, {{{
25.499999999999996`, 2.5}, {25.499999999999996`,
1.3953100000000003`}, {24.604699999999998`,
0.49999999999999994`}, {23.5, 0.49999999999999994`}, {2.5,
0.49999999999999994`}, {1.3953100000000003`,
0.49999999999999994`}, {0.49999999999999994`,
1.3953100000000003`}, {0.49999999999999994`, 2.5}, {
0.49999999999999994`, 23.5}, {0.49999999999999994`,
24.604699999999998`}, {1.3953100000000003`,
25.499999999999996`}, {2.5, 25.499999999999996`}, {23.5,
25.499999999999996`}, {24.604699999999998`,
25.499999999999996`}, {25.499999999999996`,
24.604699999999998`}, {25.499999999999996`, 23.5}, {
25.499999999999996`, 2.5}}}]}, {
FaceForm[{
RGBColor[0.5, 0.5, 0.5],
Opacity[1.]}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{20.5426,
19.116799999999998`}, {16.3832, 21.876199999999997`}, {
16.3832, 20.021499999999996`}, {6.930469999999999,
20.021499999999996`}, {6.930469999999999,
18.212100000000003`}, {16.3832, 18.212100000000003`}, {
16.3832, 16.357399999999995`}, {20.5426,
19.116799999999998`}}}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{5.30508, 13.8391}, {
9.46445, 11.079700000000003`}, {9.46445,
12.933999999999997`}, {18.917199999999998`,
12.933999999999997`}, {18.917199999999998`, 14.7438}, {
9.46445, 14.7438}, {9.46445, 16.598}, {5.30508, 13.8391}}}],
FilledCurveBox[{{{1, 4, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {
0, 1, 0}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3,
3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {1,
3, 3}, {1, 3, 3}, {1, 3, 3}}}, CompressedData["
1:eJxTTMoPSmVmYGBgBGJjIGYCYq4u+eR3VWoOxhkv5j+Qk3SA8fu/r5rKOVHM
Yd2vmNyjZ9Qcrt9QXbW9S8RBg59767IidQcPMYPGaHFhB+Nn61SfiGo4xBwp
T7o2V9Dh0Iolfg6/NBxEHv/x1Xgi4FB1XNNqkqQWnP+axUTQjFkbzn+oO2HB
j/3aDg/Xn5T6WiDoYLs3aJpiqI7DrHN+bO6tQg4zfUR7vF7pQOyfIQyRd9d1
WLL0U1kLoyjEPdm6DpoTXfQX7xBzKPjQejLkhDacL5J4+LL2Gm2HtNnSl4Vf
iELM69J2qPZM3tLnJerQX1oozZugDfHPUxGI/4W1HQ5p3TthoyDi4D7lG1v8
Mi2HgqL9zoEHhB1inOxe3BRG8MH62zXhfIbN1Z82CGhC/GMg4nCm3mN/7TYN
iHlCUPdGakDc/1kUEr46GhD/eYnD+d9iBf/kC0vC+TuCrSL+X5Vy2HGR4R5T
uAbEfxYykPBYp+HQqsCuesZAFhL+rJoQ/2rIQdxTpwkJ7yVycPfD+GDzVqLx
xbUd5HYt2JfqBdWfpA2Jj9mykPDpgYaXtaxDy7yzq86vg8qvlIHE5ylY/Eo7
XAt7o787TxfOB5ufqesQ9PbyxxkPZSDhZ6nrMAGU3u7LQtLLEx2HN2253UbX
ofZ76jis/Pay4oynAsT8QG0HKZMv/gW7FCDyTFpwPsz/MD44/Mw1HFjb1uR9
TVVwWKy880/7FHWIexrkIfLX1RzOMDZZVjHIOaDkh3vSDuj5AwCF11Vc
"]]}}, Background -> GrayLevel[0.93], Axes -> False,
AspectRatio -> 1, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}], Frame -> True, FrameTicks -> None,
FrameStyle -> Directive[
Thickness[Tiny],
GrayLevel[0.7]]],
GridBox[{{
RowBox[{
TagBox["\"Function name: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"zinside\"", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument count: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["2", "SummaryItem"]}]}},
GridBoxAlignment -> {
"Columns" -> {{Left}}, "Rows" -> {{Automatic}}}, AutoDelete ->
False, GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
GridBoxSpacings -> {"Columns" -> {{2}}, "Rows" -> {{Automatic}}},
BaseStyle -> {
ShowStringCharacters -> False, NumberMarks -> False,
PrintPrecision -> 3, ShowSyntaxStyles -> False}]}},
GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}},
AutoDelete -> False,
GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
BaselinePosition -> {1, 1}], True -> GridBox[{{
PaneBox[
ButtonBox[
DynamicBox[
FEPrivate`FrontEndResource["FEBitmaps", "SummaryBoxCloser"]],
ButtonFunction :> (Typeset`open$$ = False), Appearance -> None,
BaseStyle -> {}, Evaluator -> Automatic, Method ->
"Preemptive"], Alignment -> {Center, Center}, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}]],
GraphicsBox[{
Thickness[0.038461538461538464`], {
FaceForm[{
GrayLevel[0.93],
Opacity[1.]}],
FilledCurveBox[{{{1, 4, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}, {
1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {0, 1, 0}}}, {{{
25.499999999999996`, 2.5}, {25.499999999999996`,
1.3953100000000003`}, {24.604699999999998`,
0.49999999999999994`}, {23.5, 0.49999999999999994`}, {2.5,
0.49999999999999994`}, {1.3953100000000003`,
0.49999999999999994`}, {0.49999999999999994`,
1.3953100000000003`}, {0.49999999999999994`, 2.5}, {
0.49999999999999994`, 23.5}, {0.49999999999999994`,
24.604699999999998`}, {1.3953100000000003`,
25.499999999999996`}, {2.5, 25.499999999999996`}, {23.5,
25.499999999999996`}, {24.604699999999998`,
25.499999999999996`}, {25.499999999999996`,
24.604699999999998`}, {25.499999999999996`, 23.5}, {
25.499999999999996`, 2.5}}}]}, {
FaceForm[{
RGBColor[0.5, 0.5, 0.5],
Opacity[1.]}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{20.5426,
19.116799999999998`}, {16.3832, 21.876199999999997`}, {
16.3832, 20.021499999999996`}, {6.930469999999999,
20.021499999999996`}, {6.930469999999999,
18.212100000000003`}, {16.3832, 18.212100000000003`}, {
16.3832, 16.357399999999995`}, {20.5426,
19.116799999999998`}}}],
FilledCurveBox[{{{0, 2, 0}, {0, 1, 0}, {0, 1, 0}, {0, 1, 0}, {
0, 1, 0}, {0, 1, 0}, {0, 1, 0}}}, {{{5.30508, 13.8391}, {
9.46445, 11.079700000000003`}, {9.46445,
12.933999999999997`}, {18.917199999999998`,
12.933999999999997`}, {18.917199999999998`, 14.7438}, {
9.46445, 14.7438}, {9.46445, 16.598}, {5.30508, 13.8391}}}],
FilledCurveBox[{{{1, 4, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {
0, 1, 0}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {1, 3,
3}, {1, 3, 3}, {1, 3, 3}, {1, 3, 3}, {0, 1, 0}, {1, 3, 3}, {1,
3, 3}, {1, 3, 3}, {1, 3, 3}}}, CompressedData["
1:eJxTTMoPSmVmYGBgBGJjIGYCYq4u+eR3VWoOxhkv5j+Qk3SA8fu/r5rKOVHM
Yd2vmNyjZ9Qcrt9QXbW9S8RBg59767IidQcPMYPGaHFhB+Nn61SfiGo4xBwp
T7o2V9Dh0Iolfg6/NBxEHv/x1Xgi4FB1XNNqkqQWnP+axUTQjFkbzn+oO2HB
j/3aDg/Xn5T6WiDoYLs3aJpiqI7DrHN+bO6tQg4zfUR7vF7pQOyfIQyRd9d1
WLL0U1kLoyjEPdm6DpoTXfQX7xBzKPjQejLkhDacL5J4+LL2Gm2HtNnSl4Vf
iELM69J2qPZM3tLnJerQX1oozZugDfHPUxGI/4W1HQ5p3TthoyDi4D7lG1v8
Mi2HgqL9zoEHhB1inOxe3BRG8MH62zXhfIbN1Z82CGhC/GMg4nCm3mN/7TYN
iHlCUPdGakDc/1kUEr46GhD/eYnD+d9iBf/kC0vC+TuCrSL+X5Vy2HGR4R5T
uAbEfxYykPBYp+HQqsCuesZAFhL+rJoQ/2rIQdxTpwkJ7yVycPfD+GDzVqLx
xbUd5HYt2JfqBdWfpA2Jj9mykPDpgYaXtaxDy7yzq86vg8qvlIHE5ylY/Eo7
XAt7o787TxfOB5ufqesQ9PbyxxkPZSDhZ6nrMAGU3u7LQtLLEx2HN2253UbX
ofZ76jis/Pay4oynAsT8QG0HKZMv/gW7FCDyTFpwPsz/MD44/Mw1HFjb1uR9
TVVwWKy880/7FHWIexrkIfLX1RzOMDZZVjHIOaDkh3vSDuj5AwCF11Vc
"]]}}, Background -> GrayLevel[0.93], Axes -> False,
AspectRatio -> 1, ImageSize ->
Dynamic[{
Automatic,
3.5 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[
Magnification])}], Frame -> True, FrameTicks -> None,
FrameStyle -> Directive[
Thickness[Tiny],
GrayLevel[0.7]]],
GridBox[{{
RowBox[{
TagBox["\"Function name: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"zinside\"", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument count: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["2", "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Argument types: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox[
PaneBox[
RowBox[{"{",
RowBox[{"Real", ",", "Real"}], "}"}],
ImageSize -> {{1, 500}, Automatic}, BaselinePosition ->
Baseline, ContentPadding -> False, FrameMargins -> 0,
StripOnInput -> True], "SummaryItem"]}]}, {
RowBox[{
TagBox["\"Return type: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox[
PaneBox[
"NumericArray", ImageSize -> {{1, 500}, Automatic},
BaselinePosition -> Baseline, ContentPadding -> False,
FrameMargins -> 0, StripOnInput -> True],
"SummaryItem"]}]}, {
RowBox[{
TagBox["\"Library: \"", "SummaryItemAnnotation"],
"\[InvisibleSpace]",
TagBox["\"libbilliard.dylib\"", "SummaryItem"]}]}},
GridBoxAlignment -> {
"Columns" -> {{Left}}, "Rows" -> {{Automatic}}}, AutoDelete ->
False, GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
GridBoxSpacings -> {"Columns" -> {{2}}, "Rows" -> {{Automatic}}},
BaseStyle -> {
ShowStringCharacters -> False, NumberMarks -> False,
PrintPrecision -> 3, ShowSyntaxStyles -> False}]}},
GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}},
AutoDelete -> False,
GridBoxItemSize -> {
"Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}},
BaselinePosition -> {1, 1}]},
Dynamic[Typeset`open$$], ImageSize -> Automatic]},
"SummaryPanel"],
DynamicModuleValues:>{}], "]"}],
LibraryFunction[
"/Users/nolanking/projects/lib_billiard/target/release/libbilliard.dylib",
"zinside", {Real, Real}, NumericArray],
Editable->False,
SelectWithContents->True,
Selectable->False]], "Output",
CellChangeTimes->{
3.9335185408571*^9, {3.933518875017688*^9, 3.933518894870737*^9},
3.9335190884358807`*^9, 3.933519162535952*^9, 3.934447870105233*^9, {
3.934448202924694*^9, 3.934448221223118*^9}, 3.934448969601499*^9,
3.934453020561111*^9, 3.9355065294174423`*^9, 3.935506628654714*^9,
3.935506882538547*^9, 3.935508089990285*^9, 3.937306108670595*^9,
3.937306160060873*^9, {3.937306330312579*^9, 3.937306344360024*^9},
3.9373064476798077`*^9, 3.937306854778968*^9, 3.937307210253695*^9,
3.937307437984601*^9, 3.937307546678658*^9, 3.937307701298157*^9,
3.9373081005596533`*^9, 3.937309122160757*^9, 3.9373805409223576`*^9,
3.937380697927469*^9, 3.937381459745623*^9, 3.937381618714484*^9,
3.9379971646866207`*^9},
CellLabel->"Out[4]=",ExpressionUUID->"ae957fc7-24dc-4c5a-ad7f-91c1e0b79a0a"]
}, Open ]],
Cell[CellGroupData[{
Cell[BoxData[{
RowBox[{
RowBox[{"si", " ", "=", " ", "0"}], ";"}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"n", " ", "=", " ", "25"}], ";"}], "\[IndentingNewLine]",
RowBox[{
RowBox[{"\[Delta]", " ", "=", " ", ".1"}], ";"}], "\[IndentingNewLine]",
RowBox[{"ParametricPlot", "[", "\[IndentingNewLine]",
RowBox[{
RowBox[{"{", "\[IndentingNewLine]",
RowBox[{
RowBox[{"Normal", "[",
RowBox[{"zin", "[",
RowBox[{"s", ",", " ", "\[Delta]"}], "]"}], "]"}], ",", " ",
"\[IndentingNewLine]",
RowBox[{"Normal", "[",
RowBox[{"zout", "[",
RowBox[{"s", ",", " ", "\[Delta]"}], "]"}], "]"}]}],
"\[IndentingNewLine]", "}"}], ",", "\[IndentingNewLine]",
RowBox[{"{",
RowBox[{"s", ",", " ", "0", ",",
RowBox[{"2", "Pi"}]}], "}"}], " ", ",", "\[IndentingNewLine]",
RowBox[{"Epilog", "->", "\[IndentingNewLine]",
RowBox[{"{",
RowBox[{"Red", ",",
RowBox[{"Line", "[", "\[IndentingNewLine]",
RowBox[{"Join", "[", " ", "\[IndentingNewLine]",
RowBox[{
RowBox[{"Normal", "[",
RowBox[{"zout", "[",
RowBox[{"si", ",", "\[Delta]"}], "]"}], "]"}], ",",
"\[IndentingNewLine]",
RowBox[{"Normal", "[",
RowBox[{"billmin", "[",
RowBox[{"si", ",",
RowBox[{"Pi", "/", "2"}], ",", " ", "n", ",", " ", "\[Delta]"}],
"]"}], "]"}], ",", "\[IndentingNewLine]", " ",
RowBox[{"If", "[", " ",
RowBox[{
RowBox[{"OddQ", "[", "n", "]"}], ",",
RowBox[{"Normal", "[",
RowBox[{"zout", "[",
RowBox[{
RowBox[{"Pi", "/", "2"}], ",", " ", "\[Delta]"}], "]"}], "]"}],
",", " ",
RowBox[{"Normal", "[",
RowBox[{"zin", "[",
RowBox[{
RowBox[{"Pi", "/", "2"}], ",", " ", "\[Delta]"}], "]"}],
"]"}]}], "]"}]}], "\[IndentingNewLine]", "]"}],
"\[IndentingNewLine]", "]"}]}], "\[IndentingNewLine]", "}"}]}], ",",
"\[IndentingNewLine]",
RowBox[{"PlotStyle", "->", "Black"}], ",", "\[IndentingNewLine]",
RowBox[{"AxesStyle", "->", "Thick"}], ",", "\[IndentingNewLine]",
RowBox[{"TicksStyle", "->",
RowBox[{"Directive", "[", "16", "]"}]}], ",", "\[IndentingNewLine]",
RowBox[{"Axes", "->", "False"}], ",", "\[IndentingNewLine]",
RowBox[{"Ticks", "->", "False"}]}], "\[IndentingNewLine]", "]"}]}], "Input",\
CellChangeTimes->{{3.932596359016816*^9, 3.932596377590974*^9}, {
3.932596503760215*^9, 3.932596504863089*^9}, {3.9325965546725817`*^9,
3.932596576959281*^9}, {3.932640505966833*^9, 3.932640678236699*^9}, {
3.932640732045158*^9, 3.9326407663636*^9}, {3.932640827119998*^9,
3.932640877387299*^9}, {3.93264094866782*^9, 3.932641089780843*^9}, {
3.932641124246308*^9, 3.932641127693131*^9}, {3.932641160063299*^9,
3.93264129294904*^9}, {3.93264132646504*^9, 3.932641335469754*^9}, {
3.932641702058263*^9, 3.932641702334632*^9}, {3.932641767054126*^9,
3.9326417703219233`*^9}, {3.93264184219387*^9, 3.932641935528514*^9}, {
3.9331832325783*^9, 3.933183287866279*^9}, {3.933518448477365*^9,
3.933518463518289*^9}, {3.933518579702071*^9, 3.933518606913768*^9}, {
3.933518906010977*^9, 3.933519048167588*^9}, {3.933519116808058*^9,
3.933519134826226*^9}, {3.934447930999256*^9, 3.934447964105173*^9}, {
3.934448120990776*^9, 3.9344481246934824`*^9}, {3.934448389291599*^9,
3.934448413034206*^9}, {3.934448982351907*^9, 3.934449027447526*^9}, {
3.934449068358534*^9, 3.934449068692881*^9}, {3.934449107240181*^9,
3.9344491333677*^9}, {3.934452808096413*^9, 3.934452818837183*^9}, {
3.934452875575605*^9, 3.934452998188591*^9}, 3.934453373956764*^9,
3.937306138091243*^9, 3.937307398184548*^9, 3.937307453723188*^9, {
3.937308153536832*^9, 3.937308167007376*^9}, {3.937308218061309*^9,
3.937308263193693*^9}, {3.937308310915481*^9, 3.937308327768289*^9}, {
3.937308418994301*^9, 3.937308434329216*^9}, 3.937308468153235*^9, {
3.937308649641635*^9, 3.937308684238465*^9}, {3.9373087142851067`*^9,
3.9373087398073683`*^9}, {3.9373088315567513`*^9,
3.9373088439295683`*^9}, {3.937308877427844*^9, 3.937308887724118*^9}, {
3.93730891915093*^9, 3.937308937380707*^9}, {3.93730907402635*^9,
3.9373090747885838`*^9}, {3.937309277514932*^9, 3.937309278410163*^9}, {
3.937380582561604*^9, 3.937380618049096*^9}, {3.937380777422401*^9,
3.937380817214583*^9}, {3.93738095580454*^9, 3.93738097049937*^9}, {
3.937381002537551*^9, 3.937381002625949*^9}, {3.937381475714304*^9,
3.937381477233316*^9}, {3.937381642339957*^9, 3.937381644985113*^9}},
CellLabel->"In[5]:=",ExpressionUUID->"39196ef7-6b0e-4615-93ae-6f450b007477"],
Cell[BoxData[
GraphicsBox[
InterpretationBox[{
TagBox[{{{}, {},
TagBox[
{GrayLevel[0], AbsoluteThickness[2], Opacity[1.], FaceForm[Opacity[
0.3]], LineBox[CompressedData["
1:eJw123k8VP/3OPBbSkWhQiGi0qJUtFDedSYpIYmEEFKSJaGUhIpIZAllichS
lH3Nekb2fc/OLFHZQnaD7/08Hr/f/OPxNHPv4/U695zzOvPHiBnf0zBZSRDE
AzaC+N/f2pr/vQgK8f9eEqsTVCpJr5JNUT5prg9+qU4VhaQv+O9OGzezhL2V
PWcTSfvcj/cRVLOD30v1hYGk5T3VnOvvOMLJW3jSjvT2C0TpHPU5JA045Vwi
fVH1xDUpVTcQiT97Soz0gJimL6vdA8JlkyqGqwmK5/XsN0q3XkNPOBqkkv6j
axzL/tcXwlV6Vt4j/e5zJf+b/DcwM1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