100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.2 TrustPilot
logo-home
Summary

Summary - Scientific computation with Python (MAS2806)

Rating
-
Sold
-
Pages
15
Uploaded on
24-04-2025
Written in
2024/2025

These notes combine theoretical explanations with practical Python examples, making it easy to understand key numerical methods and how to implement them. Topics covered: • Python basics and scientific libraries (NumPy, Matplotlib) • Root-finding algorithms (bisection, Newton-Raphson) • Numerical integration (trapezoidal rule, Simpson’s rule) • Solving differential equations (Euler’s method) • Interpolation and curve fitting • Error analysis and stability • Applications in scientific and mathematical modelling

Show more Read less









Whoops! We can’t load your doc right now. Try again or contact support.

Document information

Uploaded on
April 24, 2025
Number of pages
15
Written in
2024/2025
Type
Summary

Content preview

, Functions :

1) abs() Return the absolute value of a number


len() Return
2) the
length of an object
.



3) max() Find the value in a list or similar
largest object .




4) min() Find the smallest value in a list or similar object.
5) print( Print the value of an
object.
6) round (X , n) Round a number X +on decimal places

7) Sum)) Sum the values in a list or similar.

Data
type
:




*
Integer - int)

float)) decimal
*
Floating point number numbers
>




List< list) element
*
eg
2, 4
,
6 ordered collection of items.
XLy : 2 from
ay
element to a z-c



* Boolean - bool)) is an
object that is either true or false.

*
String < str(l sequences of characters




Range :

>
-
H

1) (start stopl (2 10)
range ,
eg range ,
2-9

step) /2 10 2)
2)
range(start
2 4 6 8
stop
eg rang
, ,
.
, , , ,




Numpy :




import asnp
numpy .




for functions
trigonometric
in
Python you need numpy
·




np .
cos(np pi) . .




·
up. array > to convert an
existing list to an
array x[ Secondroustorsecond column


93)
egX np array (23 6
= .


, ,




print (x(3) + [1 ,
2 ,
3)

numbers
arrange sequences of
·
up .




Control flow and functions :

· for loop : repeat commands a number of times


if run commands
only if a condition is satisfied
· :




· while : run commands
only while a condition is satisfied

· def : creating a new function
£4.86
Get access to the full document:

100% satisfaction guarantee
Immediately available after payment
Both online and in PDF
No strings attached

Get to know the seller
Seller avatar
corinageorgiou

Get to know the seller

Seller avatar
corinageorgiou University of Glasgow (Scotland)
View profile
Follow You need to be logged in order to follow users or courses
Sold
0
Member since
2 year
Number of followers
0
Documents
7
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their exams and reviewed by others who've used these revision notes.

Didn't get what you expected? Choose another document

No problem! You can straightaway pick a different document that better suits what you're after.

Pay as you like, start learning straight away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and smashed it. It really can be that simple.”

Alisha Student

Frequently asked questions