Most problem solving in science and engineering uses scientific computing. A scientist might devise a system of differential equations to model a physical system, then use a computer to calculate their solutions. An engineer might develop a formula to predict cost as a function of several variables, then use a computer to find the combination of variables that minimizes that cost. A scientist or engineer needs to know science or engineering to make the models. He or she needs the principles of scientific computing to find out what the models predict.
Scientific computing is challenging partly because it draws on many parts of mathematics and computer science. Beyond this knowledge, it also takes discipline and practice. A problem-solving code is built and tested procedure by procedure. Algorithms and program design are chosen based on onsiderations of accuracy, stability, robustness, and performance. Modern software development tools include programming environments and debuggers, visualization, profiling, and performance tools, and high-quality libraries. The training, as opposed to just teaching, is in integrating all the knowledge and the tools and the habits to create high quality computing software “solutions.”
Principles of Scientific Computing, by David Bindel and Jonathan Goodman
R.Stallman | L.Torvalds |
Linux has a hierarchical architecture
Linux is a "collection of small programs that do one thing well"
|, >, >>, <, &, >&, 2>&1, ;, ~, ., .., $!, !:<n>, !<n>
Open a terminal window to interact with Linux
%%bash
whereis bash
bash: /usr/bin/bash /usr/share/man/man1/bash.1.gz
%%bash
ls -la /usr/bin/bash
-rwxr-xr-x 1 root root 964536 Oct 27 2021 /usr/bin/bash
Linux file system
Typical Linux directories
By next Thursday:
%%bash
# start in home directory
cd
# create this course' work space, with a full parent directory chain
mkdir -p 5P10/Lab1/house
echo cat > 5P10/Lab1/house/BR
echo dog >> 5P10/Lab1/house/BR
grep -R ^cat 5P10
echo cat2 > 5P10/Lab1/house/kitchen
grep -R ^cat 5P10
5P10/Lab1/house/BR:cat 5P10/Lab1/house/kitchen:cat2 5P10/Lab1/house/BR:cat
%%bash
cd
sed -ie 's/cat/dog/g' 5P10/Lab1/house/kitchen
grep -R ^dog 5P10
5P10/Lab1/house/kitchen:dog2 5P10/Lab1/house/BR:dog
%%bash
ps -u pstudent | grep Thunar
15119 ? 00:00:00 Thunar
%%bash
PID=`ps -u pstudent | grep Thunar | cut -f1 -d\ `
echo "We will be killing PID = $PID"
We will be killing PID = 15119