$Author: leiser $
$Id: FolgenPlotterStandard.nb 1638 2009-09-18 10:48:51Z leiser $
$LastChangedDate: 2009-09-18 12:48:51 +0200 (Fri, 18 Sep 2009) $

(* CELL WITH TABS AND MANIPULATE(S) *)

TabView[{

(* First Tab *)
Style["Folgen-Plotter",titleStyle]->
Column[{
(* First Row (Header and Explanation Button *)
Row[{
" "
(*  no hints for such a simple notebook...
Button[Style["Hinweise",9],
CreateDocument[
TextCell[Pane[Column[{
(* Explanation Texts *)
TextCell["\nHinweise\n",{explanationHeaderStyle}],
TextCell[Row[
{"texttext ",Style["italic text",Italic]," texttext"
}
],explanationStyle],
TextCell[Row[{"\nZ.B. Hintergrund Erklaerung\n"}],{explanationHeaderStyle}],
TextCell[Row[
{"texttext"
}
],explanationStyle]
(* more, if necessary ... *)
(* End Explanation Texts *)
}]]],(* End TextCell *)
WindowFrame->"Normal",WindowSize->{650,500},WindowTitle->"Hinweise"
],(* End CreateDocument *)
ImageSize->{80,20}] (* End Button *) *)
},
ImageSize->{860,25},Background->RGBColor[0.9,0.9,0.9],Alignment->{Right,Top}
],(* End Row *)

(* Second Row: Manipulate element *)


Manipulate[
(*seq = Dynamic[seqlist[[seqindex]]];*)
isConv = NumberQ[seqlimits[[seqindex]]];


If[isConv,

Show[{


ListPlot[seqlist[[seqindex]][[1;;maxPointsDisplayed]],AxesOrigin->{0,0},
Joined->joinPoints,
PlotStyle->{PointSize[Small],RGBColor[0.2,0.2,0.8]},PlotMarkers->"●",PlotRange->All,AxesLabel->{Style["n",Italic],"\!\(\*SubscriptBox[\"a\", \"n\"]\)"}
],

Graphics[{Thick,RGBColor[0.8,0.2,0.2],limitLine =Line[{
{0,seqlimits[[seqindex]]},
{maxPointsDisplayed,seqlimits[[seqindex]]}
}]
}]

},
PlotLabel->("\n Grenzwert = "<>ToString[TraditionalForm[seqlimits[[seqindex]]]]<>"\n"),
ImageSize->{550,400},Background->RGBColor[1,1,1],ImagePadding->20
], (* end Show *)

(* else, not convergent *)
Show[{


ListPlot[seqlist[[seqindex]][[1;;maxPointsDisplayed]],AxesOrigin->{0,0},
Joined->joinPoints,
PlotStyle->{PointSize[Small],RGBColor[0.2,0.2,0.8]},PlotMarkers->"●",PlotRange->All,AxesLabel->{Style["n",Italic],"\!\(\*SubscriptBox[\"a\", \"n\"]\)"}
]
},
PlotLabel->("\n nicht konvergent "<>"("<>ToString[seqlimits[[seqindex]]]<>")\n"),
ImageSize->{550,400},Background->RGBColor[1,1,1],ImagePadding->20
]

],  (* end If *)

{{seqindex,2,Style["Folge \!\(\*SubscriptBox[\"a\", \"n\"]\) =",textStyle]},
{1->ToString[Style[TraditionalForm[seqdef[[1]]],textStyle]],
2->ToString[Style[TraditionalForm[seqdef[[2]]],textStyle]],
3->ToString[Style[TraditionalForm[seqdef[[3]]],textStyle]],
4->ToString[Style[TraditionalForm[seqdef[[4]]],textStyle]],
5->ToString[Style[TraditionalForm[seqdef[[5]]],textStyle]],
6->ToString[Style[TraditionalForm[seqdef[[6]]],textStyle]],
7->ToString[Style[TraditionalForm[seqdef[[7]]],textStyle]],
8->ToString[Style[TraditionalForm[seqdef[[8]]],textStyle]]},
ControlType->PopupMenu
},
{{joinPoints,False,Style["Punkte verbinden ",textStyle]},{True,False}},

{{maxPointsDisplayed,20,Style["Anz.angezeigte Punkte ",textStyle]},4,maxPoints,1},
Delimiter,


TrackedSymbols->Manipulate,
SaveDefinitions->True,
AppearanceElements->None,
Paneled->False,
ControlPlacement->Left ,

Initialization :>
(

(* Styles *)
titleStyle := {FontFamily ->"Verdana",14,Bold, RGBColor[0.35,0.35,0.35],Background->RGBColor[1,1,1,0]};
tagAtRight := {FontFamily ->"Verdana",12,Bold, RGBColor[0,33/255,66/255],Background->RGBColor[1,1,1,0],TextAlignment->{Right,Top}};
textStyle := {FontFamily ->"Verdana",10,Bold, RGBColor[0.35,0.35,0.35],Background->RGBColor[1,1,1,0],AutoIndent->False,ParagraphIndent->0,TextJustification->1};
explanationStyle := {FontFamily ->"Times",14,Plain, RGBColor[0.35,0.35,0.35],Background->RGBColor[1,1,1,0],AutoIndent->False,ParagraphIndent->0,TextJustification->1};
explanationHeaderStyle := {FontFamily ->"Times",16,Bold, RGBColor[0.35,0.35,0.35],Background->RGBColor[1,1,1,0],AutoIndent->False,ParagraphIndent->0,TextJustification->1};
mathStyle := {FontFamily ->"Times",14,Bold, RGBColor[0.35,0.35,0.35],Background->RGBColor[1,1,1,0],AutoIndent->False,ParagraphIndent->0,TextJustification->1};
plotLabelStyle := {FontFamily ->"Times",14,Plain, RGBColor[0.35,0.35,0.35],Background->RGBColor[1,1,1,0]};

maxPoints=200;
pointSize=1;

(* List of the defined sequences: *)
seqdef={n, 1/n,Sin[n],3+1/n,(1/2)+(-1)^n*(1/n^2),(n+3)/(2n+5),(1/3)^n,(3/2)^n};
(* List of the limits *)
seqlimits = Limit[seqdef,n->Infinity];
(* List of the data points of the defined sequences: *)
seqlist={
Table[{n,seqdef[[1]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[2]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[3]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[4]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[5]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[6]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[7]]},{n,1,maxPoints+1,1}],
Table[{n,seqdef[[8]]},{n,1,maxPoints+1,1}]
};

)

] (* End Manipulate *)
(* End Second Row *)
}(*,Alignment->{Left,Top}*)] (* End Column *)
(* End First Tab *)


},Background->RGBColor[0.95,0.95,0.95 ](* TabView Background *)
] (* End TabView *)

(* END OF CELL WITH TAB AND MANIPULATE(S) *)

2009, Projekt LEMUREN, Lernen Multimedial, Departement Mathematik, ETH Zürich | Licence: CC-BY-SA

$LastChangedDate: 2009-09-18 12:48:51 +0200 (Fri, 18 Sep 2009) $