File:MVT.gif

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

MVT.gif(287 × 126 pixels, file size: 790 KB, MIME type: image/gif, looped, 200 frames, 8.0 s)

Captions

Captions

Add a one-line explanation of what this file represents

Summary[edit]

Description
English: Animation for the Mean Value Theorem for integration
Deutsch: Animation zum Mittelwertsatz für Integrale
Date
Source Own work
Author Auswahlaxiom
GIF development
InfoField
 
This GIF graphic was created with Asymptote.
Source code
InfoField

Asymptote code

import graph;

size(8cm, 0);

defaultpen(fontsize(14)+linewidth(0.8));

real dt = 0.04;
int n = 0;

void ship() {
	write(n);
	shipout(outprefix() + format("-%04d", n));
	++n;
}

real inf(real f(real), real a, real b, int n) {
	return min(map(f, uniform(a, b, n)));
}

real sup(real f(real), real a, real b, int n) {
	return max(map(f, uniform(a, b, n)));
}

real average(real f(real), real a, real b, int n) {
	return sum(map(f, uniform(a+(b-a)/(2*n), b-(b-a)/(2*n), n-1)))/n;
}

real f(real x) {
	return 2+4/(13-x)+sin(2sqrt(x^2+3)-3)/2-(x-4)^2/16;
}

real f(real x) {
	return 2+4/(13-x)+sin(2sqrt(x^2+3)-3)/2-(x-4)^2/16;
}

real xmax = 8;

xtick("$\xi$", xmax, invisible);
ytick("$f(\xi)$", sup(f, 0, xmax, 100), invisible);

for(real t = 0; t+dt/2 < 8; t += dt) {
	save();
	real x = (1-abs(t/4-1))*xmax;
	//real x = (0.9*cos(t/4*pi)+0.1*cos(t/4*pi*3)+1)/2*xmax;
	real y = f(x);
	fill((0, 0)--graph(f, 0, xmax)--(xmax, 0)--cycle, rgb(1.0, 0.5, 0.0)+opacity(0.5));
	fill(box((0, 0), (xmax, y)), rgb(0.0, 0.5, 1.0)+opacity(0.5));
	draw(Label("$f$", MidPoint, N), graph(f, 0, xmax));
	draw((x, 0)--(x, y), dashed);
	xaxis(0, xmax, above=true);
	yaxis(0, above=true);
	yaxis(YEquals(xmax), 0, above=true);
	yequals(y);
	xtick("$a$", 0);
	xtick("$b$", xmax);
	xtick("$\xi$", x);
	ytick("$f(\xi)$", y);
	dot((x, y));
	ship();
	restore();
}

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
current15:32, 29 March 2017Thumbnail for version as of 15:32, 29 March 2017287 × 126 (790 KB)Auswahlaxiom (talk | contribs)User created page with UploadWizard

There are no pages that use this file.

File usage on other wikis

The following other wikis use this file: