Skip to content

Commit

Permalink
Folder creation 4 useful py scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
Goul-tard committed Dec 23, 2024
1 parent 92549a6 commit 668b529
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions utils/gauss_legendre_weights.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

# Resume: The script the roots and weights of the legendre polynomials
# of order n.
# See https://mathworld.wolfram.com/Legendre-GaussQuadrature.html


# w_i = (2 * (1-roots[i]**2)) / ((i+1)**2 * (PL(roots[i]))**2)


# SUM(W_i) = 2.

0 comments on commit 668b529

Please sign in to comment.