Working with Notebooks

Section 2

Craig Bauling    craigb@wolfram.com

Goals

Understand how to create and work with Text within a Notebook

Creating Slide Shows - From Scratch and from Existing Notebooks

Understanding the basics for creating Quizzes and Tests

Basics of Notebooks

The look and feel of the notebook is found in StyleSheet.  Explore Stylesheets.
End with the "Format"  "StyleSheet" "Creative" "Natural Colors"

Notebooks have Stylesheets   "Format"  "StyleSheet"
Cells have cell styles

This is plain text.

This is a sub-item

This is a sub-item paragraph

FV = PV (((1 + i))^n)   This is an Displayformula

This is progam style

Text Formatting with Classroom Assistant

Changing Font Styles

This plain text.    This is a modified Plain text.          "Format", "Font"

This is the result of using Writing and Formatting

The Derivative?     Show Copy and Paste

Answer

The Derivative?     Show Copy and Paste

Answer

The Derivative?     Show Copy and Paste

Answer

Create your own cell style:  
"Format" "Edit Stylesheet"

This is the result

answer 2

Answer 3

Entering Greek Letters

Δ    μ    ρ     Use the Classroom Assistant - Typesetting ∞β

Δ   μ   ρ   Use the "ESC" key before and after first letter

Δ   μ   ρ    Use \[   ]  and the name of symbol

Remember to Spell Check!

menu     "Edit"    "Check Spelling"
Skip - don't worry about it
Replace - Change my word with the Replace With word
Add Word - Stores the word in the dictionary  (* either permanently or for this notebook or for this cell *)

Using Hyperlinks

Insert a hyperlink 
hyperlink
 for "Insert"  "Hyperlink"

More Notebook Tricks in the Documentation Center      		              guide/NotebooksAndDocumentsHowToTopics

Creating Quizzes

Easy Quiz

1. How much wood could a wood chuck chuck if a wood chuck could chuck wood?

Answer:

2. What is the Capital of Paris?

A bit more difficult

1.  What is the sum of 1 and 3?

Text[Grid[{{"A.   two ", "B.    five"},{"C.   three ","D.   seven"}}]]

Answer: A

Algebra (expanding polynomials)

PrintList[list_]:=
TraditionalForm[Grid[Table[{ToString[i]<>".",list[[i]]},{i,Range[Length[list]]}],Alignment->Left]]
Manipulate[
Pane[
Column[{
Style["Expanding Polynomials",FontFamily->"Arial",14,Bold],
Button["Generate random exercises",
{
problems=
Flatten[
Table[
{
SeedRandom[];
leadexponent=RandomInteger[{1,maxExponent}];
coefficients=RandomInteger[{-10,10},leadexponent];
outsideexponent=RandomInteger[{2,maxOutsideExponent}];
(Total[RandomInteger[{-10,10}]+(coefficients[[#]]*(x^(#)))&/@Range[leadexponent]])^outsideexponent
},
{10}
]
];
},Method->"Queued"],
TabView[{"Quiz"->Dynamic[PrintList[problems]],"Answer Key"->Dynamic[PrintList[(Expand[#]&/@problems)]]}]
}]
],
{{maxExponent,3,"Set maximum exponent (inside parentheses)"},1,3,1,ControlType->SetterBar},
{{maxOutsideExponent,3,"Set maximum exponent (outside parentheses)"},2,5,1,ControlType->SetterBar},
SaveDefinitions->True]

Finance - Calculating Future Values Quiz

PrintList[list_]:=
TraditionalForm[Grid[Table[{ToString[i]<>".",NumberForm[list[[i]],{10,2}]},{i,Range[Length[list]]}],Alignment->Left]]
Manipulate[
Pane[
Column[{
Style["Calculate Future Values Given The Following Data",FontFamily->"Arial",14,Bold],
Button["Generate Random Exercises",
{
SeedRandom[];
presentvalue=RandomInteger[{200,1000},{ques}];
(* futurevalue=RandomInteger[{2000,10000},{ques}]; *)
interestrate= RandomReal[{1,12},{ques},WorkingPrecision->10];
periods=RandomInteger[{4,36},{ques}];
(* futureratio=futurevalue/presentvalue;*)
problems1=Transpose[{presentvalue,interestrate,periods}];
answers1=(presentvalue[[#]]*(((1+((interestrate[[#]])/100)))^(periods[[#]])))&/@Range[ques];
}
,Method->"Queued"],
Style["Data Format={PV, Interest, Periods}",FontFamily->"Arial",12,Italic],
TabView[{
"Quiz"->Dynamic[PrintList[problems1]],"Answer Key"->Dynamic[PrintList[answers1]]
}]  }
,{300}]]
,
{{ques,15,"Number of Questions"},5,25,5,ControlType->SetterBar}, SaveDefinitions->True]

Generating a Slide Show

New Slide Show

Creating a Slide Show from your existing Notebook

Open "Palettes"  "Slide Show"  
"Convert Notebook"