एक लैगुएरे श्रृंखला को एक स्वतंत्र चर से गुणा करने के लिए, पायथन में polynomial.laguerre.lagmulx() विधि का उपयोग करें। लैगुएरे श्रृंखला c को x से गुणा करें, जहां x स्वतंत्र चर है। पैरामीटर c लैगुएरे श्रृंखला गुणांकों की एक 1-डी सरणी है जिसे निम्न से उच्च तक क्रमित किया गया है।
कदम
सबसे पहले, आवश्यक पुस्तकालय आयात करें -
import numpy as np from numpy.polynomial import laguerre as L
एक सरणी बनाएं -
c = np.array([1, 2, 3])
सरणी प्रदर्शित करें -
print("Our Array...\n",c) आयामों की जाँच करें -
print("\nDimensions of our Array...\n",c.ndim) डेटाटाइप प्राप्त करें -
print("\nDatatype of our Array object...\n",c.dtype) आकार प्राप्त करें -
print("\nShape of our Array object...\n",c.shape) एक लैगुएरे श्रृंखला को एक स्वतंत्र चर से गुणा करने के लिए, Python में polynomial.laguerre.lagmulx() विधि का उपयोग करें -
print("\nResult....\n",L.lagmulx(c)) उदाहरण
import numpy as np
from numpy.polynomial import laguerre as L
# Create an array
c = np.array([1, 2, 3])
# Display the array
print("Our Array...\n",c)
# Check the Dimensions
print("\nDimensions of our Array...\n",c.ndim)
# Get the Datatype
print("\nDatatype of our Array object...\n",c.dtype)
# Get the Shape
print("\nShape of our Array object...\n",c.shape)
# To multiply a Laguerre series by an independent variable, use the polynomial.laguerre.lagmulx() method in Python Numpy
print("\nResult....\n",L.lagmulx(c)) आउटपुट
Our Array... [1 2 3] Dimensions of our Array... 1 Datatype of our Array object... int64 Shape of our Array object... (3,) Result.... [-1. -1. 11. -9.]