(* Content-type: application/mathematica *) (*** Wolfram Notebook File ***) (* http://www.wolfram.com/nb *) (* CreatedBy='Mathematica 7.0' *) (*CacheID: 234*) (* Internal cache information: NotebookFileLineBreakTest NotebookFileLineBreakTest NotebookDataPosition[ 145, 7] NotebookDataLength[ 14302, 393] NotebookOptionsPosition[ 13524, 364] NotebookOutlinePosition[ 13885, 380] CellTagsIndexPosition[ 13842, 377] WindowFrame->Normal*) (* Beginning of Notebook Content *) Notebook[{ Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"L2Norm", "[", "f_", "]"}], " ", ":=", SqrtBox[ RowBox[{" ", RowBox[{ SubsuperscriptBox["\[Integral]", "0", "\[Pi]"], RowBox[{ SuperscriptBox[ RowBox[{"Abs", "[", "f", "]"}], "2"], RowBox[{"\[DifferentialD]", "x"}]}]}]}]]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"L2IP", "[", RowBox[{"f_", ",", " ", "g_"}], "]"}], " ", ":=", " ", RowBox[{ SubsuperscriptBox["\[Integral]", "0", "\[Pi]"], RowBox[{"f", " ", RowBox[{"Conjugate", "[", "g", "]"}], RowBox[{"\[DifferentialD]", "x"}]}]}]}], ";"}]}], "Input", CellChangeTimes->{{3.4596865062044563`*^9, 3.459686664120265*^9}, { 3.4596906854989*^9, 3.459690691303339*^9}, 3.459691313898197*^9, { 3.459694182516881*^9, 3.459694187027012*^9}}, FontSize->14], Cell[CellGroupData[{ Cell[BoxData[{ RowBox[{ RowBox[{"v", " ", "=", " ", "x"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"m", "=", "10"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"H", " ", "=", " ", RowBox[{"ConstantArray", "[", RowBox[{"0", ",", RowBox[{"{", RowBox[{ RowBox[{"m", "+", "1"}], ",", "m"}], "}"}]}], "]"}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"V", " ", "=", " ", RowBox[{"{", RowBox[{"v", "/", RowBox[{"L2Norm", "[", "v", "]"}]}], "}"}]}], ";"}], "\[IndentingNewLine]", RowBox[{"For", "[", RowBox[{ RowBox[{"k", "=", "1"}], ",", RowBox[{"k", "\[LessEqual]", " ", "m"}], ",", RowBox[{"k", "++"}], ",", RowBox[{ RowBox[{"w", " ", "=", " ", RowBox[{ RowBox[{"Integrate", "[", RowBox[{ RowBox[{"\[Xi]", " ", RowBox[{"(", RowBox[{ FractionBox["x", "\[Pi]"], "-", "1"}], ")"}], RowBox[{"(", RowBox[{ RowBox[{"V", "[", RowBox[{"[", RowBox[{"-", "1"}], "]"}], "]"}], "/.", RowBox[{"x", " ", "\[Rule]", " ", "\[Xi]"}]}], ")"}]}], ",", RowBox[{"{", RowBox[{"\[Xi]", ",", "0", ",", "x"}], "}"}]}], "]"}], "+", RowBox[{"Integrate", "[", RowBox[{ RowBox[{"x", " ", RowBox[{"(", RowBox[{ FractionBox["\[Xi]", "\[Pi]"], "-", "1"}], ")"}], RowBox[{"(", RowBox[{ RowBox[{"V", "[", RowBox[{"[", RowBox[{"-", "1"}], "]"}], "]"}], "/.", RowBox[{"x", " ", "\[Rule]", " ", "\[Xi]"}]}], ")"}]}], ",", RowBox[{"{", RowBox[{"\[Xi]", ",", "x", ",", "\[Pi]"}], "}"}]}], "]"}]}]}], " ", ";", "\[IndentingNewLine]", RowBox[{"For", "[", RowBox[{ RowBox[{"j", "=", "1"}], ",", RowBox[{"j", "\[LessEqual]", " ", "k"}], ",", " ", RowBox[{"j", "++"}], ",", " ", RowBox[{ RowBox[{ RowBox[{"H", "\[LeftDoubleBracket]", RowBox[{"j", ",", "k"}], "\[RightDoubleBracket]"}], "=", RowBox[{"L2IP", "[", RowBox[{"w", ",", RowBox[{ "V", "\[LeftDoubleBracket]", "j", "\[RightDoubleBracket]"}]}], "]"}]}], ";", " ", RowBox[{"w", "=", RowBox[{"w", "-", " ", RowBox[{ RowBox[{"H", "\[LeftDoubleBracket]", RowBox[{"j", ",", "k"}], "\[RightDoubleBracket]"}], " ", RowBox[{ "V", "\[LeftDoubleBracket]", "j", "\[RightDoubleBracket]"}]}]}]}]}]}], "]"}], ";", "\[IndentingNewLine]", RowBox[{ RowBox[{"H", "\[LeftDoubleBracket]", RowBox[{ RowBox[{"k", "+", "1"}], ",", "k"}], "\[RightDoubleBracket]"}], " ", "=", " ", RowBox[{"L2Norm", "[", RowBox[{"Simplify", "[", "w", "]"}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"w", " ", "=", " ", RowBox[{ RowBox[{"Simplify", "[", "w", "]"}], "/", RowBox[{"H", "\[LeftDoubleBracket]", RowBox[{ RowBox[{"k", "+", "1"}], ",", "k"}], "\[RightDoubleBracket]"}]}]}], ";", "\[IndentingNewLine]", RowBox[{"V", " ", "=", " ", RowBox[{"Join", "[", RowBox[{"V", ",", RowBox[{"{", "w", "}"}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"ew", " ", "=", " ", RowBox[{ RowBox[{"-", "1"}], "/", RowBox[{"Eigenvalues", "[", RowBox[{"N", "[", RowBox[{ RowBox[{"H", "\[LeftDoubleBracket]", RowBox[{ RowBox[{"1", ";;", "k"}], ",", RowBox[{"1", ";;", "k"}]}], "\[RightDoubleBracket]"}], ",", "50"}], "]"}], "]"}]}]}], ";", "\[IndentingNewLine]", RowBox[{"Print", "[", "ew", "]"}], ";"}]}], "]"}], "\[IndentingNewLine]"}], "Input", CellChangeTimes->CompressedData[" 1:eJxTTMoPSmViYGAQA2IQ/en2PcUrx146tvRcUgLRtw+WGIDoLWFWRiD6k6Ti 66tAuu4Z21sQvbL87V8QnXSqg+cakPbdkyQIohfxbBAF0YcbuyVB9Lu6akUQ HXaCVQ1Ei88t0wOr4zvtBKLXFb2JAtF8V2viQbRR0ZwEEJ1W8TMTRHMJv6oE 0ZsE+VeDxZfeWwuieRbobgLRHkpmYPrMiVtnrwNptav6F0D0gs3f34Hoc+1T mW8A6T1P/bhA9JO+bjAt9ziLD0RzfdEWBNE/9bjFQHTXza0qILpzy3ptEG0V lacDopl2vN3cefylY0ci62EQ/eqn4QkQbVLqAKZv57apdQFpzhlXdEH0PgWH FsYTwHBbUNgGogHHqc4I "], FontSize->14], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"{", "1.5198177546350665716581919481459145835653816200836982326841354784125968144\ 3356`50.", "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303924017249*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0072558857140631273505843722216537463035203133497519155782817010316758341\ 9135`50.", ",", "9.631468396731402874256759264799748338654151027236135713210666647856501866\ 84039`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303924167313*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000334319025676918377586646556494855476695440460098712649349066324494567\ 7339`50.", ",", "4.253392214699186344921462681702095015398017416876646861736519676611114321\ 23303`50.", ",", "33.04598177020192356902721574691930300490192986518653873063875947275387574\ 156041`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303924376745*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000461917061544609855180000623962676550449732720017593909433140122749\ 9862`50.", ",", "4.008649821230364273385155261987074632209409661653325015130165157802367005\ 93685`50.", ",", "10.71016632332046859550140675658245352104992773442640346834661542523753348\ 821447`50.", ",", "84.58915561517185470609312104106077196578819448447108287191677004887747633\ 67803`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303924619141*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000000257220796830567665368704027668986973584230503811743131391044885\ 0106`50.", ",", "4.000109316441949620182156462114348166750190639621278609918281863150728423\ 90662`50.", ",", "9.148751325016062512916911073359185130710601909038305528428592598335563164\ 4715`50.", ",", "22.16232655229952207468877051868193797040308160230268605589372032806532119\ 543499`50.", ",", "181.0227517190312634596505537641734437792187988236481540292096043103106272\ 9767314`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303925076208*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000000000069003458379676782028502828987711267825749043447092367653488\ 922`50.", ",", "4.000000588755939641662149026839077467628566165572757662541600642528637858\ 46731`50.", ",", "9.006383982038691297798702628692478927622292026900345491222383536565880409\ 09084`50.", ",", "16.89725585071831673639599088759832215869520365579606159391243503611595176\ 000529`50.", ",", "40.96112722733603584267852813512689766767958359445144090260712661393685816\ 877302`50.", ",", "343.0454793665241836438051931978997022414406380690022292975810950682548376\ 3672647`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.4603039256919928`*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000000000000010026337429288691059134121111637183898614886106323120811\ 0837`50.", ",", "4.000000001605511268852548481980560213617598479196161616540844533166112227\ 2715`50.", ",", "9.000122421471944053233432700837147338257577328692835093121973418018819211\ 64781`50.", ",", "16.08448124543698800875937225268585062374353703162871793722549685927418428\ 404791`50.", ",", "28.17121363307873770747785003480536783563574483587268542312999245933314614\ 594766`50.", ",", "69.88079855024792622024355886237553567822542392911599517517556763954860219\ 423876`50.", ",", "595.2966353544505808497299712418420109817283574441702451225931242044229116\ 2566038`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303926487615*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000000000000000000858026019256540903221432598720149608837021109108355\ 3011`50.", ",", "4.000000000002476837331555982464067720463242488610786228844934328983911116\ 32532`50.", ",", "9.000001204230210346253364665978484522079118937435775036938725850936595220\ 46173`50.", ",", "16.00396265753825591333082533202919877077101996107064525998378363678591141\ 149876`50.", ",", "25.50068330155367763866838438894986330673614926182455189294168050272977627\ 232274`50.", ",", "44.18943131055583284514912837672523601101038371872274253731971944086500531\ 390235`50.", ",", "112.1115162702877884723639516862381539900650178291458707643427768935123804\ 1825934`50.", ",", "966.3571286489353642963331019677260552046685775488126262414093185095205681\ 895989`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303928265122*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000000000000000000000046066251548167185635573359618892678570832670227\ 3421`50.", ",", "4.000000000000002334868046355778674269812018034344093752027055464992023263\ 40763`50.", ",", "9.000000006830236266874853379418543509390102630205443222495980994138704541\ 9912`50.", ",", "16.00009563693741973719972884326955778452474865627537190520572915322288311\ 663344`50.", ",", "25.04603140811324393866737472089904438598427562568739682804815184305592408\ 593185`50.", ",", "37.82617433870810828865465793952905102602320191921965855278584813067366133\ 082991`50.", ",", "66.32736169225101630308058052676080340803651789972227002337588493836058043\ 867388`50.", ",", "171.2723924143370135217078256593935872451274474092712214681196430627517279\ 5284885`50.", ",", "1488.749796800997645883802694501003869744046768501903992808962606215599617\ 68321956`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.460303930588732*^9}}, FontSize->14], Cell[BoxData[ RowBox[{"{", RowBox[{ "1.0000000000000000000000000000001630328137834800608631332660978145183170860\ 2804`50.", ",", "4.000000000000000001424552272914470993337442455832060127291079354381175748\ 3914`50.", ",", "9.000000000024152066014676593879819205555558960131602220128862516380053891\ 77468`50.", ",", "16.00000133200433537399538947268842709260883713644674491485707076044894515\ 222316`50.", ",", "25.00224972038466802881090100789173155048077521275557840433022148608151111\ 218893`50.", ",", "36.27706301346338131919635776684034123475761361823112244831272066156096969\ 913545`50.", ",", "53.87979034544693379092308687554894092682118116826986870071791450739647344\ 227674`50.", ",", "96.08128952523807428112185928539512422540815146006142179917039233035019589\ 299406`50.", ",", "251.4173290188406175893420775913122806428107645100750923834220212588132950\ 775331`50.", ",", "2198.939520503300735955829039299943428589696741166365215952107551578778022\ 89079825`50."}], "}"}]], "Print", CellChangeTimes->{{3.460058675561501*^9, 3.460058691133402*^9}, { 3.460059485110405*^9, 3.4600595032002983`*^9}, {3.460303908494569*^9, 3.4603039328109617`*^9}}, FontSize->14] }, Open ]] }, Open ]] }, WindowSize->{821, 738}, WindowMargins->{{149, Automatic}, {Automatic, 0}}, ShowSelection->True, FrontEndVersion->"7.0 for Mac OS X x86 (32-bit) (February 18, 2009)", StyleDefinitions->"Default.nb" ] (* End of Notebook Content *) (* Internal cache information *) (*CellTagsOutline CellTagsIndex->{} *) (*CellTagsIndex CellTagsIndex->{} *) (*NotebookFileOutline Notebook[{ Cell[545, 20, 860, 25, 102, "Input"], Cell[CellGroupData[{ Cell[1430, 49, 4280, 120, 332, "Input"], Cell[CellGroupData[{ Cell[5735, 173, 317, 7, 22, "Print"], Cell[6055, 182, 428, 10, 41, "Print"], Cell[6486, 194, 527, 12, 59, "Print"], Cell[7016, 208, 625, 14, 77, "Print"], Cell[7644, 224, 724, 16, 95, "Print"], Cell[8371, 242, 825, 18, 113, "Print"], Cell[9199, 262, 922, 20, 131, "Print"], Cell[10124, 284, 1022, 22, 149, "Print"], Cell[11149, 308, 1122, 24, 167, "Print"], Cell[12274, 334, 1222, 26, 185, "Print"] }, Open ]] }, Open ]] } ] *) (* End of internal cache information *)