File:C0 seq cauchy in l2.gif

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

C0_seq_cauchy_in_l2.gif(400 × 300 pixels, file size: 58 KB, MIME type: image/gif, looped, 20 frames, 20 s)

Captions

Captions

Add a one-line explanation of what this file represents

Summary[edit]

Description
Português: Uma sequência de funções contínuas e Cauchy na norma L^2 que convergem para uma função descontínua.
English: A sequence of continuos function Cauchy in the L^2 norm, which converge to a noncontinuos function.
Date
Source Own work
Author Picknick

Código fonte[edit]

#!/usr/bin/env python
# -*- coding: utf-8 -*- 
'''
Este trabalho está licenciado sob a Licença Creative Commons 
Atribuição-CompartilhaIgual 4.0 Internacional. Para ver uma cópia desta licença,
visite https://creativecommons.org/licenses/by-sa/4.0/ ou envie uma carta 
para Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
'''

from __future__ import division
import numpy as np
import matplotlib.pylab as plt
import matplotlib.animation as animation

fig = plt.figure(figsize = (4,3), dpi=100, frameon=False)
ax = plt.subplot(1,1,1)
plt.axis('off')

#x - axis
ax.set_xlim((-1.5,1.5))
plt.arrow(-1.5,0,3,0,head_width=0.075, length_includes_head=True, facecolor='black')
plt.text(1.25, -0.2, r'$x$', fontsize=14)

#y- axis
ax.set_ylim((-0.25,1.75))
plt.arrow(0,-0.25,0,2,head_width=0.075, length_includes_head=True, facecolor='black')
plt.text(-0.2, 1.5, r'$y$', fontsize=14)

line1, = plt.plot([-1,0],[0,0],'b-', linewidth=1.5)
line2, = plt.plot([0,1],[0,1],'b-', linewidth=1.5)
line3, = plt.plot([1,1],[1,1],'b-', linewidth=1.5)
point1, = plt.plot(-1,0,'bo', markersize=4)
point2, = plt.plot(0,0,'bo', markersize=4)
point4, = plt.plot(1,1,'bo', markersize=4)

plt.plot([1,1],[-0.025,1],'k--', alpha=0.25)
plt.plot([-0.025,1],[1,1],'k--', alpha=0.25)
plt.text(0.95,-0.15,'$1$')
plt.text(-0.15,0.95,'$1$')

t = plt.text(-1,1,'')

def init():
    line1.set_color('blue')

    line2.set_color('blue')
    line2.set_xdata([0,1])

    line3.set_color('blue')
    line3.set_xdata([1,1])

    point1.set_color('blue')
    point2.set_marker('')
    point4.set_color('blue')
    t.set_text(r'$y = f_n(x)$')

    return line1, line2, line3, point1, point2, point4

def run(n):
    i = (1.75)**n
    if (n <= 12):
        line2.set_xdata([0,1/i])
        line2.set_marker('')

        line3.set_xdata([1/i,1])
    else:
        line1.set_color('red')

        line3.set_xdata([0,1])
        line3.set_color('red')

        line2.set_color('red')
        line2.set_xdata([0,0])
        line2.set_ydata([1,1])
        line2.set_marker('o')
        line2.set_markersize(4)
        line2.set_markerfacecolor('white')

        point1.set_color('red')
        point2.set_marker('o')
        point2.set_markersize(4)
        point2.set_markerfacecolor('red')
        point4.set_color('red')

        t.set_text(r'$f_n\to f\,\notin\,C^0$')

    return line1, line2, line3, point1, point2, point4

im_ani = animation.FuncAnimation(fig, run, np.arange(0,20), init_func=init, interval=100, blit=False)
im_ani.save('c0_seq_cauchy_in_l2.gif',writer='imagemagick',fps=1)

Licensing[edit]

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current04:24, 7 July 2016Thumbnail for version as of 04:24, 7 July 2016400 × 300 (58 KB)Picknick (talk | contribs)User created page with UploadWizard

The following page uses this file: