new file: Files/flashplayer_32_sa.exe new file: favicon.ico new file: globe.gif new file: imgs/download.png new file: imgs/zuck.jpg new file: index.html new file: other.ico new file: script.js new file: site.webmanifest new file: sitemap.html new file: styles/backround.css new file: styles/border.css new file: styles/fonts/Titillium_Web/OFL.txt new file: styles/fonts/Titillium_Web/TitilliumWeb-Black.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-Bold.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-BoldItalic.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-ExtraLight.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-ExtraLightItalic.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-Italic.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-Light.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-LightItalic.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-Regular.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-SemiBold.ttf new file: styles/fonts/Titillium_Web/TitilliumWeb-SemiBoldItalic.ttf new file: styles/fonts/webfontkit-20221027-163353/generator_config.txt new file: styles/fonts/webfontkit-20221027-163353/specimen_files/grid_12-825-55-15.css new file: styles/fonts/webfontkit-20221027-163353/specimen_files/specimen_stylesheet.css new file: styles/fonts/webfontkit-20221027-163353/stylesheet.css new file: styles/fonts/webfontkit-20221027-163353/titilliumweb-extralight-demo.html new file: styles/fonts/webfontkit-20221027-163353/titilliumweb-extralight-webfont.woff new file: styles/fonts/webfontkit-20221027-163353/titilliumweb-extralight-webfont.woff2 new file: styles/fonts/webfontkit-20221027-165950/generator_config.txt new file: styles/fonts/webfontkit-20221027-165950/specimen_files/grid_12-825-55-15.css new file: styles/fonts/webfontkit-20221027-165950/specimen_files/specimen_stylesheet.css new file: styles/fonts/webfontkit-20221027-165950/stylesheet.css new file: styles/fonts/webfontkit-20221027-165950/titilliumweb-bold-demo.html new file: styles/fonts/webfontkit-20221027-165950/titilliumweb-bold-webfont.woff new file: styles/fonts/webfontkit-20221027-165950/titilliumweb-bold-webfont.woff2 new file: styles/style.css new file: tools/2048/.gitignore new file: tools/2048/.jshintrc new file: tools/2048/CONTRIBUTING.md new file: tools/2048/LICENSE.txt new file: tools/2048/README.md new file: tools/2048/Rakefile new file: tools/2048/favicon.ico new file: tools/2048/index.html new file: tools/2048/js/animframe_polyfill.js new file: tools/2048/js/application.js new file: tools/2048/js/bind_polyfill.js new file: tools/2048/js/classlist_polyfill.js new file: tools/2048/js/game_manager.js new file: tools/2048/js/grid.js new file: tools/2048/js/html_actuator.js new file: tools/2048/js/keyboard_input_manager.js new file: tools/2048/js/local_storage_manager.js new file: tools/2048/js/tile.js new file: tools/2048/meta/apple-touch-icon.png new file: tools/webretro/cores/neocd_libretro.js new file: tools/webretro/cores/neocd_libretro.wasm new file: tools/webretro/cores/nestopia_libretro.js new file: tools/webretro/cores/nestopia_libretro.wasm new file: tools/webretro/cores/o2em_libretro.js new file: tools/webretro/cores/o2em_libretro.wasm new file: tools/webretro/cores/opera_libretro.js new file: tools/webretro/cores/opera_libretro.wasm
225 lines
12 KiB
HTML
225 lines
12 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en"><!-- #BeginTemplate "/Templates/Advanced.dwt" --><!-- DW6 -->
|
|
|
|
<!-- Mirrored from www.mathsisfun.com/sets/injective-surjective-bijective.html by HTTrack Website Copier/3.x [XR&CO'2014], Sat, 29 Oct 2022 01:00:39 GMT -->
|
|
<head>
|
|
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
|
<!-- #BeginEditable "doctitle" -->
|
|
<title>Injective, Surjective and Bijective</title>
|
|
<style type="text/css">
|
|
<!--
|
|
.style1 {font-weight: bold}
|
|
-->
|
|
</style>
|
|
<!-- #EndEditable -->
|
|
<meta name="keywords" content="math, maths, mathematics, school, homework, education">
|
|
|
|
<meta name="viewport" content="width=device-width; initial-scale=1.0; user-scalable=true;">
|
|
<meta name="HandheldFriendly" content="true">
|
|
<link rel="stylesheet" type="text/css" href="../style3.css">
|
|
<script src="../main3.js" type="text/javascript"></script>
|
|
</head>
|
|
|
|
<body id="bodybg" class="adv">
|
|
<div class="bg">
|
|
<div id="stt"></div>
|
|
<div id="hdr"></div>
|
|
<div id="logo"><a href="../index.html"><img src="../images/style/logo.svg" alt="Math is Fun"></a></div>
|
|
<div id="advText">Advanced</div>
|
|
<div id="gtran">
|
|
<script type="text/javascript">document.write(getTrans());</script></div>
|
|
<div id="gplus">
|
|
<script type="text/javascript">document.write(getGPlus());</script></div>
|
|
<div id="adTopOuter" class="centerfull noprint">
|
|
<div id="adTop">
|
|
<script type="text/javascript">document.write(getAdTop());</script>
|
|
</div>
|
|
</div>
|
|
<div id="adHide">
|
|
<div id="showAds1"><a href="javascript:showAds()">Show Ads</a></div>
|
|
<div id="hideAds1"><a href="javascript:hideAds()">Hide Ads</a><br>
|
|
<a href="../about-ads.html">About Ads</a></div>
|
|
</div>
|
|
<div id="menuWide" class="menu">
|
|
<script type="text/javascript">document.write(getMenu(0));</script>
|
|
</div>
|
|
<div id="linkto">
|
|
<div id="linktort">
|
|
<script type="text/javascript">document.write(getLinks());</script></div>
|
|
</div>
|
|
<div id="search" role="search">
|
|
<script type="text/javascript">document.write(getSearch());</script></div>
|
|
<div id="menuSlim" class="menu">
|
|
<script type="text/javascript">document.write(getMenu(1));</script>
|
|
</div>
|
|
<div id="menuTiny" class="menu">
|
|
<script type="text/javascript">document.write(getMenu(2));</script>
|
|
</div>
|
|
<div id="extra"></div>
|
|
</div>
|
|
<div id="content" role="main"><!-- #BeginEditable "Body" -->
|
|
|
|
<h1 align="center">Injective, Surjective and Bijective</h1>
|
|
<p align="center">"Injective, Surjective and Bijective" tells us about how a function behaves.</p>
|
|
<p>A <a href="function.html">function</a> is a way of matching the members of a set "A" <b>to</b> a set "B":
|
|
</p><br>
|
|
<div align="center">
|
|
<p><img src="images/function-mapping.svg" alt="General, Injective, Surjective and Bijective Functions"></p>
|
|
</div>
|
|
<p> </p>
|
|
<p>Let's look at that more closely:</p>
|
|
<div class="dotpoint">
|
|
|
|
<p>A <b>General Function</b> points from each member of "A" to a member of "B".</p>
|
|
<p>It <b>never</b> has one "A" pointing to more than one "B", so <b>one-to-many is not OK</b> in a function (so something like "f(x) = 7 <i><b>or</b></i> 9" is not allowed)</p>
|
|
<p>But more than one "A" can point to the same "B" (<b>many-to-one is OK</b>)</p>
|
|
|
|
</div>
|
|
|
|
<div class="dotpoint">
|
|
<p><b>Injective</b> means we won't have two or more "A"s pointing to the same "B". </p>
|
|
<p>So <b>many-to-one is NOT OK</b> (which is OK for a general function).</p>
|
|
<p>As it is also a function<b> one-to-many is not OK</b> </p>
|
|
<p>But we can have a "B" without a matching "A"</p>
|
|
<p>Injective is also called "<b>One-to-One</b>"</p>
|
|
|
|
</div>
|
|
<div class="dotpoint">
|
|
<p><b>Surjective</b> means that every "B" has <b>at least one</b> matching "A" (maybe more than one).</p>
|
|
<p>There won't be a "B" left out. </p>
|
|
</div>
|
|
<div class="dotpoint">
|
|
|
|
<p><b>Bijective</b> means both Injective and Surjective together. </p>
|
|
<p>Think of it as a "perfect pairing" between the sets: every one has a partner and no one is left out.</p>
|
|
<p>So there is a perfect "<b>one-to-one correspondence</b>" between the members of the sets. </p>
|
|
<p>(But don't get that confused with the term "One-to-One" used to mean injective).</p>
|
|
<div class="center80">
|
|
<p>Bijective functions have an <b>inverse</b>! </p>
|
|
<p>If every "A" goes to a unique "B", and every "B" has a matching "A" then we can go back and forwards without being led astray.</p>
|
|
<p>Read <a href="function-inverse.html">Inverse Functions</a> for more.</p>
|
|
</div>
|
|
|
|
</div>
|
|
<h2>On A Graph </h2>
|
|
<p>So let us see a few examples to understand what is going on. </p>
|
|
<p>When <b>A</b> and <b>B</b> are subsets of the Real Numbers we can graph the relationship. </p>
|
|
<p>Let us have <b>A</b> on the x axis and <b>B</b> on y, and look at our first example:</p>
|
|
<p class="center"><img src="images/vertical-line-test.svg" alt="function not single valued"></p>
|
|
|
|
<p>This is <b>not a function</b> because we have an <b>A</b> with many <b>B</b>. It is like saying f(x) = 2 <i><b>or</b></i> 4 </p>
|
|
<p>It fails the "Vertical Line Test" and so is not a function. But is still a valid relationship, so don't get angry with it.</p>
|
|
<p>Now, a general function can be like this:</p>
|
|
<p class="center"><img src="images/function-general-graph.svg" alt="General Function"><br>
|
|
<span class="larger">A General Function</span></p>
|
|
<p>It CAN (possibly) have a <b>B</b> with many <b>A</b>. For example sine, cosine, etc are like that. Perfectly valid functions.</p>
|
|
<p>But an "<b>Injective Function</b>" is stricter, and looks like this:</p>
|
|
<p class="center"><img src="images/function-injective-graph.svg" alt="Injective Function"><br>
|
|
<span class="larger">"Injective" (one-to-one)</span></p>
|
|
<p>In fact we can do a "Horizontal Line Test": </p>
|
|
<div class="def">
|
|
<p>To be <b>Injective</b>, a Horizontal Line should never intersect the curve at 2 or more points.</p>
|
|
</div>
|
|
<p><i>(Note: <a href="functions-increasing.html">Strictly Increasing (and Strictly Decreasing) functions</a> are Injective, you might like to read about them for more details)</i></p>
|
|
<p>So:</p>
|
|
<ul>
|
|
<li>If it passes the <b>vertical line test</b> it is a function</li>
|
|
<li>If it also passes the <b>horizontal line test</b> it is an injective function</li>
|
|
</ul>
|
|
<h2>Formal Definitions</h2>
|
|
<p>OK, stand by for more details about all this: </p>
|
|
<h3>Injective </h3>
|
|
|
|
<p>A function <b><i>f</i></b> is <b>injective</b> if and only if whenever <b><i>f(x) = f(y)</i></b>, <b><i> x = y</i></b>. </p>
|
|
<div class="example">
|
|
<p><b>Example:</b> <b><i>f</i>(<i>x</i>) = <i>x+5</i></b> from the set of real numbers <img src="../images/symbols/set-r.svg" alt="real numbers" height="16"> to <img src="../images/symbols/set-r.svg" alt="real numbers" height="16"> is an injective function. </p>
|
|
<p>Is it true that whenever <b><i>f(x) = f(y)</i></b>, <b><i> x = y</i></b> ?</p>
|
|
<p>Imagine x=3, then:</p>
|
|
<ul>
|
|
<li> f(x) = 8</li>
|
|
</ul>
|
|
<p>Now I say that f(y) = 8, what is the value of y? It can only be 3, so x=y </p>
|
|
</div>
|
|
<br>
|
|
|
|
<div class="example">
|
|
<p><b>Example:</b> <b><i>f</i>(<i>x</i>) = <i>x<sup>2</sup></i></b> from the set of real numbers <img src="../images/symbols/set-r.svg" alt="real numbers" height="16"> to <img src="../images/symbols/set-r.svg" alt="real numbers" height="16"> is <b class="large">not</b> an injective function because of this kind of thing:</p>
|
|
<ul>
|
|
<li><b><i>f</i>(<i>2</i>) =
|
|
|
|
4 </b>and </li>
|
|
<li><b><i>f</i>(<i>-2</i>) = 4</b></li>
|
|
</ul>
|
|
<p>This is against the definition <b><i>f(x) = f(y)</i></b>, <b><i> x = y</i></b>, because <i><b>f(2) = f(-2) but 2 ≠ -2</b></i></p>
|
|
<p>In other words there are <b>two</b> values of <b>A</b> that point to one <b>B</b>.</p>
|
|
<p> </p>
|
|
<p>BUT if we made it from the set of natural
|
|
numbers <img src="../images/symbols/set-n.svg" alt="natural numbers" height="16"> to <img src="../images/symbols/set-n.svg" alt="natural numbers" height="16"> then it <span class="large">is</span> injective, because:</p>
|
|
<ul>
|
|
<li><b><i>f</i>(<i>2</i>) =
|
|
|
|
4 </b></li>
|
|
<li>there is no f(-2), because -2 is not a natural
|
|
number</li>
|
|
</ul>
|
|
<p>So the domain and codomain of each set is important!</p>
|
|
</div>
|
|
<p> </p>
|
|
<h3>Surjective (Also Called "Onto")</h3>
|
|
<p> A function <b><i>f</i></b> (from set <i><b>A</b></i> to <i><b>B</b></i>) is <b>surjective</b> if and only if for every <b>
|
|
<em>y</em></b> in <i><b>B</b></i>, there is at least one <b><em>x</em></b> in <i><b>A</b></i> such that <span class="style1"><em>f</em>(<em>x</em>) = <em>y</em></span>,<b> </b>in other words <b><i>f</i></b> is surjective
|
|
if and only if
|
|
|
|
<b><i>f(A) = B</i></b>. </p>
|
|
<p>In simple terms: every B has some A. </p>
|
|
<div class="example">
|
|
<p><b>Example:</b> The function <b><i>f</i>(<i>x</i>) = <i>2x</i></b> from the set of natural
|
|
numbers <img src="../images/symbols/set-n.svg" alt="natural numbers" height="16"> to the set of non-negative <b>even</b> numbers is a <b>surjective</b> function. </p>
|
|
<p>BUT <b><i>f</i>(<i>x</i>) = <i>2x</i></b> from the set of natural
|
|
numbers <img src="../images/symbols/set-n.svg" alt="natural numbers" height="16"> to <img src="../images/symbols/set-n.svg" alt="natural numbers" height="16"> is <b>not surjective</b>, because, for example, no member in <img src="../images/symbols/set-n.svg" alt="natural numbers" height="16"> can be mapped to <b><i>3</i></b> by this function. </p>
|
|
</div>
|
|
|
|
<p> </p>
|
|
<h3>Bijective</h3>
|
|
<p>
|
|
A function <b><em>f</em></b> (from set <i><b>A</b></i> to <i><b>B</b></i>) is <b>bijective</b> if, for every <b><em>y</em></b> in <i><b>B</b></i>, there is exactly one <b><em>x</em></b> in <i><b>A</b></i> such that <span class="style1"><em>f</em>(<em>x</em>) = <em>y</em></span></p>
|
|
<p>Alternatively, <b><em>f</em></b> is bijective if it is a <strong>one-to-one correspondence</strong> between those sets, in other words both <strong>injective and surjective.</strong></p>
|
|
<div class="example">
|
|
<p>
|
|
<b>Example:</b> The function <b><i>f</i>(<i>x</i>) = <i>x<sup>2</sup></i></b> from the set of positive real
|
|
numbers to positive real
|
|
numbers is both injective and surjective.
|
|
Thus it is also <b>bijective</b>. </p>
|
|
<p>But the same function from the set of all real numbers <img src="../images/symbols/set-r.svg" alt="real numbers" height="16"> is <span class="large">not</span> bijective because we could have, for example, both</p>
|
|
<ul>
|
|
<li><b><i>f</i>(<i>2</i>)=4 and </b></li>
|
|
<li><b><i>f</i>(<i>-2</i>)=4</b></li>
|
|
</ul>
|
|
</div><p> </p>
|
|
|
|
<div class="questions">
|
|
|
|
<script type="text/javascript">getQ(2448, 2449, 2450, 2451, 7285, 7286, 7287, 7288, 2452, 7289);</script>
|
|
|
|
</div>
|
|
|
|
<div class="related">
|
|
<a href="function.html">Functions</a>
|
|
<a href="sets-introduction.html">Sets</a>
|
|
<a href="number-types.html">Common Number Sets</a>
|
|
<a href="domain-range-codomain.html">Domain, Range and Codomain</a> <a href="index.html">Sets Index</a></div>
|
|
<!-- #EndEditable --></div>
|
|
<div id="adend" class="centerfull noprint">
|
|
<script type="text/javascript">document.write(getAdEnd());</script>
|
|
</div>
|
|
<div id="footer" class="centerfull noprint">
|
|
<script type="text/javascript">document.write(getFooter());</script>
|
|
</div>
|
|
<div id="copyrt">
|
|
Copyright © 2017 MathsIsFun.com
|
|
</div>
|
|
|
|
<script type="text/javascript">document.write(getBodyEnd());</script>
|
|
</body><!-- #EndTemplate -->
|
|
<!-- Mirrored from www.mathsisfun.com/sets/injective-surjective-bijective.html by HTTrack Website Copier/3.x [XR&CO'2014], Sat, 29 Oct 2022 01:00:40 GMT -->
|
|
</html> |