20 lines
467 B
Python
20 lines
467 B
Python
"""Main script for numerik package."""
|
|
import sys
|
|
import os
|
|
|
|
# Ensure src directory is on the Python path for local imports
|
|
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "src"))
|
|
|
|
def main():
|
|
"""Demonstrate polynomial interpolation using divided differences."""
|
|
from serie_3 import poly_mat
|
|
|
|
x = [1, 2, 3, 4, 5]
|
|
y = [2, 3, 5, 7, 11]
|
|
|
|
result = poly_mat.poly_mat(list(zip(x, y)))
|
|
print(result)
|
|
|
|
if __name__ == "__main__":
|
|
main()
|