How to Create Matrix and Vector in modern Fortran (from 2003)

top of page

Search

The way modern Fortran provides to create matrix and vector is more convenient, let's check the example below. OUTPUT: A = 1.00000000 ...

Adisorn O.

- Jul 9
- 2 min

LAPACK Package Testing for LU Solver Ax = b

To solve the linear system Ax = b, LAPACK provide a function dgesv() see more detail https://netlib.org/lapack/explore-html-3.6.1/d7/d3b/...

3 views

Adisorn O.

- Jul 8
- 1 min

How to pass array variables to F90 subroutine?

Consider this example of fix-sized and allocatable array case I: Fix-sized array Case II: Allocatable array One important thing to remark...

6 views

Adisorn O.

- Feb 24
- 1 min

Compute the Minimum Distance between 2 sets of coordinates

The code will compute and get the minimum distance between 2 sets of arbitrary numbers of points in 2D space. It also draws the lines...

6 views

Adisorn O.

- Feb 23
- 3 min

Introduction to Julia and comparison with MATLAB syntax

OpenAI. (2024). ChatGPT (4) [Large language model]. https://chat.openai.com Jeff Bezanson, Stefan Karpinski, Viral B. Shah, and Alan...

9 views

Adisorn O.

- Feb 17
- 0 min

14 views

Adisorn O.

- Dec 27, 2023
- 1 min

A Unified Method for Numerical Integration

Trapezoidal rule Simpson's 1/3 rule

10 views

Adisorn O.

- Dec 6, 2023
- 2 min

F90 subroutine for Gauss Elimination with partial pivoting

! Main Program PROGRAM SolveLinearSystem IMPLICIT NONE REAL, DIMENSION(3, 3) :: A REAL, DIMENSION(3) :: b INTEGER :: n ! Define the...

9 views

Adisorn O.

- May 10, 2023
- 1 min

Passing functions as arguments in MATLAB

MATLAB allows us to pass functions as arguments of another function. This is very useful when we call other functions (for example,...

19 views

Adisorn O.

- May 2, 2023
- 1 min

Matrix Representation of a Linear System for Multiple Load Cases Analysis

In many engineering design problems, we often have to solve the same linear system for variable load cases. As shown in the figure below,...

18 views

Adisorn O.

- May 1, 2023
- 0 min

7 views

Adisorn O.

- May 1, 2023
- 0 min

16 views

Adisorn O.

- Apr 29, 2023
- 1 min

Newton-Raphson Method for solving nonlinear equation system and unconstrainted optimization problem

[updated 6.12.2023] For optimization problem, the optimum solution of (x1,x2) is found by setting the derivative of objectives of...

16 views

Adisorn O.

- Apr 17, 2023
- 1 min

Getting to know MATLAB's Cell

Sometimes we want to store various data types into a single array. Thinking of a container that can store various things in separate...

8 views

Adisorn O.

- Mar 17, 2023
- 1 min

MATLAB's sum() function

MATLAB provides a simple but efficient sum( ) function to sum column or row vector, as well as all elements in arrays. Syntax:...

14 views

bottom of page