<jupyter_start><jupyter_text>The coordinates of solution points using Gauss-Lobatto-Legendre quadrature points.<jupyter_code>xi = quad.GaussLobattoJacobi(4).nodes<jupyter_output><empty_output><jupyter_text>The Lagrange basis using the Gauss-Lobatto-Legendre quadrature points.<jupyter_code>Lk = poly.LagrangeBasis(xi)<jupyter_output><empty_output><jupyter_text>This is used to plotting the basis functions.<jupyter_code>x = numpy.linspace(-1., 1., 100)
phi = Lk(x)
pyplot.figure(figsize=(6, 3))
pyplot.plot(x, phi[:, 0], 'r-', lw=3, label="1st basis")
pyplot.plot(x, phi[:, 1], 'm-', lw=3, label="2nd basis")
pyplot.plot(x, phi[:, 2], 'c-', lw=3, label="3rd basis")
pyplot.plot(x, phi[:, 3], 'g-', lw=3, label="4th basis")
pyplot.plot(xi, numpy.zeros(4), 'k.--', lw=2, 
            markersize=15, markerfacecolor='r', markeredgecolor='r')
pyplot.plot(xi, numpy.ones(4), 'k.--', lw=2, 
            markersize=15, markerfacecolor='r', markeredgecolor='r')
pyplot.ylim(-0.2, 1.05)
pyplot.title(r'$\eta(\xi)$', fontsize=25)
pyplot.xlabel(r'$\xi$', fontsize=15)
pyplot.grid()
pyplot.legend(loc=0, bbox_to_anchor=(1.02, 1.04));<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.19808861859252824, 'fraction_numerical': 0.038227628149435276, 'mean_word_length': 6.2, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '3', 'dir': 'jupyter-structured-clean-dedup', 'id': '241239', 'license': 'MIT', 'n_tokens_mistral': 507, 'n_tokens_neox': 482, 'n_words': 84, 'path': 'Huynh2007/Fig2.1a.ipynb', 'repo_name': 'piyueh/SEM-Exercises', 'size': '1151'}