Julia Programming Language for Scientific Computing University of Konstanz, SS 2015 EXERCISE SHEET 2 Review the video Getting Started with Julia by Leah Hanson (part 2 of 4) http://blog.l eahhanson.us/pages/speaking.html https://www.youtube.com/watch?v=pHQdSmySQ_w&spfreload=10 Read the Julia Language Documentation, Sections 1.5 to 1.6: Mathematical functions, Complex arithmetic Solve the following exercises by filling in the details (JULIA code and answers). Submit by email to dietmar.saupe@uni-konstanz.de by Thursday, April 23, 12 noon. 1. Make an array immutable (read-only) (Is this possible in Julia?) 2. Consider a random 10x2 matrix representing Cartesian coordinates, convert them to polar coordinates 3. Create random vector of size 100 and replace the maximum value by 0 4. Create a structured array with x and y coordinates covering the [0,1]x[0,1] area. 5. Print the minimum and maximum representable value for each Julia scalar type 6. Create a structured array representing a position (x,y) and a color (r,g,b) (Does julia support structured arrays?) 7. Consider a random vector with shape (100,2) representing coordinates, find point by point distances 8. Generate a generic 2D Gaussian-like array 9. Consider the vector [1, 2, 3, 4, 5]. How to build a new vector with 3 consecutive zeros interleaved between each value? 10. Find the nearest value from a given value in an array 11. Compute the Mandelbrot Set using complex arithmetic (next week after Monday's session)