Pyspark, Finite Element Analysis, Mathematical Modeling, Databricks.
P[0,k] = left + k * h if k <= number_of_elements-1: T[0,k] = k T[1,k] = k+1 else: pass print(P) print(T) We might also allocate some space for our matrices P and T at the beginning of the code. import numpy as np right = 1 left = 0 h = 2**(-2) number_of_elements = int((right-left)/h) P =