Using scripts

In Julia and Juliabox, you can use scripts! These can be handy, but I don't find them quite as useful with Juliabox as I do when I'm working at the command line.

In [3]:
include("Lecture-4-in-class-example-script.jl")
Out[3]:
([1.1102230246251565e-15,1.0,2.0],
3x3 Array{Float64,2}:
 -0.707107   0.0  0.707107
  0.0       -1.0  0.0     
  0.707107   0.0  0.707107)
In [4]:
@show A
A = [1 0 1
 0 1 0
 1 0 1]
Out[4]:
3x3 Array{Int64,2}:
 1  0  1
 0  1  0
 1  0  1
In [7]:
eigvals(A)
eigvecs(A)
Out[7]:
3x3 Array{Float64,2}:
 -0.707107   0.0  0.707107
  0.0       -1.0  0.0     
  0.707107   0.0  0.707107