April 18, 2017 --- Class 27 --- Non-linear Data Fitting, Introduction
to Parallel Computing
Activities:
Non-linear Data Fitting
-----------------------
When the model function depends non-linearly on the parameters, we have
to use an iterative method to minimize chi-squared. This problem is
discussed in Numerical Recipies. The present case differs from the
general minimization problem because we can calculate the first and
second derivatives of chi-squared because we know the form of the model
function. Numerical Recipies has the Levenberg-Marquardt method and
the user needs to supply the model function and its first derivatives
with respect to its parameters. I have my own fitting routines that
can be found in either ~sg/fitting or ~sg/src/misc.
The user needs to also supply second derivatives for my fitter.
For my routines, you need to supply the model function. Examples are
finitesize.c and powerlaw.c. You can find additional examples in
~sg/src/misc. Consult the makefile. Look for targets that are
compiled with fit.o or cofit.o. Cofit deals with correlated data.
Fitnotes contains information about the input for my fitting routines.
Gnu Scientific Library also has data fitting routines that implement
Levenberg-Marquardt.
As an example of a non-linear fit model, we looked at const_exp.c
which approproiate for the coffee cooling problem. I fit the file
~sg/coffee_black.dat.err
Don't forget that after the fit is done, there is an axis file
fit_graph.ax that shows the data and the fit.
Introduction to Parallel Computing
----------------------------------
Some notes related to our discussion can be found in
~sg/parallel_computing.2017. We got as far as the table on
clock speed of various processors. We will complete discussion of
material in that file in our next class and then go on to
CUDA programming.
The following material goes beyond the discussion in class and
was not discussed in class except for the graph in
Page24_cpu_frequency.pdf.
If you want to learn more about computer architecture there are a
number of good books. Patterson and Hennessy have written two books:
Computer Organization and Design, Fifth Edition and
Computer Architecture, Fifth Edition: A Quantitative Approach.
As both are in their fifth edition, you see that they are popular.
The newer editions emphasize parallel computing. Check out iucat.
You should be able to access the electronic edition of at least the
second book.
There are other references for you on the cluster in ~sg/parallel
You might be interested in the report from the National Academy
FutureOfComputingPerformance.pdf which explains why learning about
parallel programming is so important.
Page24_cpu_frequency.pdf is from a report on future computer
performance/ The full report is ExaScale Computing Study:
Technology Challenges in Achieving Exascale Systems. Peter Kogge
is the editor and study lead. You should be able to find this on
the internet.
The cuda subdirectory contains three files:
01-intro_to_cuda_c.pdf 02-cuda-overview.pdf cuda_links
The first file has some very important material about CUDA C that was
not in our introduction.
02-cuda-overview.pdf is a very good brief overview that has some
overlap with what was presented in class.
cuda_links isn't really appropriately named since it list books as
well and is not restricted to cuda. Here is the contents of that file.
GPU Accelerated Computing with C and C++
https://developer.nvidia.com/how-to-cuda-c-cpp
If you want to buy the CUDA programming book by Kirk and Hwu, I can give you a
discount code.
High Performance Computing: Programming and Applications (Chapman & Hall/CRC Computational Science)Dec 14, 2010
by John Levesque and Gene Wagenbreth
High Performance Parallelism Pearls Volume Two: Multicore and Many-core Programming ApproachesJul 23, 2015
by Jim Jeffers and James Reinders
High Performance Parallelism Pearls Volume One: Multicore and Many-core Programming ApproachesNov 3, 2014
by James Reinders and James Jeffers
High Performance Computer Architecture (3rd Edition) (Addison-Wesley Series in Electrical & Computer Engineering)Dec 31, 1993 | Facsimile
by Harold S. Stone
Introduction to High Performance Computing for Scientists and Engineers (Chapman & Hall/CRC Computational Science)Jul 2, 2010
by Georg Hager and Gerhard Wellein