I have an example A legend states that when Euler saw that he could not visit every bridge once, he went on the seventh bridge and let himself drown in the Pregel river. This gave him a solution for the seven bridges problem ;-)
Well with no it_life I would have a game which has no solution. The states of the it_crack suggest an generalization of the eulerian paths: one would be allowed to pass a bridge 2 or 3 times (depending on the bridge) Alain Le 22/01/22 09:40, "Busser Alain" <alain.bus...@ac-reunion.fr> a écrit : > > Hello, > > to begin a new year, why not play with graphs ? Or rather create games on > graphs ? I think about 3 examples : > > 1) eulerian paths. The basic floor would be fl_water and each node of the > graph would be an island (say fl_sand). The edges of the graph would be made > of fl_bridge_bw but with it_crack.l on it (LARGE, water). The sides of the > bridges would be flanked by st_panel to avoid making the level too difficult > -I think it is not always easy to find an eulerian path, so take care not to > fall into the water is too much imho). The it_crack makes sure one can use > each bridge only once. To ensure that one must use the bridge, there would be > a row of gates somewhere and say a laser: every bridge has in it center a > fl_trigger and on passing the bridge, the trigger opens one door. Only when > all the doors are open, can the laser set light on the oxyd stones. An > historical example is the city of Königsberg but this one ( 4 nodes, 7 edges) > is not eulerian, as Euler showed in 1741. But in the same article, Euler gave > an example of eulerian graph, which adjacency matrix is > > 012122 > 100012 > 200101 > 101010 > 210101 > 221010 > > (this is a multigraph with 6 islands and 15 bridges, 8 of them emanating from > the first node). The examples given by Euler are all planar multigraphs, I > propose to stick on these, even if it is possible to implement non planar > graphs with vorticies. > > > > 2) hamiltonian paths. Planar graphs can be implemented with sandy islands > surrounded by water like the eulerian graph, but this time there is no > it_crack nor it_trigger on the bridge. But once an island has been visited, > it should be impossible for Blackball to visit it twice. So each island would > be surrounded by a ring which be visited exactly twice by Blackball (first, > entering the island from a bridge, second, leaving the island to get to > another bridge). On the center of the island, there is a switch which opens a > door of the corridor to that here again Blackball must visit all the islands. > Once a door is opened, there could appear it_crack on the ring to ensure the > flooding occurs when Blackball is leaving, but the cracking should be > propagated on all the ring so that Blackball can never come back to the same > island. Hamilton's example was the dodecahedron graph (20 islands connected > by 30 bridges!) but there are simpler hamiltonian graphs, for example the > cube (8 nodes, 12 edges) or the tetrahedron (4 islands connected by 6 bridges > as each island is connected to all the other ones). > > 3) 3-coloring of a graph. This one is more difficult to program. Blackball is > a gardener (no dangerous items here). On each island is a greenhouse (st_ice > or st_light_glass) and Blackball choose what to seed in the lighthouse > (fl_lawn, it_banana or it_cherry) but for the sake of biodiversity, there > should never be the same plant in greenhouses joined by a single bridge. Once > the conditions (any greenhouse contains a plant, and two adjacent greenhouses > do not contain the same plant) a door opens somewhere allowing Blackball to > reach an oxyd. So there must be some mechanism which checks the conditions. > Blackball could use st_fourswitch to choose the plant (or none) for the > greenhouse. The 4 colours theorem ensures that for any archipelago only 4 > plants are necessary, but in most cases 3 are enough. > > With several examples of each of these 3 problems, I mean games, there could > be enough to create a levelpack. It could be fun and interesting to develop > collaboratively this levelpack. I plan to give this task as homework to my > pupils. > > No need to read latin, just look at the maps on page 2: > http://eulerarchive.maa.org/backup/E053.html > > Alain > > > > > > > >
<?xml version="1.0" encoding="UTF-8" standalone="no" ?> <el:level xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://enigma-game.org/schema/level/1 level.xsd" xmlns:el="http://enigma-game.org/schema/level/1"> <el:protected> <el:info el:type="level"> <el:identity el:title="The seven bridges" el:subtitle="" el:id="alain27"/> <el:version el:score="1" el:release="1" el:revision="1" el:status="experimental"/> <el:author el:name="Alain Busser" el:email="" el:homepage=""/> <el:copyright>Copyright © 1743 Leonhard Euler</el:copyright> <el:license el:type="GPL v2.0 or above" el:open="true"/> <el:compatibility el:enigma="1.10"/> <el:modes el:easy="false" el:single="true" el:network="false"/> <el:score el:easy="-" el:difficult="-"/> </el:info> <el:luamain><![CDATA[ ti[" "] = {"fl_water"} ti["."] = {"fl_sand"} ti["1"] = ti["."] .. {"st_panel",faces="ew"} ti["2"] = ti["."] .. {"st_panel",faces="ns"} ti["#"] = ti["."] .. {"st_pinkbumps"} ti["-"] = ti["."] .. {"it_crack_l", flavor="water"} ti["O"] = ti["."] .. {"st_oxyd",flavor="a"} ti["@"] = ti["."] .. {"#ac_marble_black"} ti["a"] = ti["."] .. {"it_trigger",target="dA",action="open"} ti["b"] = ti["."] .. {"it_trigger",target="dB",action="open"} ti["c"] = ti["."] .. {"it_trigger",target="dC",action="open"} ti["d"] = ti["."] .. {"it_trigger",target="dD",action="open"} ti["e"] = ti["."] .. {"it_trigger",target="dE",action="open"} ti["f"] = ti["."] .. {"it_trigger",target="dF",action="open"} ti["g"] = ti["."] .. {"it_trigger",target="dG",action="open"} ti["A"] = {"st_door",flavor="d",faces="ew",name="dA"} ti["B"] = {"st_door",flavor="d",faces="ns",name="dB"} ti["C"] = {"st_door",flavor="d",faces="ns",name="dC"} ti["D"] = {"st_door",flavor="d",faces="ns",name="dD"} ti["E"] = {"st_door",flavor="d",faces="ns",name="dE"} ti["F"] = {"st_door",flavor="d",faces="ns",name="dF"} ti["G"] = {"st_door",flavor="d",faces="ns",name="dG"} ti["<"] = {"st_laser",orientation=WEST,state=ON} ti[">"] = {"st_mirror",flavor="triangle",orientation=EAST} wo(ti," ",{ "O .................", " .................", " 1-1 1-1 1-1 ", "D 1a1 1b1 1c1 ", "C 1-1 1-1 1-1 ", "B .......22222....", ">A<...@...--d--....", "E .......22222....", "F 1-1 1-1 1-1 ", "G 1e1 1f1 1g1 ", " 1-1 1-1 1-1 ", " .................", "O ................."}) wo:shuffleOxyd() ]]></el:luamain> <el:i18n> <el:string el:key="title"> <el:english el:translate="true" el:comment="The seven bridges."/> <el:translation el:lang="fr">Les 7 ponts</el:translation> </el:string> </el:i18n> </el:protected> </el:level>