Programming Articles

Page 200 of 2547

Evaluate a Laguerre series at points x broadcast over the columns of the coefficient in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 175 Views

To evaluate a Laguerre series at points x, use the polynomial.laguerre.lagval() method in Python NumPy. This function broadcasts evaluation points over coefficient columns when tensor=False. Syntax numpy.polynomial.laguerre.lagval(x, c, tensor=True) Parameters The function accepts three parameters ? x − Array of points at which to evaluate the series. Can be scalar, list, or array c − Array of coefficients ordered so that coefficients for degree n are in c[n]. For multidimensional arrays, remaining indices enumerate multiple polynomials tensor − If True (default), extends coefficient shape. If False, broadcasts x over coefficient columns ...

Read More

Integrate a Laguerre series over axis 1 in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 216 Views

To integrate a Laguerre series, use the laguerre.lagint() method in Python. The method returns the Laguerre series coefficients c integrated m times from lbnd along axis. At each iteration the resulting series is multiplied by scl and an integration constant, k, is added. The scaling factor is for use in a linear change of variable. Syntax numpy.polynomial.laguerre.lagint(c, m=1, k=[], lbnd=0, scl=1, axis=0) Parameters c − Array of Laguerre series coefficients. If c is multidimensional, different axes correspond to different variables m − Order of integration, must be positive (Default: 1) k − Integration ...

Read More

Integrate a Laguerre series over specific axis in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 184 Views

The Laguerre polynomial integration in Python can be performed using NumPy's laguerre.lagint() method. This function integrates Laguerre series coefficients along a specified axis, allowing for flexible multi-dimensional operations. Syntax numpy.polynomial.laguerre.lagint(c, m=1, k=[], lbnd=0, scl=1, axis=0) Parameters The function accepts the following parameters: c − Array of Laguerre series coefficients m − Order of integration (default: 1) k − Integration constant(s) (default: []) lbnd − Lower bound of integral (default: 0) scl − Scaling factor (default: 1) axis − Axis over which integration is performed (default: 0) Basic Integration Example ...

Read More

Generate a Vandermonde matrix of the Laguerre polynomial with float array of points in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 199 Views

To generate a Vandermonde matrix of the Laguerre polynomial, use the laguerre.lagvander() method in NumPy. This function returns a pseudo-Vandermonde matrix where each row contains the Laguerre polynomial values evaluated at a specific point. The Laguerre polynomials are orthogonal polynomials used in mathematical analysis and physics. The Vandermonde matrix has shape x.shape + (deg + 1, ), where the last index corresponds to the polynomial degree. Syntax numpy.polynomial.laguerre.lagvander(x, deg) Parameters x: Array of points. Converted to float64 or complex128 depending on element types. Scalar values are converted to 1-D arrays. deg: Degree ...

Read More

Generate a Vandermonde matrix of the Laguerre polynomial in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 205 Views

To generate a pseudo Vandermonde matrix of the Laguerre polynomial, use the laguerre.lagvander() function in Python NumPy. The method returns the pseudo-Vandermonde matrix with shape x.shape + (deg + 1, ), where the last index corresponds to the degree of the Laguerre polynomial. The dtype will match the converted x array. The parameter x is an array of points, converted to float64 or complex128 depending on whether elements are complex. If x is scalar, it converts to a 1-D array. The parameter deg specifies the degree of the resulting matrix. Syntax numpy.polynomial.laguerre.lagvander(x, deg) Parameters ...

Read More

Compute the roots of a Laguerre series with given complex roots in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 246 Views

To compute the roots of a Laguerre series, use the laguerre.lagroots() method in Python NumPy. The method returns an array of the roots of the series. If all the roots are real, then output is also real, otherwise it is complex. The root estimates are obtained as the eigenvalues of the companion matrix. Roots far from the origin of the complex plane may have large errors due to the numerical instability of the series for such values. Roots with multiplicity greater than 1 will also show larger errors as the value of the series near such points is relatively ...

Read More

Compute the roots of a Laguerre series in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 400 Views

To compute the roots of a Laguerre series, use the laguerre.lagroots() method in Python NumPy. The method returns an array of the roots of the series. If all the roots are real, then the output is also real, otherwise it is complex. The root estimates are obtained as the eigenvalues of the companion matrix. Roots far from the origin of the complex plane may have large errors due to the numerical instability of the series for such values. Roots with multiplicity greater than 1 will also show larger errors as the value of the series near such points is ...

Read More

Generate a Laguerre series with given complex roots in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 176 Views

To generate a Laguerre series with given complex roots, use the laguerre.lagfromroots() method in Python NumPy. This method returns a 1-D array of coefficients representing the Laguerre polynomial. If all roots are real, the output is a real array. If some roots are complex, the output is complex even if all coefficients in the result are real. Syntax numpy.polynomial.laguerre.lagfromroots(roots) Parameters roots: A sequence containing the roots of the polynomial. Example with Complex Roots Let's generate a Laguerre series with complex conjugate roots − from numpy.polynomial import laguerre as L ...

Read More

Generate a Laguerre series with given roots in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 192 Views

To generate a Laguerre series with given roots in Python NumPy, use the laguerre.lagfromroots() method. This function returns a 1-D array of coefficients representing the polynomial. If all roots are real, the output is a real array; if some roots are complex, the output is complex even if all resulting coefficients are real. Syntax numpy.polynomial.laguerre.lagfromroots(roots) Parameters: roots − Sequence containing the roots of the polynomial Returns: 1-D array of Laguerre series coefficients ordered from lowest to highest degree. Example with Real Roots Let's generate a Laguerre series with roots at ...

Read More

Integrate a Laguerre series over axis 0 in Python

AmitDiwan
AmitDiwan
Updated on 26-Mar-2026 189 Views

To integrate a Laguerre series over a specific axis in Python, use the numpy.polynomial.laguerre.lagint() method. This function integrates a Laguerre series along a specified axis, returning the integrated coefficients. Syntax numpy.polynomial.laguerre.lagint(c, m=1, k=[], lbnd=0, scl=1, axis=0) Parameters c − Array of Laguerre series coefficients. For multidimensional arrays, different axes correspond to different variables m − Order of integration (must be positive, default: 1) k − Integration constant(s). Default is empty list (all constants set to zero) lbnd − Lower bound of the integral (default: 0) scl − Scaling factor applied after each integration ...

Read More
Showing 1991–2000 of 25,469 articles
« Prev 1 198 199 200 201 202 2547 Next »
Advertisements