text:
# Zelda casemod with levitating Triforce

Post Syndicated from Liz Upton original https://www.raspberrypi.org/blog/zelda-casemod-with-levitating-triforce/

I know: you’ve seen a bajillion RetroPie implementations before, and a bajillion casemods to go with them. But this one’s so hopelessly, magnificently splendid that we felt we had to share. Magnetic levitation. It’s not just for trains and frogs.

This Zelda casemod, covered with engraved pine from the forests of Hyrule and shiny brass mouldings hammered by…dwarves or something, would be gorgeous as-is. The levitating, mirrored Triforce twizzling away on top is the icing on the cake; and a very lovely cake it is too. Here’s some video (in Spanish, with English subtitles) from Tuberviejuner in Spain, walking you through the build.

#### Raspberry pi Zelda mod: MagicBerry WindWaker by Makomod & Tuberviejuner.

Raspberry pi Zelda mod: Magic Berry WindWaker The Legend of Zelda by Makomod & Tuberviejuner alucinad con el triforce levitador.

This magical piece of work is by MakoMod, a case modder who splits his time between Barcelona and Texas. There’s a Pi inside running RetroPie, and a separate electromagnetic device levitating the Triforce up top. If you’re interested in incorporating something like this into one of your own builds, there are two ways to go: make your own from scratch, as DrewPaul Designs has done here, or buy a pre-built kit.

If you get in there quickly, you’ve a chance to own this one-off case: MakoMod is auctioning it on eBay. You’ve got until July 14 2018 to bid – good luck!

The post Zelda casemod with levitating Triforce appeared first on Raspberry Pi.

# SUPER game night 3: GAMES MADE QUICK??? 2.0

Post Syndicated from Eevee original https://eev.ee/blog/2018/01/23/super-game-night-3-games-made-quick-2-0/

Game night continues with a smorgasbord of games from my recent game jam, GAMES MADE QUICK??? 2.0!

The idea was to make a game in only a week while watching AGDQ, as an alternative to doing absolutely nothing for a week while watching AGDQ. (I didn’t submit a game myself; I was chugging along on my Anise game, which isn’t finished yet.)

I can’t very well run a game jam and not play any of the games, so here’s some of them in no particular order! Enjoy!

These are impressions, not reviews. I try to avoid major/ending spoilers, but big plot points do tend to leave impressions.

## Weather Quest, by timlmul

short · rpg · jan 2017 · (lin)/mac/win · free on itch · jam entry

Weather Quest is its author’s first shipped game, written completely from scratch (the only vendored code is a micro OO base). It’s very short, but as someone who has also written LÖVE games completely from scratch, I can attest that producing something this game-like in a week is a fucking miracle. Bravo!

For reference, a week into my first foray, I think I was probably still writing my own Tiled importer like an idiot.

Only Mac and Windows builds are on itch, but it’s a LÖVE game, so Linux folks can just grab a zip from GitHub and throw that at love.

FINAL SCORE: ⛅☔☀

## Pancake Numbers Simulator, by AnorakThePrimordial

short · sim · jan 2017 · lin/mac/win · free on itch · jam entry

Given a stack of N pancakes (of all different sizes and in no particular order), the Nth pancake number is the most flips you could possibly need to sort the pancakes in order with the smallest on top. A “flip” is sticking a spatula under one of the pancakes and flipping the whole sub-stack over. There’s, ah, a video embedded on the game page with some visuals.

Anyway, this game lets you simulate sorting a stack via pancake flipping, which is surprisingly satisfying! I enjoy cleaning up little simulated messes, such as… incorrectly-sorted pancakes, I guess?

This probably doesn’t work too well as a simulator for solving the general problem — you’d have to find an optimal solution for every permutation of N pancakes to be sure you were right. But it’s a nice interactive illustration of the problem, and if you know the pancake number for your stack size of choice (which I wish the game told you — for seven pancakes, it’s 8), then trying to restore a stack in that many moves makes for a nice quick puzzle.

FINAL SCORE: $$\frac{18}{11}$$

## Framed Animals, by chridd

short · metroidvania · jan 2017 · web/win · free on itch · jam entry

The concept here was to kill the frames, save the animals, which is a delightfully literal riff on a long-running AGDQ/SGDQ donation incentive — people vote with their dollars to decide whether Super Metroid speedrunners go out of their way to free the critters who show you how to walljump and shinespark. Super Metroid didn’t have a showing at this year’s AGDQ, and so we have this game instead.

It’s rough, but clever, and I got really into it pretty quickly — each animal you save gives you a new ability (in true Metroid style), and you get to test that ability out by playing as the animal, with only that ability and no others, to get yourself back to the most recent save point.

I did, tragically, manage to get myself stuck near what I think was about to be the end of the game, so some of the animals will remain framed forever. What an unsatisfying conclusion.

Gravity feels a little high given the size of the screen, and like most tile-less platformers, there’s not really any way to gauge how high or long your jump is before you leap. But I’m only even nitpicking because I think this is a great idea and I hope the author really does keep working on it.

FINAL SCORE: \$136,596.69

## Battle 4 Glory, by Storyteller Games

short · fighter · jan 2017 · win · free on itch · jam entry

This is a Smash Bros-style brawler, complete with the four players, the 2D play area in a 3D world, and the random stage obstacles showing up. I do like the Smash style, despite not otherwise being a fan of fighting games, so it’s nice to see another game chase that aesthetic.

Alas, that’s about as far as it got — which is pretty far for a week of work! I don’t know what more to say, though. The environments are neat, but unless I’m missing something, the only actions at your disposal are jumping and very weak melee attacks. I did have a good few minutes of fun fruitlessly mashing myself against the bumbling bots, as you can see.

FINAL SCORE: 300%

## Icnaluferu Guild, Year Sixteen, by CHz

short · adventure · jan 2017 · web · free on itch · jam entry

Here we have the first of several games made with bitsy, a micro game making tool that basically only supports walking around, talking to people, and picking up items.

I tell you this because I think half of my appreciation for this game is in the ways it wriggled against those limits to emulate a Zelda-like dungeon crawler. Everything in here is totally fake, and you can’t really understand just how fake unless you’ve tried to make something complicated with bitsy.

It’s pretty good. The dialogue is entertaining (the rest of your party develops distinct personalities solely through oneliners, somehow), the riffs on standard dungeon fare are charming, and the Link’s Awakening-esque perspective walls around the edges of each room are fucking glorious.

FINAL SCORE: 2 bits

## The Lonely Tapes, by JTHomeslice

short · rpg · jan 2017 · web · free on itch · jam entry

Another bitsy entry, this one sees you play as a Wal— sorry, a JogDawg, which has lost its cassette tapes and needs to go recover them!

(A cassette tape is like a VHS, but for music.)

(A VHS is—)

I have the sneaking suspicion that I missed out on some musical in-jokes, due to being uncultured swine. I still enjoyed the game — it’s always clear when someone is passionate about the thing they’re writing about, and I could tell I was awash in that aura even if some of it went over my head. You know you’ve done good if someone from way outside your sphere shows up and still has a good time.

FINAL SCORE: Nine… Inch Nails? They’re a band, right? God I don’t know write your own damn joke

## Pirate Kitty-Quest, by TheKoolestKid

short · adventure · jan 2017 · win · free on itch · jam entry

I completely forgot I’d even given “my birthday” and “my cat” as mostly-joking jam themes until I stumbled upon this incredible gem. I don’t think — let me just check here and — yeah no this person doesn’t even follow me on Twitter. I have no idea who they are?

BUT THEY MADE A GAME ABOUT ANISE AS A PIRATE, LOOKING FOR TREASURE

PIRATE. ANISE

PIRATE ANISE!!!

This game wins the jam, hands down. 🏆

FINAL SCORE: Yarr, eight pieces o’ eight

## CHIPS Mario, by NovaSquirrel

short · platformer · jan 2017 · (lin/mac)/win · free on itch · jam entry

You see this? This is fucking witchcraft.

This game is made with MegaZeux. MegaZeux games look like THIS. Text-mode, bound to a grid, with two colors per cell. That’s all you get.

Until now, apparently?? The game is a tech demo of “unbound” sprites, which can be drawn on top of the character grid without being aligned to it. And apparently have looser color restrictions.

The collision is a little glitchy, which isn’t surprising for a MegaZeux platformer; I had some fun interactions with platforms a couple times. But hey, goddamn, it’s free-moving Mario, in MegaZeux, what the hell.

(I’m looking at the most recently added games on DigitalMZX now, and I notice that not only is this game in the first slot, but NovaSquirrel’s MegaZeux entry for Strawberry Jam last February is still in the seventh slot. RIP, MegaZeux. I’m surprised a major feature like this was even added if the community has largely evaporated?)

FINAL SCORE: n/a, disqualified for being probably summoned from the depths of Hell

## d!¢< pic, by 573 Games

short · story · jan 2017 · web · free on itch · jam entry

This is a short story about not sending dick pics. It’s very short, so I can’t say much without spoiling it, but: you are generally prompted to either text something reasonable, or send a dick pic. You should not send a dick pic.

It’s a fascinating artifact, not because of the work itself, but because it’s so terse that I genuinely can’t tell what the author was even going for. And this is the kind of subject where the author was, surely, going for something. Right? But was it genuinely intended to be educational, or was it tongue-in-cheek about how some dudes still don’t get it? Or is it side-eying the player who clicks the obviously wrong option just for kicks, which is the same reason people do it for real? Or is it commentary on how “send a dick pic” is a literal option for every response in a real conversation, too, and it’s not that hard to just not do it — unless you are one of the kinds of people who just feels a compulsion to try everything, anything, just because you can? Or is it just a quick Twine and I am way too deep in this? God, just play the thing, it’s shorter than this paragraph.

I’m also left wondering when it is appropriate to send a dick pic. Presumably there is a correct time? Hopefully the author will enter Strawberry Jam 2 to expound upon this.

FINAL SCORE: 3½” 😉

## Marble maze, by Shtille

short · arcade · jan 2017 · win · free on itch · jam entry

Ah, hm. So this is a maze navigated by rolling a marble around. You use WASD to move the marble, and you can also turn the camera with the arrow keys.

The trouble is… the marble’s movement is always relative to the world, not the camera. That means if you turn the camera 30° and then try to move the marble, it’ll move at a 30° angle from your point of view.

That makes navigating a maze, er, difficult.

Camera-relative movement is the kind of thing I take so much for granted that I wouldn’t even think to do otherwise, and I think it’s valuable to look at surprising choices that violate fundamental conventions, so I’m trying to take this as a nudge out of my comfort zone. What could you design in an interesting way that used world-relative movement? Probably not the player, but maybe something else in the world, as long as you had strong landmarks? Hmm.

FINAL SCORE: ᘔ

## Refactor: flight, by fluffy

short · arcade · jan 2017 · lin/mac/win · free on itch · jam entry

Refactor is a game album, which is rather a lot what it sounds like, and Flight is one of the tracks. Which makes this a single, I suppose.

It’s one of those games where you move down an oddly-shaped tunnel trying not to hit the walls, but with some cute twists. Coins and gems hop up from the bottom of the screen in time with the music, and collecting them gives you points. Hitting a wall costs you some points and kills your momentum, but I don’t think outright losing is possible, which is great for me!

Also, the monk cycles through several animal faces. I don’t know why, and it’s very good. One of those odd but memorable details that sits squarely on the intersection of abstract, mysterious, and a bit weird, and refuses to budge from that spot.

The music is great too? Really chill all around.

FINAL SCORE: 🎵🎵🎵🎵

short · adventure · jan 2017 · web · free on itch · jam entry

Another bitsy game, this one starring a pig (humorously symbolized by a giant pig nose with ears) who must collect fruit and solve some puzzles.

This is charmingly nostalgic for me — it reminds me of some standard fare in engines like MegaZeux, where the obvious things to do when presented with tiles and pickups were to make mazes. I don’t mean that in a bad way; the maze is the fundamental environmental obstacle.

A couple places in here felt like invisible teleport mazes I had to brute-force, but I might have been missing a hint somewhere. I did make it through with only a little trouble, but alas — I stepped in a bad warp somewhere and got sent to the upper left corner of the starting screen, which is surrounded by walls. So Klyde’s new life is being trapped eternally in a nowhere space.

FINAL SCORE: 19/20 apples

## And more

That was only a third of the games, and I don’t think even half of the ones I’ve played. I’ll have to do a second post covering the rest of them? Maybe a third?

Or maybe this is a ludicrous format for commenting on several dozen games and I should try to narrow it down to the ones that resonated the most for Strawberry Jam 2? Maybe??

# Weekly roundup: Out of potluck

Post Syndicated from Eevee original https://eev.ee/dev/2017/07/10/weekly-roundup-out-of-potluck/

Spoilers: I didn’t finish the potluck game! I think I bit off a little more than I could chew, since the game necessarily needs a bunch of mechanics and world to actually make use of all the tiles. So I’ll just… keep working on it over time. It’d be nice to finish by the end of the month, but suddenly I have far more stuff than before to be working on, so who knows anything.

• potluck: I made an inventory, added UI for it, implemented the other colors of locks, made several kinds of projectiles, implemented damage and recoil and i-frames, made a whole menu for customizing gamepad controls, rigged a convoluted thing that tries to adapt the UI to the style of gamepad you’re using, implemented conveyor belts, and did a whole lot of planning. But still, so far to go, sob.

• fox flux: Started touching up portraits from the first game while watching glip play Zelda. Results thusfar are promising!

• chaos composer: I have been drafted into working on glip’s game, already in progress in Unity. I just got ahold of the game thusfar, and I’ve never used Unity before, so I’ve mostly been giving myself a crash course by clicking stuff at random to see what happens.

I have no idea what I’ll be doing this next week! I have a lot of things vying for my attention, and somehow the month is already one-third over. I’d like to knock out some low-hanging fruit, so maybe I’ll get blogging out of the way and try to finally finish veekun?

# Some memorable levels

Post Syndicated from Eevee original https://eev.ee/blog/2017/07/01/some-memorable-levels/

Another Patreon request from Nova Dasterin:

Maybe something about level design. In relation to a vertical shmup since I’m working on one of those.

I’ve been thinking about level design a lot lately, seeing as how I’ve started… designing levels. Shmups are probably the genre I’m the worst at, but perhaps some general principles will apply universally.

And speaking of general principles, that’s something I’ve been thinking about too.

I’ve been struggling to create a more expansive tileset for a platformer, due to two general problems: figuring out what I want to show, and figuring out how to show it with a limited size and palette. I’ve been browsing through a lot of pixel art from games I remember fondly in the hopes of finding some inspiration, but so far all I’ve done is very nearly copy a dirt tile someone submitted to my potluck project.

Recently I realized that I might have been going about looking for inspiration all wrong. I’ve been sifting through stuff in the hopes of finding something that would create some flash of enlightenment, but so far that aimless tourism has only found me a thing or two to copy.

I don’t want to copy a small chunk of the final product; I want to understand the underlying ideas that led the artist to create what they did in the first place. Or, no, that’s not quite right either. I don’t want someone else’s ideas; I want to identify what I like, figure out why I like it, and turn that into some kinda of general design idea. Find the underlying themes that appeal to me and figure out some principles that I could apply. You know, examine stuff critically.

I haven’t had time to take a deeper look at pixel art this way, so I’ll try it right now with level design. Here, then, are some levels from various games that stand out to me for whatever reason; the feelings they evoke when I think about them; and my best effort at unearthing some design principles from those feelings.

## Doom II: MAP10, Refueling Base

screenshots mine — map via doom wiki — see also textured perspective map (warning: large!) via ian albertpistol start playthrough

I’m surprising myself by picking Refueling Base. I would’ve expected myself to pick MAP08, Tricks and Traps, for its collection of uniquely bizarre puzzles and mechanisms. Or MAP13, Downtown, the map that had me convinced (erroneously) that Doom levels supported multi-story structures. Or at least MAP08, The Pit, which stands out for the unique way it feels like a plunge into enemy territory.

(Curiously, those other three maps are all Sandy Petersen’s sole work. Refueling Base was started by Tom Hall in the original Doom days, then finished by Sandy for Doom II.)

But Refueling Base is the level I have the most visceral reaction to: it terrifies me.

See, I got into Doom II through my dad, who played it on and off sometimes. My dad wasn’t an expert gamer or anything, but as a ten-year-old, I assumed he was. I watched him play Refueling Base one night. He died. Again, and again, over and over. I don’t even have very strong memories of his particular attempts, but watching my parent be swiftly and repeatedly defeated — at a time when I still somewhat revered parents — left enough of an impression that hearing the level music still makes my skin crawl.

This may seem strange to bring up as a first example in a post about level design, but I don’t think it would have impressed on me quite so much if the level weren’t designed the way it is. (It’s just a video game, of course, and since then I’ve successfully beaten it from a pistol start myself. But wow, little kid fears sure do linger.)

The one thing that most defines the map has to be its interconnected layout. Almost every major area (of which there are at least half a dozen) has at least three exits. Not only are you rarely faced with a dead end, but you’ll almost always have a choice of where to go next, and that choice will lead into more choices.

This hugely informs the early combat. Many areas near the beginning are simply adjacent with no doors between them, so it’s easy for monsters to start swarming in from all directions. It’s very easy to feel overwhelmed by an endless horde; no matter where you run, they just seem to keep coming. (In fact, Refueling Base has the most monsters of any map in the game by far: 279. The runner up is the preceding map at 238.) Compounding this effect is the relatively scant ammo and health in the early parts of the map; getting very far from a pistol start is an uphill battle.

The connections between rooms also yield numerous possible routes through the map, as well as several possible ways to approach any given room. Some of the connections are secrets, which usually connect the “backs” of two rooms. Clearing out one room thus rewards you with a sneaky way into another room that puts you behind all the monsters.

In fact, the map rewards you for exploring it in general.

Well, okay. It might be more accurate to say that that map punishes you for not exploring it. From a pistol start, the map is surprisingly difficult — the early areas offer rather little health and ammo, and your best chance of success is a very specific route that collects weapons as quickly as possible. Many of the most precious items are squirrelled away in (numerous!) secrets, and you’ll have an especially tough time if you don’t find any of them — though they tend to be telegraphed.

One particularly nasty surprise is in the area shown above, which has three small exits at the back. Entering or leaving via any of those exits will open one of the capsule-shaped pillars, revealing even more monsters. A couple of those are pain elementals, monsters which attack by spawning another monster and shooting it at you — not something you want to be facing with the starting pistol.

But nothing about the level indicates this, so you have to make the association the hard way, probably after making several mad dashes looking for cover. My successful attempt avoided this whole area entirely until I’d found some more impressive firepower. It’s fascinating to me, because it’s a fairly unique effect that doesn’t make any kind of realistic sense, yet it’s still built out of familiar level mechanics: walk through an area and something opens up. Almost like 2D sidescroller design logic applied to a 3D space. I really like it, and wish I saw more of it. So maybe that’s a more interesting design idea: don’t be afraid to do something weird only once, as long as it’s built out of familiar pieces so the player has a chance to make sense of it.

A similarly oddball effect is hidden in a “barracks” area, visible on the far right of the map. A secret door leads to a short U-shaped hallway to a marble skull door, which is themed nothing like the rest of the room. Opening it seems to lead back into the room you were just in, but walking through the doorway teleports you to a back entrance to the boss fight at the end of the level.

It sounds so bizarre, but the telegraphing makes it seem very natural; if anything, the “oh, I get it!” moment overrides the weirdness. It stops being something random and becomes something consciously designed. I believe that this might have been built by someone, even if there’s no sensible reason to have built it.

In fact, that single weird teleporter is exactly the kind of thing I’d like to be better at building. It could’ve been just a plain teleporter pad, but instead it’s a strange thing that adds a lot of texture to the level and makes it much more memorable. I don’t know how to even begin to have ideas like that. Maybe it’s as simple as looking at mundane parts of a level and wondering: what could I do with this instead?

I think a big problem I have is limiting myself to the expected and sensible, to the point that I don’t even consider more outlandish ideas. I can’t shake that habit simply by bolding some text in a blog post, but maybe it would help to keep this in mind: you can probably get away with anything, as long as you justify it somehow. Even “justify” here is too strong a word; it takes only the slightest nod to make an arbitrary behavior feel like part of a world. Why does picking up a tiny glowing knight helmet give you 1% armor in Doom? Does anyone care? Have you even thought about it before? It’s green and looks like armor; the bigger armor pickup is also green; yep, checks out.

On the other hand, the map as a whole ends up feeling very disorienting. There’s no shortage of landmarks, but every space is distinct in both texture and shape, so everything feels like a landmark. No one part of the map feels particularly central; there are a few candidates, but they neighbor other equally grand areas with just as many exits. It’s hard to get truly lost, but it’s also hard to feel like you have a solid grasp of where everything is. The space itself doesn’t make much sense, even though small chunks of it do. Of course, given that the Hellish parts of Doom were all just very weird overall, this is pretty fitting.

This sort of design fascinates me, because the way it feels to play is so different from the way it looks as a mapper with God Vision. Looking at the overhead map, I can identify all the familiar places easily enough, but I don’t know how to feel the way the map feels to play; it just looks like some rooms with doors between them. Yet I can see screenshots and have a sense of how “deep” in the level they are, how difficult they are to reach, whether I want to visit or avoid them. The lesson here might be that most of the interesting flavor of the map isn’t actually contained within the overhead view; it’s in the use of height and texture and interaction.

I realize as I describe all of this that I’m really just describing different kinds of contrast. If I know one thing about creative work (and I do, I only know one thing), it’s that effectively managing contrast is super duper important.

And it appears here in spades! A brightly-lit, outdoor, wide-open round room is only a short jog away from a dark, cramped room full of right angles and alcoves. A wide straight hallway near the beginning is directly across from a short, curvy, organic hallway. Most of the monsters in the map are small fry, but a couple stronger critters are sprinkled here and there, and then the exit is guarded by the toughest monster in the game. Some of the connections between rooms are simple doors; others are bizarre secret corridors or unnatural twisty passages.

You could even argue that the map has too much contrast, that it starts to lose cohesion. But if anything, I think this is one of the more cohesive maps in the first third of the game; many of the earlier maps aren’t so much places as they are concepts. This one feels distinctly like it could be something. The theming is all over the place, but enough of the parts seem deliberate.

I hadn’t even thought about it until I sat down to write this post, but since this is a “refueling base”, I suppose those outdoor capsules (which contain green slime, inset into the floor) could be the fuel tanks! I already referred to that dark techy area as “barracks”. Elsewhere is a rather large barren room, which might be where the vehicles in need of refueling are parked? Or is this just my imagination, and none of it was intended this way?

It doesn’t really matter either way, because even in this abstract world of ambiguity and vague hints, all of those rooms still feel like a place. I don’t have to know what the place is for it to look internally consistent.

I’m hesitant to say every game should have the loose design sense of Doom II, but it might be worth keeping in mind that anything can be a believable world as long as it looks consciously designed. And I’d say this applies even for natural spaces — we frequently treat real-world nature as though it were “designed”, just with a different aesthetic sense.

Okay, okay. I’m sure I could clumsily ramble about Doom forever, but I do that enough as it is. Other people have plenty to say if you’re interested.

I do want to stick in one final comment about MAP13, Downtown, while I’m talking about theming. I’ve seen a few people rag on it for being “just a box” with a lot of ideas sprinkled around — the map is basically a grid of skyscrapers, where each building has a different little mini encounter inside. And I think that’s really cool, because those encounters are arranged in a way that very strongly reinforces the theme of the level, of what this place is supposed to be. It doesn’t play quite like anything else in the game, simply because it was designed around a shape for flavor reasons. Weird physical constraints can do interesting things to level design.

## Braid: World 4-7, Fickle Companion

screenshots via StrategyWikiplaythroughplaythrough of secret area

I love Braid. If you’re not familiar (!), it’s a platformer where you have the ability to rewind time — whenever you want, for as long as you want, all the way back to when you entered the level.

The game starts in world 2, where you do fairly standard platforming and use the rewind ability to do some finnicky jumps with minimal frustration. It gets more interesting in world 3 with the addition of glowing green objects, which aren’t affected by the reversal of time.

And then there’s world 4, “Time and Place”. I love world 4, so much. It’s unlike anything I’ve ever seen in any other game, and it’s so simple yet so clever.

The premise is this: for everything except you, time moves forwards as you move right, and backwards as you move left.

This has some weird implications, which all come together in the final level of the world, Fickle Companion. It’s so named because you have to use one (single-use) key to open three doors, but that key is very easy to lose.

Say you pick up the key and walk to the right with it. Time continues forwards for the key, so it stays with you as expected. Now you climb a ladder. Time is frozen since you aren’t moving horizontally, but the key stays with you anyway. Now you walk to the left. Oops — the key follows its own path backwards in time, going down the ladder and back along the path you carried it in the first place. You can’t fix this by walking to the right again, because that will simply advance time normally for the key; since you’re no longer holding it, it will simply fall to the ground and stay there.

You can see how this might be a problem in the screenshot above (where you get the key earlier in the level, to the left). You can climb the first ladder, but to get to the door, you have to walk left to get to the second ladder, which will reverse the key back down to the ground.

The solution is in the cannon in the upper right, which spits out a Goomba-like critter. It has the timeproof green glow, so the critters it spits out have the same green glow — making them immune to both your time reversal power and to the effect your movement has on time. What you have to do is get one of the critters to pick up the key and carry it leftwards for you. Once you have the puzzle piece, you have to rewind time and do it again elsewhere. (Or, more likely, the other way around; this next section acts as a decent hint for how to do the earlier section.)

It’s hard to convey how bizarre this is in just text. If you haven’t played Braid, it’s absolutely worth it just for this one world, this one level.

And it gets even better, slash more ridiculous: there’s a super duper secret hidden very cleverly in this level. Reaching it involves bouncing twice off of critters; solving the puzzle hidden there involves bouncing the critters off of you. It’s ludicrous and perhaps a bit too tricky, but very clever. Best of all, it’s something that an enterprising player might just think to do on a whim — hey, this is possible here, I wonder what happens if I try it. And the game rewards the player for trying something creative! (Ironically, it’s most rewarding to have a clever idea when it turns out the designer already had the same idea.)

What can I take away from this? Hm.

Well, the underlying idea of linking time with position is pretty novel, but getting to it may not be all that hard: just combine different concepts and see what happens.

A similar principle is to apply a general concept to everything and see what happens. This is the first sighting of a timeproof wandering critter; previously timeproofing had only been seen on keys, doors, puzzle pieces, and stationary monsters. Later it even applies to Tim himself in special circumstances.

The use of timeproofing on puzzle pieces is especially interesting, because the puzzle pieces — despite being collectibles that animate moving into the UI when you get them — are also affected by time. If the pieces in this level weren’t timeproof, then as soon as you collected one and moved left to leave its alcove, time would move backwards and the puzzle piece would reverse out of the UI and right back into the world.

Along similar lines, the music and animated background are also subject to the flow of time. It’s obvious enough that the music plays backwards when you rewind time, but in world 4, the music only plays at all while you’re moving. It’s a fantastic effect that makes the whole world feel as weird and jerky as it really is under these rules. It drives the concept home instantly, and it makes your weird influence over time feel all the more significant and far-reaching. I love when games weave all the elements of the game into the gameplaylike this, even (especially?) for the sake of a single oddball level.

Admittedly, this is all about gameplay or puzzle mechanics, not so much level design. What I like about the level itself is how simple and straightforward it is: it contains exactly as much as it needs to, yet still invites trying the wrong thing first, which immediately teaches the player why it won’t work. And it’s something that feels like it ought to work, except that the rules of the game get in the way just enough. This makes for my favorite kind of puzzle, the type where you feel like you’ve tried everything and it must be impossible — until you realize the creative combination of things you haven’t tried yet. I’m talking about puzzles again, oops; I guess the general level design equivalent of this is that players tend to try the first thing they see first, so if you put required parts later, players will be more likely to see optional parts.

I think that’s all I’ve got for this one puzzle room. I do want to say (again) that I love both endings of Braid. The normal ending weaves together the game mechanics and (admittedly loose) plot in a way that gave me chills when I first saw it; the secret ending completely changes both how the ending plays and how you might interpret the finale, all by making only the slightest changes to the level.

screenshot mine — playthrough of normal mapplaythrough of advanced map

I love Portal. I blazed through the game in a couple hours the night it came out. I’d seen the trailer and instantly grasped the concept, so the very slow and gentle learning curve was actually a bit frustrating for me; I just wanted to portal around a big playground, and I finally got to do that in the six “serious” tests towards the end, 13 through 18.

Valve threw an interesting curveball with these six maps. As well as being more complete puzzles by themselves, Valve added “challenges” requiring that they be done with as few portals, time, or steps as possible. I only bothered with the portal challenges — time and steps seemed less about puzzle-solving and more about twitchy reflexes — and within them I found buried an extra layer of puzzles. All of the minimum portal requirements were only possible if you found an alternative solution to the map: skipping part of it, making do with only one cube instead of two, etc. But Valve offered no hints, only a target number. It was a clever way to make me think harder about familiar areas.

Alongside the challenges were “advanced” maps, and these blew me away. They were six maps identical in layout to the last six test chambers, but with a simple added twist that completely changed how you had to approach them. Test 13 has two buttons with two boxes to place on them; the advanced version removes a box and also changes the floor to lava. Test 14 is a live fire course with turrets you have to knock over; the advanced version puts them all in impenetrable cages. Test 17 is based around making extensive use of a single cube; the advanced version changes it to a ball.

But the one that sticks out the most to me is test 18, a potpourri of everything you’ve learned so far. The beginning part has you cross several large pits of toxic sludge by portaling from the ceilings; the advanced version simply changes the ceilings to unportalable metal. It seems you’re completely stuck after only the first jump, unless you happen to catch a glimpse of the portalable floor you pass over in mid-flight. Or you might remember from the regular version of the map that the floor was portalable there, since you used it to progress further. Either way, you have to fire a portal in midair in a way you’ve never had to do before, and the result feels very cool, like you’ve defeated a puzzle that was intended to be unsolvable. All in a level that was fairly easy the first time around, and has been modified only slightly.

I’m not sure where I’m going with this. I could say it’s good to make the player feel clever, but that feels wishy-washy. What I really appreciated about the advanced tests is that they exploited inklings of ideas I’d started to have when playing through the regular game; they encouraged me to take the spark of inspiration this game mechanic gave me and run with it.

So I suppose the better underlying principle here — the most important principle in level design, in any creative work — is to latch onto what gets you fired up and run with it. I am absolutely certain that the level designers for this game loved the portal concept as much as I do, they explored it thoroughly, and they felt compelled to fit their wilder puzzle ideas in somehow.

More of that. Find the stuff that feels like it’s going to burst out of your head, and let it burst.

## Chip’s Challenge: Level 122, Totally Fair and Level 131, Totally Unfair

screenshots mine — full maps of both levelsplaythrough of Totally Fairplaythrough of Totally Unfair

I mention this because Portal reminded me of it. The regular and advanced maps in Portal are reminiscent of parallel worlds or duality or whatever you want to call the theme. I extremely dig that theme, and it shows up in Chip’s Challenge in an unexpected way.

Totally Fair is a wide open level with a little maze walled off in one corner. The maze contains a monster called a “teeth”, which follows Chip at a slightly slower speed. (The second teeth, here shown facing upwards, starts outside the maze but followed me into it when I took this screenshot.)

The goal is to lure the teeth into standing on the brown button on the right side. If anything moves into a “trap” tile (the larger brown recesses at the bottom), it cannot move out of that tile until/unless something steps on the corresponding brown button. So there’s not much room for error in maneuvering the teeth; if it falls in the water up top, it’ll die, and if it touches the traps at the bottom, it’ll be stuck permanently.

The reason you need the brown button pressed is to acquire the chips on the far right edge of the level.

The gray recesses turn into walls after being stepped on, so once you grab a chip, the only way out is through the force floors and ice that will send you onto the trap. If you haven’t maneuvered the teeth onto the button beforehand, you’ll be trapped there.

Doesn’t seem like a huge deal, since you can go see exactly how the maze is shaped and move the teeth into position fairly easily. But you see, here is the beginning of Totally Fair.

The gray recess leads up into the maze area, so you can only enter it once. A force floor in the upper right lets you exit it.

Totally Unfair is exactly identical, except the second teeth has been removed, and the entrance to the maze looks like this.

You can’t get into the maze area. You can’t even see the maze; it’s too far away from the wall. You have to position the teeth completely blind. In fact, if you take a single step to the left from here, you’ll have already dumped the teeth into the water and rendered the level impossible.

The hint tile will tell you to “Remember sjum”, where SJUM is the password to get back to Totally Fair. So you have to learn that level well enough to recreate the same effect without being able to see your progress.

It’s not impossible, and it’s not a “make a map” faux puzzle. A few scattered wall blocks near the chips, outside the maze area, are arranged exactly where the edges of the maze are. Once you notice that, all you have to do is walk up and down a few times, waiting a moment each time to make sure the teeth has caught up with you.

So in a sense, Totally Unfair is the advanced chamber version of Totally Fair. It makes a very minor change that force you to approach the whole level completely differently, using knowledge gleaned from your first attempt.

And crucially, it’s an actual puzzle! A lot of later Chip’s Challenge levels rely heavily on map-drawing, timing, tedium, or outright luck. (Consider, if you will, Blobdance.) The Totally Fair + Totally Unfair pairing requires a little ingenuity unlike anything else in the game, and the solution is something more than just combinations of existing game mechanics. There’s something very interesting about that hint in the walls, a hint you’d have no reason to pick up on when playing through the first level. I wish I knew how to verbalize it better.

Anyway, enough puzzle games; let’s get back to regular ol’ level design.

maps via vgmaps and TCRFplaythrough with commentary

Link’s Awakening was my first Zelda (and only Zelda for a long time), which made for a slightly confusing introduction to the series — what on earth is a Zelda and why doesn’t it appear in the game?

The whole game is a blur of curiosities and interesting little special cases. It’s fabulously well put together, especially for a Game Boy game, and the dungeons in particular are fascinating microcosms of design. I never really appreciated it before, but looking at the full maps, I’m struck by how each dungeon has several large areas neatly sliced into individual screens.

Much like with Doom II, I surprise myself by picking Eagle’s Tower as the most notable part of the game. The dungeon isn’t that interesting within the overall context of the game; it gives you only the mirror shield, possibly the least interesting item in the game, second only to the power bracelet upgrade from the previous dungeon. The dungeon itself is fairly long, full of traps, and overflowing with crystal switches and toggle blocks, making it possibly the most frustrating of the set. Getting to it involves spending some excellent quality time with a flying rooster, but you don’t really do anything — mostly you just make your way through nondescript caves and mountaintops.

Having now thoroughly dunked on it, I’ll tell you what makes it stand out: the player changes the shape of the dungeon.

That’s something I like a lot about Doom, as well, but it’s much more dramatic in Eagle’s Tower. As you might expect, the dungeon is shaped like a tower, where each floor is on a 4×4 grid. The top floor, 4F, is a small 2×2 block of rooms in the middle — but one of those rooms is the boss door, and there’s no way to get to that floor.

(Well, sort of. The “down” stairs in the upper-right of 3F actually lead up to 4F, but the connection is bogus and puts you in a wall, and both of the upper middle rooms are unreachable during normal gameplay.)

The primary objective of the dungeon is to smash four support columns on 2F by throwing a huge iron ball at them, which causes 4F to crash down into the middle of 3F.

Even the map on the pause screen updates to reflect this. In every meaningful sense, you, the player, have fundamentally reconfigured the shape of this dungeon.

I love this. It feels like I have some impact on the world, that I came along and did something much more significant than mere game mechanics ought to allow. I saw that the tower was unsolvable as designed, so I fixed it.

It’s clear that the game engine supports rearranging screens arbitrarily — consider the Wind Fish’s Egg — but this is s wonderfully clever and subtle use of that. Let the player feel like they have an impact on the world.

## The cutting room floor

This is getting excessively long so I’m gonna cut it here. Some other things I thought of but don’t know how to say more than a paragraph about:

• Super Mario Land 2: Six Golden Coins has a lot of levels with completely unique themes, backed by very simple tilesets but enhanced by interesting one-off obstacles and enemies. I don’t even know how to pick a most interesting one. Maybe just play the game, or at least peruse the maps.

• This post about density of detail in Team Fortress 2 is really good so just read that I guess. It’s really about careful balance of contrast again, but through the lens of using contrasting amounts of detail to draw the player’s attention, while still carrying a simple theme through less detailed areas.

• Metroid Prime is pretty interesting in a lot of ways, but I mostly laugh at how they spaced rooms out with long twisty hallways to improve load times — yet I never really thought about it because they all feel like they belong in the game.

One thing I really appreciate is level design that hints at a story, that shows me a world that exists persistently, that convinces me this space exists for some reason other than as a gauntlet for me as a player. But it seems what comes first to my mind is level design that’s clever or quirky, which probably says a lot about me. Maybe the original Fallouts are a good place to look for that sort of detail.

Conversely, it sticks out like a sore thumb when a game tries to railroad me into experiencing the game As The Designer Intended. Games are interactive, so the more input the player can give, the better — and this can be as simple as deciding to avoid rather than confront enemies, or deciding to run rather than walk.

I think that’s all I’ve got in me at the moment. Clearly I need to meditate on this a lot more, but I hope some of this was inspiring in some way!

# Weekly roundup: Breath of the Tired

Post Syndicated from Eevee original https://eev.ee/dev/2017/06/25/weekly-roundup-breath-of-the-tired/

I may have spoken too soon; I had some pretty sleepy nights this week. Oh, well. The slow march of progress continued nonetheless. Also I played Zelda a lot.

• potluck: I built a few little mechanisms: platforms, keys, switches, etc. I don’t have much game yet, but I’m putting off the bulk of it until GDQ week. Hope I can actually do this game justice in just a week! It’ll be a different kind of experience, since the art is set in stone and I already have an engine that can do most of what I want; I just have to build levels and story.

• book: I churned out a good few thousand words, rewrote the introduction, and got rid of a ton of stuff from the old book concept. It’s actually presentable as a work in progress now! Nice.

• veekun: I struggled with form ordering for quite a long time, but finally got it figured out, which is useful and important. Getting there. Also I had to yakshave my self-hosted git (which I use for ripped sprites), after an upgrade caused it to bitrot.

I did less than I would’ve liked, but I’ve still got some decent momentum on these three big things. Still feeling pretty good, and eagerly looking forward to having time free in July to mess around with art and work on fox flux.

# Weekly roundup: Successful juggling

Post Syndicated from Eevee original https://eev.ee/dev/2017/06/19/weekly-roundup-successful-juggling/

Despite flipping my sleep, as I seem to end up doing every month now, I’ve had a pretty solid week. We finally got our hands on a Switch, so I just played Zelda to stay up a ridiculously long time and restore my schedule pretty quickly.

• potluck: I started building the potluck game in LÖVE, and it’s certainly come along much faster — I have map transitions, dialogue, and a couple moving platforms working. I still don’t quite know what this game is, but I’m starting to get some ideas.

I also launched GAMES MADE QUICK??? 1½, a game jam for making a game while watching GDQ, instead of just plain watching GDQ. I intend to spend the week working on the potluck game, though I’m not sure whether I’ll finish it then.

• fox flux: I started planning out a more interesting overworld and doodled a couple relevant tiles. Terrain is still hard. Also some more player frames.

• art: I finally finished a glorious new banner, which now hangs proudly above my Twitter and Patreon. I did a bedtime slate doodle. I made and animated a low-poly Yoshi. I sketched Styx based on a photo.

I keep wishing I have time to dedicate to painting experiments, but I guess this is pretty good output.

• veekun: Wow! I touched veekun on three separate occasions. I have basic item data actually physically dumping now, I fixed some stuff with Pokémon, and I got evolutions working. Progress! Getting there! So close!

• blog: Per request, I wrote about digital painting software, though it was hampered slightly by the fact that most of it doesn’t run on my operating system.

I seem to be maintaining tangible momentum on multiple big projects, which is fantastic. And there’s still 40% of the month left! I’m feeling pretty good about where I’m standing; if I can get potluck and veekun done soon, that’ll be a medium and a VERY LARGE weight off my shoulders.

Post Syndicated from Alex Bate original https://www.raspberrypi.org/blog/steampunk-laptop/

In this digital age, where backup computers and multiple internet-connected devices are a must, maker phrazelle built this beautiful Raspberry Pi-powered steampunk laptop for his girlfriend.

And now we all want one. I mean, just look at it!

There’s no denying that, had Liz seen this before me, she’d have copied the link into an email and titled it INSTABLOG before sending it to my inbox.

This build is gorgeous. And as a fan of quirky-looking tech builds and of making things out of wood, it caught my eye in a heartbeat, causing me to exclaim “Why, I – ugh! – I want a Steampunk laptop?!” Shortly afterwards, there followed the realisation that there is an Instructables page for the project, leading me to rejoice that I could make my own. “You’ll never finish it,” chides the incomplete Magic Mirror beneath my desk. I shush it with a kick.

## Winging it

“I didn’t really spec this out when I started building. I knew I wanted a box, but didn’t know how I was going to approach it,” explains phrazelle, a maker after my own “meh, I’ll wing it” heart. He continues, “I started with a mechanical keyboard with some typewriter-esque keys and built out a board for it. This went in a few directions, and I wound up with a Frankenstein keyboard tray.”

Originally wanting a hole for each key, phrazelle used a paint relief method to mark the place of each one. However, this didn’t work out too well, so he decided to jigsaw out a general space for the keys in a group. After a few attempts and an application of Gorilla Glue, it was looking good.

## Building a Steampunk laptop

With his father’s help, phrazelle’s next step was to build the box for the body of the laptop. Again, it was something of an unplanned mashup, resulting in a box that was built around the keyboard tray. Via a series of mitred joints, routing, and some last minute trim, he was able to fit an LCD screen from a cannibalised laptop into the lid, complete with an LCD driver acquired from eBay.

## All of the Steampunk trimmings

“As I was going in the Steampunk direction, gears and gauges seemed to make sense,” says phrazelle. “I found a lot of cool stuff on Etsy and Amazon. The front battery gauge, back switch plate, and LED indicator housings came off Etsy.” He also discovered that actual watch gears, which he had purchased in bulk, were too flimsy for use as decoration, so he replaced them with some brass replicas from Amazon instead. Hand-blown marbles worked as LED defusers and the case was complete.

## Inside the belly of the (beautiful) beast

Within the laptop body, phrazelle (do let us know your actual name, by the way) included a Talentcell battery pack which he modified to cut the output lines, something that was causing grief when trying to charge the battery. He utilised a plugable USB 2.4 four-port powered hub to power the Raspberry Pi and optional USB devices. He also added a bushel of various other modifications, all of which he explains on his Instructables page.

I ran with the Pixel distro for this build. Then I went through and did some basic security housekeeping like changing the default password, closing every unnecessary port on the firewall, and disabling the Bluetooth. I even put the Bro IDS platform on it to keep an eye out for shifty hackers… *shakes fist*

This thing runs like a champ! For its intended functionality, it does everything it needs to. You can get on the internet, write papers, check email… If you want to get nerdy, you can even brush up on your coding skillz.

## Instructables and you

As I said, we love this build. Not only is it a great example of creating an all-in-one Raspberry Pi laptop, but it’s also gorgeous! Make sure to check out phrazelle’s other builds on Instructables, including his Zelda-themed bartop arcade and his ornate magic mirror.

While you’re there, check out the other Raspberry Pi-themed builds on Instructables. There are LOADS of them. And they’re great. And if you wrote any of them – ahem! – like I did, you should be proud of yourself – ahem! – like I am. *clears throat even more pointedly*

Have you built your own Pi laptop? Tell us about it in the comments below. We can’t wait to see it!

The post Steampunk laptop powered by Pi: OMG so fancy! appeared first on Raspberry Pi.

# Zelda-inspired ocarina-controlled home automation

Post Syndicated from Alex Bate original https://www.raspberrypi.org/blog/zelda-home-automation/

Allen Pan has wired up his home automation system to be controlled by memorable tunes from the classic Zelda franchise.

#### Zelda Ocarina Controlled Home Automation – Zelda: Ocarina of Time | Sufficiently Advanced

With Zelda: Breath of the Wild out on the Nintendo Switch, I made a home automation system based off the Zelda series using the ocarina from The Legend of Zelda: Ocarina of Time. Help Me Make More Awesome Stuff! https://www.patreon.com/sufficientlyadvanced Subscribe! http://goo.gl/xZvS5s Follow Sufficiently Advanced!

## Listen!

Released in 1998, The Legend of Zelda: Ocarina of Time is the best game ever is still an iconic entry in the retro gaming history books.

Very few games have stuck with me in the same way Ocarina has, and I think it’s fair to say that, with the continued success of the Zelda franchise, I’m not the only one who has a special place in their heart for Link, particularly in this musical outing.

Thanks to Cynosure Gaming‘s Ocarina of Time review for the image.

Allen, or Sufficiently Advanced, as his YouTube subscribers know him, has used a Raspberry Pi to detect and recognise key tunes from the game, with each tune being linked (geddit?) to a specific task. By playing Zelda’s Lullaby (E, G, D, E, G, D), for instance, Allen can lock or unlock the door to his house. Other tunes have different functions: Epona’s Song unlocks the car (for Ocarina noobs, Epona is Link’s horse sidekick throughout most of the game), and Minuet of Forest waters the plants.

## So how does it work?

It’s a fairly simple setup based around note recognition. When certain notes are played in a specific sequence, the Raspberry Pi detects the tune via a microphone within the Amazon Echo-inspired body of the build, and triggers the action related to the specific task. The small speaker you can see in the video plays a confirmation tune, again taken from the video game, to show that the task has been completed.

As for the tasks themselves, Allen has built a small controller for each action, whether it be a piece of wood that presses down on his car key, a servomotor that adjusts the ambient temperature, or a water pump to hydrate his plants. Each controller has its own small ESP8266 wireless connectivity module that links back to the wireless-enabled Raspberry Pi, cutting down on the need for a ton of wires about the home.

And yes, before anybody says it, we’re sure that Allen is aware that using tone recognition is not the safest means of locking and unlocking your home. This is just for fun.

## Do-it-yourself home automation

While we don’t necessarily expect everyone to brush up on their ocarina skills and build their own Zelda-inspired home automation system, the idea of using something other than voice or text commands to control home appliances is a fun one.

You could use facial recognition at the door to start the kettle boiling, or the detection of certain gasses to – ahem!– spray an air freshener.

We love to see what you all get up to with the Raspberry Pi. Have you built your own home automation system controlled by something other than your voice? Share it in the comments below.

The post Zelda-inspired ocarina-controlled home automation appeared first on Raspberry Pi.


text:
# 11.1.3 - Probability Distribution Plots

11.1.3 - Probability Distribution Plots

In previous lessons you have constructed probabilities distribution plots for normal distributions, binomial distributions, and $t$ distributions. This week you will use the same procedure to construct a probability distribution plot for the chi-square distribution.

## MinitabExpress – Constructing a Probability Distribution Plot

Chi-square tests of independence are always right-tailed tests. Let's find the area of a chi-square distribution with 1 degree of freedom to the right of $\chi^2 = 1.75$. In other words, we're looking up the $p$ value associated with a chi-square test statistic of 1.75.

1. On a PC: from the menu select STATISTICS > Distribution Plot
On a Mac: from the menu select Statistics > Probability Distributions > Distribution Plot
2. Select Display Probability
3. For Distribution select Chi-Square
4. For Degrees of freedom enter 1
5. Select A specified X value
6. Select Right tail
7. For X value enter 1.75

This should result in the following output:

Video Walkthrough

Select your operating system below to see a step-by-step guide for this example.

## Example: Area to the Right of Chi-Sq = 6.25, df=3

 [1] Link ↥ Has Tooltip/Popover Toggleable Visibility

format: plain


text:
# 2.6.6.5 imgMedian

Median

## Brief Information

Apply median filter to image

## Command Line Usage

1. imgMedian d:=10;

2. imgMedian d:=5 img:=mat(1) oimg:=mat(2);

## Variables

Display
Name
Variable
Name
I/O
and
Type
Default
Value
Description
Dimension d

Input

int

2

Specifies the dimensions of the neighborhood on which median filtering is applied. This value should not be less than 2.

Input Matrix img

Input

Image

<active>

Specifies the source image to be manipulated. The default input is the active image.

Output Image oimg

Output

Image

<input>

Specifies the output image. By default, the output image is the same as the input image.

See the syntax here.

## Description

This function applies median filtering to an image. Each pixel of the input image is replaced by the median of the pixels in its neighborhood.

Median filter is usually used for noise removal. It is especially suitable for removing salt and pepper noise and pulse noise.

It is more advantageous over average filter in that it tends to preserve more features, for example, true edges, in the input image.

## Examples

In this example, we use the imgMedian function to remove noise from the input image:

1. When the input image is active, select Image: Spatial Filters: Median to open the dialog of the X-Function.
2. In the dialog, change the settings as the screenshot below and click OK to close the dialog.

A new image is created. We can see some noise is removed.

The original image

The output image

## Algorithm

The computation uses L_MedianFilterBitmap() function from LEADTOOLS Main API. Please refer to the LEADTOOLS Main API Help file, Version 14 and read L_MedianFilterBitmap topic.

## References

LEADTOOLS Main API Help file, Version 14


text:
# Newlander-Niremberg theorem

Let $M$ be a smooth manifold of real dimension $m=2n$. Then every integrable almost complex structure $J$ on $M$ is defined by a unique analytic structure.

Title Newlander-Niremberg theorem NewlanderNirembergTheorem 2013-03-22 15:37:53 2013-03-22 15:37:53 Simone (5904) Simone (5904) 5 Simone (5904) Theorem msc 32Q60


text:
# Illustration Classically forbidden / allowed region

Harmonic potential energy function $$W_{\text{pot}}(x)$$ with sketched total energy $$W$$ of a particle. Classically the particle always has a positive kinetic energy:$$W_{\text{kin}} ~=~ (W_{\text{pot}} - W) > 0$$Here the particle can only move between the turning points $$x_1$$ and $$x_2$$, which are determined by the total energy $$W$$ (horizontal line). It is the classically allowed region (blue).
Negative kinetic energy is not physically possible:$$W_{\text{kin}} ~=~ (W_{\text{pot}} - W) < 0$$


text:
# Technical challenges to improving resolution of lunar orbit imaging by using solar UV light?

@Uwe's question and answer seem to illustrate that the resolution of surface-imaging spacecraft orbiting around the Moon has not dramatically improved over the decades, and that this is pretty-much limited by aperture size which in turn has pretty-much been limited by payload size/weight.

Question: What would be the technical challenges to improving spatial resolution by using the same aperture, but a substantially shorter wavelength instead?

For example, the Sun puts out a significant amount of UV. It's less intense than in the visible part of the spectrum, but it's still there.

Maybe I'm planning a landing a small craft with short legs, and I'd like to find and confirm an area with a low frequency of basketball-sized rocks in which to put my landing ellipse. If the resolution of current data is only 1 meter line pairs, that's not going to be good enough.

• There are other ways to increase resolution (lower orbit), and Uwe's answer only focused on the diffraction limit of the optics, ignoring the resolution limit of the sensor underneath. – Hobbes Sep 30 '18 at 14:37
• @Hobbes go for it, please! I just wanted to add something to one aspect, but certainly there are other aspects to cover here! – uhoh Sep 30 '18 at 14:40
• How about SAR imaging on moon ? – Prakhar Oct 3 '18 at 15:23
• @Prakhar that's a good point! Using a synthetic aperture allows for great resolution without a large spacecraft. e.g. How can ICEYE-X1 capture 2D high resolution SAR images in “tens of seconds”? With low lunar orbit SAR just might be able to do 30cm resolution – uhoh Oct 3 '18 at 15:34

At first sight it is a good idea to increase optical resolution by using shorter wavelengths. But sunlight is aproximized as black body radiation of 5900 K with the maximum intensity at about 560 nm. To increase resolution, the used wavelength should be much shorter. But at about 250 nm the solar intensity is much smaller, see this graph. Even without the Earth's atmospheric absorbtion of short wavelengths in lunar orbit.

But you need much light for a short exposure time and low noise images from the electronic image sensor. The camera of the lunar orbiter may be rotated for compensation of orbit velocity to the image. In order to get better images with more resolution, the compensation of camera movement should be better to allow longer exposures for more photons detected by the sensor.

But unfortunately solar intensity is more than 10 times smaller at 250 nm when compared to 560 nm. I think this could not be compensated by using longer exposure times only.

Sorry, I only found a graph with german text. Feel free to replace it with a graph with english description.

To add to @Uwe's answer, I found a source for the solar spectrum above the atmosphere (i.e. in space). It's in old-style .xls binary format, so I found a Python library to open it as I don't like to remember the Excel days.

A very broad band from 250nm to 350nm in the UV has about 1/7 the intensity of the 450 to 650nm band.

However, conventional CCDs and other imagers tend to give one photoelectron per photon, independent of photon energy 1 Watt of 300nm has half the number of photons as 1 Watt of 600nm. So even if the system had flat quantum efficiency (which it won't, even with backside-thinned CCDs) that ratio should really be 1/15.

Further factor in the precipitous drop in the Moon's albedo in the UV (the Moon is red, it is not at all white, see Why doesn't a full/gibbous moon high in the sky ever seem to look orange? Shouldn't it? for more details) so that ratio should really be 1/30.

While the idea could be workable, a factor of 30 loss in brightness would be tough to make up for with a factor of 30 longer exposure. At some point you'll need some pretty fancy camera-slewing or multiple image correlation and stacking with a toasty-hot image processing FPGA in order to keep the S/N comparable to the state-of-the-art in visible light.

above: "Figure 8: Averaged geometrical moon albedos measured by GOME from July 1995, November 1995, and September 1996." From ESA's GOME moon measurements, including instrument characterisation and moon albedo.

import numpy as np
import matplotlib.pyplot as plt

# https://www.nrel.gov/grid/solar-resource/spectra-astm-e490.html
# older https://www.nrel.gov/grid/solar-resource/spectra-wehrli.html
# FOUND: [Read Excel File in Python](https://stackoverflow.com/q/22169325/3904031)
# works for older .xls, which are binary and pre-2007 conversion to XML-like
# https://pypi.org/project/xlrd/
# https://libraries.io/pypi/xlrd
# HANDY!  http://www.python-excel.org/
# ALSO HANDY!  https://www.datacamp.com/community/tutorials/python-excel-tutorial

clight  = 2.99792458E+08   # m / s
hplanck = 6.626070040E-34  # J s
Coulomb = 6E+18

if False:   # do this once to read the Excel file, then save as .npy

from xlrd import open_workbook

wb     = open_workbook('e490_00a_amo.xls')
sheets = wb.sheets()
s0     = sheets[0]   # first sheet

nrows, ncols = s0.nrows, s0.ncols
print (nrows, ncols)

name_C0 = s0.cell(0,0).value   # u'Wavelength, microns'
name_C1 = s0.cell(0,1).value   # u'E-490 W/m2/micron'

lam = np.array([s0.cell(n,0).value for n in range(1, nrows)])
I   = np.array([s0.cell(n,1).value for n in range(1, nrows)])

np.save('lam', lam)
np.save('I',   I  )

else:  # then you can just read from disk next time

n0  = np.argmax(lam>0.15)
n1  = np.argmax(lam>0.75)

lam = lam[n0:n1+1]
I   = I[n0:n1+1]

dlam = lam[1:] - lam[:-1]
lam  = lam[:-1]
I    = I[:-1]

Ephot = hplanck * clight / (1E-06 * lam)

print lam.min(), lam.max()
print dlam.min(), dlam.max()

uv1  = (lam >= 0.25) * (lam <= 0.35)
uv2  = (lam >= 0.35) * (lam <= 0.45)
vis1 = (lam >= 0.45) * (lam <= 0.55)
vis2 = (lam >= 0.55) * (lam <= 0.65)

Iuv1  = I * uv1
Iuv2  = I * uv2
Ivis1 = I * vis1
Ivis2 = I * vis2

Iuv1_tot  = (Iuv1  * dlam).sum()
Iuv2_tot  = (Iuv2  * dlam).sum()
Ivis1_tot = (Ivis1 * dlam).sum()
Ivis2_tot = (Ivis2 * dlam).sum()

print "Iuv1_tot:  {} W/m^2".format(Iuv1_tot)
print "Iuv2_tot:  {} W/m^2".format(Iuv2_tot)
print "Ivis1_tot: {} W/m^2".format(Ivis1_tot)
print "Ivis2_tot: {} W/m^2".format(Ivis2_tot)

if True:
plt.figure()
plt.subplot(2, 1, 1)
plt.plot(lam, I,    '-k')
plt.plot(lam, Iuv1, '-m')
plt.plot(lam, Iuv2, '-b')
plt.plot(lam, Ivis1, '-g')
plt.plot(lam, Ivis2, '-y')
plt.text(0.32, 350,  '52', fontsize=14)
plt.text(0.405, 750, '139', fontsize=14)
plt.text(0.48, 1300, '193', fontsize=14)
plt.text(0.59, 1200, '176', fontsize=14)
plt.text(0.18, 1900, 'approx W/m^2', fontsize=14)
plt.xlabel('microns')
plt.ylabel('W/m^2/micron')

plt.subplot(2, 1, 2)
plt.plot(lam, I,    '-k')
plt.plot(lam, Iuv1, '-m')
plt.plot(lam, Iuv2, '-b')
plt.plot(lam, Ivis1, '-g')
plt.plot(lam, Ivis2, '-y')
plt.yscale('log')
plt.xlabel('microns')
plt.ylabel('W/m^2/micron')
plt.suptitle('e490_00a_amo.xls')
plt.show()

• For amateur photography on Earth, a sunny day gives you a massive excess of photons leading to shutter times of 1/2000 s, so an exposure 30 times longer doesn't seem so bad. (this leads to the question what sort of exposure times you need when photographing from orbit) – Hobbes Sep 30 '18 at 14:33
• @Hobbes For an improved resolution of 30cm at say 70 km, one would need to use a fairly long focal length. "10.5 µradians per pixel)" was mentioned in the question, this would have to be half that! Surface brightness of extended, resolved objects decreases as the square of the focal length, so better do the math first. – uhoh Sep 30 '18 at 14:37
• @Hobbes: Amateur photography on Earth uses typically a medium sensitivity film with medium resolution. But aerial photography uses a low speed high resolution film. Typical exposure (above Earth) about 1/250 at f/8. The exposure times for for Lunar Orbiter was 1/100, 1/50 or 1/25 second. An exposure 30 times longer seems so bad, 1/3 s to over one second. – Uwe Oct 1 '18 at 10:00

I try to estimate the usage of UV light to get more resolution of the NAC by using information about the wide angle camera WAC. The WAC has also two UV ranges.

There is some more information about the WAC of the Lunar Reconnaissance Orbiter here: (1), (2) and (3) (this is behind a paywall, I did not read it).

The wide angle camera image sensor was sensitive for 200 to 1000 nm. Using filters seven ranges could be detected, UV1 320 nm, width 32 nm, UV2 at 360nm with 15 nm width, 3 visible ranges and 2 ranges for near infrared.

The narrow angle camera NAC had no filters for detection of different wavelengths. But the method used for UV detection of the WAC shows what is necessary to get the increased sensitivity to compensate the low intensity of UV radiation within the solar black body radiation.

The resolution of the wide angle camera WAC was better in the visual range with 74.9 m/pixel or 1.498 mrad at a height of 50 km. For UV it was only 383.5 m/pixel = 7.67 mrad. The resolution was more than 4 times better in the visible range than for UV.

For UV 512 x 16 pixels of the sensor were used and binned to only 128 x 4. The mean value for a sub array of 4 by 4 = 16 pixels was computed by on-chip analog summing to get a better signal to noise ratio. SNR was 157 for 320 nm wavelength as well as 565 nm, but the area of 16 pixels had to be used to detect enough UV photons. It was possible to get the same noise level with the low intensity UV radiation by increasing the effective area of a pixel by factor of 16.

If we want to increase the resolution of the NAC by decreasing the wavelength by a factor of two, we need an image sensor with two times the pixel count in each direction. The area of a pixel is thus 4 times smaller and gets 4 times less photons. Due to the low intensity of the UV radiation we need about 16 times (information from the WAC) more light for the same SNR. So we need 4*16 = 64 times more light and 8 times the diameter of the telescope to get the necessary light. But this means an aperture of f/0.64 instead of f/5.1 for the 700 mm telescope of the NAC.

So it is much cheaper to stay at the same wavelength (also the same focal length) and increase the diameter of the telescope by a factor of 2. The image sensor should have 4 times more pixel to make use of the better resolution, but the total size of the sensor should be the same. The area of a single pixel is thus 4 times smaller. To get the same SNR, we need the same count of photons for the smaller pixel. But we already increased the diameter of the telescope by a factor of 2 and get thus 4 times the photons on the total area of the image sensor. Therefore pixel with 1/4 area get the same count of photons. The aperture of the NAC should be only f/2.75 instead of f/5.5.

• WAC uses a lens, Narrow angle NAC used a mirror. WAC wasn't used for high resolution imaging so I don't understand yet how this is helpful, can you explain a bit more? Thanks! – uhoh Oct 1 '18 at 16:39


text:
Nikolay Grozev

# Introduction

This article overviews how to quickly set up and get started with the pandas data analysis library. It also lists common code snippets for parsing, loading, and transforming data. For more detailed documentation on pandas’ more advanced features (e.g. plot styling and combining data frames) you’ll need to refer to other sources.

# Installing and Importing

First we need to install python and the pip package manager. If you don’t already have them, you can use pyenv to easily install them (tested on Ubuntu and OS X). On Ubuntu, you can follow these instructions to get pyenv. On OS X you can just use brew:

1
brew install pyenv

Once you have pyenv, you can install and configure the desired python version as follows:

1
2
3
4
# Install the desired python version - e.g. 3.4.3
pyenv install 3.4.3
# Set it up as a global version - pyenv will reconfigure your PATH accordingly
pyenv global 3.4.3

Now we can use pip to install pandas, the ipython shell, and jupyter.

1
pip install pandas ipython[all] jupyter

The last two libraries will allow us to create web base notebooks in which we can play with python and pandas. If you don’t know what jupyter notebooks are you can see this tutorial.

Next, we need to start jupyter. I find it useful to store all notebooks on a cloud storage or a folder under version control, so I can share between multiple machines. This can be achieved with an additional parameter as follows:

1
jupyter notebook --notebook-dir=~/Dropbox/notebooks

Next, we need to import pandas in the first cell of the jupyter notebook.:

1
import pandas

When we have a long notebook, it is useful to have an automatically generated table of contents (TOC). The following code (Borrowed from this post on StackOverflow) installs the TOC jupyter plugin, i.e.:

1
2
3
4
5
6
7
8
9
10
mkdir toc
cd toc
wget https://raw.githubusercontent.com/minrk/ipython_extensions/master/nbextensions/toc.js
wget https://raw.githubusercontent.com/minrk/ipython_extensions/master/nbextensions/toc.css

## install and enable
cd ..
jupyter-nbextension install --user toc
jupyter-nbextension enable toc/toc

Then we need to restart the kernel and make the first cell “Markdown” type and add the following:

1
2

When you save the TOC should appear.

# Creating Data Frames

Data frames are the central concept in pandas. In essence, a data frame is table with labeled rows and columns. Data frames can be created from multiple sources - e.g. CSV files, excel files, and JSON.

Loading a CSV file as a data frame is pretty easy:

1
data_frame = pandas.read_csv('file.csv', sep=';')

Sometimes the CSV file contains padding spaces in front of the values. To ignore them use the skipinitialspaces parameter:

1

If the padding white spaces occur on both sides of the cell values we need to use a regular expression separator. In this case, we need to use the ‘python’ processing engine, instead of the underlying native one, in order to avoid warnings. This will degrade the performance a bit:

1
pandas.read_csv('file.csv', sep='\s*;\s*', skipinitialspace=True, engine='python')

Sometimes we need to sample the data before loading it, as it is too big to fit in memory. This can be achieved following this approach.

## Hardcoded Dataframes

Hardcoded data frames can be constructed by providing a hash of columns and their values.

1
2
3
4
5
6
7
import numpy as np

df = pandas.DataFrame({
'col1': ['Item0', 'Item0', 'Item1', 'Item1'],
'col2': ['Gold', 'Bronze', 'Gold', 'Silver'],
'col3': [1, 2, np.nan, 4]
})

We will reuse this data frame in some subsequent examples.

# Previewing Data

To preview the data and the metadata of a dataframe you can use the following functions:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# Displays the top 5 rows. Accepts an optional int parameter - num. of rows to show

# Similar to head, but displays the last rows
df.tail()

# The dimensions of the dataframe as a (rows, cols) tuple
df.shape

# The number of columns. Equal to df.shape[0]
len(df)

# An array of the column names
df.columns

# Columns and their types
df.dtypes

# Converts the frame to a two-dimensional table
df.values

# Displays descriptive stats for all columns
df.describe()

# Sorting

The sort_index method is used to sort the frame by one of its axis indices. The axis is either 0 or 1 - row/column axis respectively:

1
2
# Sort rows descendingly by the index
df.sort_index(axis=0, ascending=False)

We can also sort by one or multiple columns:

1
df.sort_values(by=['col2', 'col1'], ascending=False)

# Selecting/Querying

Individual columns can be selected with the [] operator or directly as attributes:

1
2
3
4
5
6
7
8
# Selects only the column named 'col1';
df.col1

# Same as previous
df['col1']

# Select two columns
df[['col1', 'col2']]

You can also select by absolute coordinates/position in the frame. Indices are zero based:

1
2
3
4
5
6
7
8
# Selects second row
df.iloc[1]
# Selects rows 1-to-3
df.iloc[1:3]
# First row, first column
df.iloc[0,0]
# First 4 rows and first 2 columns
df.iloc[0:4, 0:2]

Most often, we need to select by a condition on the cell values. To do so, we provide a boolean array denoting which rows will be selected. The trick is that pandas predefines many boolean operators for its data frames and series. For example the following expression produces a boolean array:

1
2
# Produces and array, not a single value!
df.col3 > 0

This allows us to write queries like these:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
# Query by a single column value
df[df.col3 > 0]

# Query by a single column, if it is in a list of predefined values
df[df['col2'].isin(['Gold', 'Silver'])]

# A conjunction query using two columns
df[(df['col3'] > 0) & (df['col2'] == 'Silver')]

# A disjunction query using two columns
df[(df['col3'] > 0) | (df['col2'] == 'Silver')]

# A query checking the textual content of the cells
df[df.col2.str.contains('ilver')]

# Modifying Data Frames

Pandas’ operations tend to produce new data frames instead of modifying the provided ones. Many operations have the optional boolean inplace parameter which we can use to force pandas to apply the changes to subject data frame.

It is also possible to directly assign manipulate the values in cells, columns, and selections as follows:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# Modifies the cell identified by its row index and column name
df.at[1, 'col2'] = 'Bronze and Gold'

# Modifies the cell identified by its absolute row and column indices
df.iat[1,1] = 'Bronze again'

# Replaces the column with the array. It could be a numpy array or a simple list.
#Could also be used to create new columns
df.loc[:,'col3'] = ['Unknown'] * len(df)

# Equivalent to the previous
df.col3 = ['Unknown'] * len(df)

# Removes all rows with any missing values.
df.dropna(how='any')

# Removes all rows with all missing values.
df.dropna(how='all')

It is often useful to create new columns based on existing ones by using a function. The new columns are often called Derived Characteristics:

1
2
3
4
5
6
7
8
9
10
11
def f(x):
return x + ' New Column';

# Uses the unary function f to create a new column based on an existing one
df.col4 = f(df.col3)

def g(x, y):
return x + '_' + y

# Uses the 2-arg function g to create a new column based on 2 existing columns
df.col4 = g(df.col3, df.col2)

# Dates and Time

When loading data from a CSV, we can tell pandas to look for and parse dates. The parse_dates parameters can be used for that. In the most typical case, you would pass a list of column names as parse_dates:

1
dates_df = pandas.read_csv('test.csv', sep=';', parse_dates=['col1', 'col2'])

This will work for most typical date formats. If it does not (i.e. we have a non-standard date format) we need to supply our own date parser:

1
2
3
4
5
def custom_parser(s):
# Specify the non-standard format you need
return pandas.datetime.strptime(s, '%d%b%Y')

dates_df = pandas.read_csv('test.csv', sep=';', parse_dates=['col1'], date_parser=custom_parser)

Alternatively, if we’ve already loaded the data frame we can change a column from string to a date:

1
dates_df['col2'] = pandas.to_datetime(dates_df['col2'], format='%d.%m.%Y')

For more on date-time formats look at the documentation.

Often we need to work with Unix/Posix timestamps. Converting numeric timestamps to pandas timestamps is easy with the unit parameter:

1
2
# Unit specifies if the time is in seconds('s'), millis ('ms'), nanos('ns') etc.
dates_df['col'] = pandas.to_datetime(dates_df['col'], unit='ms')

If we need to parse Posix timestamps while reading CSVs, we can once again resort to converter functions. In the converter function we can use the pandas.to_datetime utility which accepts a unit parameter:

1
2
3
4
5
def timestamp_parser(n):
# Specify the unit you need
return pandas.to_datetime(float(n), unit='ms')

dates_df = pandas.read_csv('test.csv', sep=';', parse_dates=['col1'], date_parser=timestamp_parser)

We can also convert time/timestamp data to Unix epoch numbers:

1
2
# Creates a new numeric column with the timestamp epoch in nanos
dates_df.col4 = pandas.to_numeric(dates_df.col3)

# Plotting

## Set Up

Pandas uses matplotlib to render graphs, so you need to install it:

1
pip install matplotlib

Before we continue we need to test if matplotlib was set up properly. Open a terminal, start the python interpreter, and type:

1
import matplotlib

If the import works without problems you’re good to go. However, sometimes in OS X you may get the following error:

“RuntimeError: Python is not installed as a framework. The Mac OS X backend will not be able to function correctly if Python is not installed as a framework. See the Python documentation for more information on installing Python as a framework on Mac OS X. Please either reinstall Python as a framework, or try one of the other backends. If you are Working with Matplotlib in a virtual enviroment, see ‘Working with Matplotlib in Virtual environments’ in the Matplotlib FAQ”

If that error occurs, you need to execute the following from terminal:

1
echo "backend: TkAgg" >> ~/.matplotlib/matplotlibrc

This will set the proper matplotlib backend, as discussed here.

Now we can import the matplot library in one of the jupyter notebook cells:

1
import matplotlib.pyplot as plt

There is one last configuration to complete before we can display plots in the web notebook. We need to tell jupyter to display the matplotlib plots as images in the notebook itself. To do so, type the following command in one of the notbook cells:

1
2
# Will allow us to embed images in the notebook
%matplotlib inline

## Basic Plotting

In the rest of this section we’ll use the following data frame:

1
2
3
4
5
plot_df = pandas.DataFrame({
'col1': [1, 3, 2, 4],
'col2': [3, 6, 5, 1],
'col3': [4, 7, 6, 2],
})

Data frames have a method called plot. By default, it plots a line chart with al numerical columns. The x-axis is the row index of the data frame. In other words, you’re plotting :

1
plot_df.plot()

We can also specify a column for the x-axis:

1
plot_df.plot(x='col1')

The plot has an optional parameter kind which can be used to plot the data in different type of visualisation - e.g. bar harts, pie chart, or histograms.

Using kind=’bar’ produces multiple plots - one for each row. In each plot, there’s a bar for each cell.

1
2
# Use kind='hbar' for horizontal bars, and stacked=True to stack the groups
plot_df.plot(kind='bar')

Boxplots are displayed with the kind=’box’ options. Each box represents a numeric column.

1
plot_df.plot(kind='box')


text:
# Article

Full entry | PDF   (0.4 MB)
Keywords:
element order; prime graph; Suzuki group
Summary:
One of the important questions that remains after the classification of the finite simple groups is how to recognize a simple group via specific properties. For example, authors have been able to use graphs associated to element orders and to number of elements with specific orders to determine simple groups up to isomorphism. In this paper, we prove that Suzuki groups $Sz(q)$, where $q\pm \sqrt{2q}+1$ is a prime number can be uniquely determined by the order of group and the number of elements with the same order.
References:
[1] Chen, G.Y.: About Frobenius groups and $2$-Frobenius groups. J. Southwest China Normal Univ. 20 (5) (1995), 485–487.
[2] Ebrahimzadeh, B., Iranmanesh, A., Parvizi Mosaed, H.: A new characterization of Ree group $^2G_2 (q)$ by the order of group and number of elements with same order. Int. J. Group Theory 6 (4) (2017), 1–6. MR 3695074
[3] Frobenius, G.: Verallgemeinerung des Sylowschen Satze. Berliner Sitz (1895), 981–983.
[4] Gorenstein, D.: Finite Groups. Harper and Row, New York, 1980. MR 0569209 | Zbl 0463.20012
[5] Khalili Asboei, A., Amiri, S.S., Iranmanesh, A., Tehranian, A.: A new characterization of sporadic simple groups by NSE and order. J. Algebra Appl. 12 (2) (2013), 1250158. DOI 10.1142/S0219498812501587 | MR 3005607
[6] Khalili Asboei, A., Iranmanesh, A.: Characterization of the linear groups $L_2(p)$. Czechoslovak Math. J. 64 (139) (2014), no. 459–464. MR 3277747
[7] Parvizi Mosaed, H., Iranmanesh, A., Tehranian, A.: Characterization of suzuki group by nse and order of group. Bull. Korean Math. Soc. 53 (3) (2016), 651–656. DOI 10.4134/BKMS.b140564 | MR 3508660
[8] Shao, C.G., Shi, W., Jiang, Q.H.: Characterization of simple $K_4$-groups. Front Math. China 3 (3) (2008), 355–370. DOI 10.1007/s11464-008-0025-x | MR 2425160 | Zbl 1165.20020
[9] Suzuki, M.: On a class of doubly transitive groups. Ann. of Math. 2 (75) (1962), 105–145. DOI 10.2307/1970423 | MR 0136646
[10] Wiliams, J.S.: Prime graph components of finite groups. J. Algebra 69 (2) (1981), 487–512. DOI 10.1016/0021-8693(81)90218-0 | MR 0617092

Partner of


text:
# A 2-D Calibration Scheme for Resistive Nonvolatile Memories

Albert Lee, Raahul Jagannathan, Di Wu, Kang L. Wang

Research output: Contribution to journalArticlepeer-review

## Abstract

Resistive nonvolatile memories (NVMs) promise significant performance improvement over existing NVM candidates. However, fabrication nonidealities and parasitics on the access path cause cell location-dependent variations in the total resistance received at the read circuitry. Write characteristics delivered to each cell, as well as the optimal write conditions for each cell, are also location-dependent. In this article, we propose a 2-D calibration scheme to address these variations. The proposed scheme joins row and column calibrations to create a correction grid at each crosspoint on the array and effectively cancels many spatial patterns. The enabling circuit and algorithmic modifications are described. We assess the 2-D calibration scheme in a 28-nm $256\times 256$ memory array, and show reduction in variability across multiple gradient patterns compared to conventional calibration methods. For the same calibration granularity, 2-D calibration achieves between 41% and 99% improvement depending on the amount of calibration bits. For the same amount of total calibration bits, the 2-D calibration scheme reduces the variability between 39% and 99%.

Original language English 9032316 1371-1377 7 IEEE Transactions on Very Large Scale Integration (VLSI) Systems 28 6 https://doi.org/10.1109/TVLSI.2020.2975589 Published - 2020 Jun

## All Science Journal Classification (ASJC) codes

• Software
• Hardware and Architecture
• Electrical and Electronic Engineering

## Fingerprint

Dive into the research topics of 'A 2-D Calibration Scheme for Resistive Nonvolatile Memories'. Together they form a unique fingerprint.


text:
# Reaction of water and methane

Methane is a non-polar compound, i.e. it shows no bipolar movement but even after that it reacts with water which is a polar compound and polar and non-polar compounds do not react. Why does this reaction take place, then:

Q: The reaction of methane and water is a way to prepare hydrogen according to

$$\ce{CH4 (g) + H2O -> CO2 (g) + H2 (g)}$$

...

Polar and non-polar liquids do not mix, but that doesn't tell you anything about their ability to react, which depends on the thermodynamics and kinetics of the reaction. The reaction shown is in the gaseous state.

The reaction of methane gas with gaseous water, which you show, is a common reaction called Methane reformation. Methane gas is heated with steam (gaseous water) to produce hydrogen (and $\ce{CO2}$).

As shown in that link, the reaction takes place in two steps: \begin{align}\ce{CH4_{(g)} + H2O_{(g)} &-> CO_{(g)} + H2_{(g)}} &&\text{(Endothermic)}\\ \ce{CO_{(g)} + H2O_{(g)} &-> CO2_{(g)} + H2_{(g)}} && \text{(Exothermic)}\end{align}

It appears it probably requires some heating to get this reaction to proceed (the first step is endothermic), I'll edit when I have a chance to look up the thermodynamic properties and see if we can glean what drives the reaction, or if it requires catalysis to avoid the energy barrier.

Side-note: by "bipolar movement" I think you mean "dipole moment"

Edit: According to this source, the first step of the reaction happens at ~3–20 atmospheres of pressure. The second step uses a catalyst to make the reaction more energetically favorable.

The thermodynamic variables for the individual species (at $25~\mathrm{^\circ C}$) in the net reaction are:

$$\begin{array}{c|cc} & \Delta S^\circ \left( \frac{\mathrm{kJ}}{\mathrm{K\cdot mol}} \right) & \Delta H_\mathrm{f}^\circ \left( \frac{\mathrm{kJ}}{\mathrm{mol}} \right) \\ \hline \ce{CH4_{(g)}} & 0.1862 & -74.81 \\ \ce{H2O_{(g)}} & 0.1887 & -241.8 \\ \ce{CO2_{(g)}} & 0.2136 & -393.5 \\ \ce{H2_{(g)}} & 0.1306 & 0 \\ \end{array}$$

The balanced net reaction is:

$$\ce{CH4_{(g)} + 2 H2O_{(g)} -> CO2_{(g)} + 4 H2_{(g)}}$$

Therefore:

$$\begin{array}{l|ccc} & \Delta S^\circ \left( \frac{\mathrm{kJ}}{\mathrm{K\cdot mol}} \right) & \Delta H^\circ \left( \frac{\mathrm{kJ}}{\mathrm{mol}} \right) \\ \hline \text{Reactants} & 0.5636 & -558.41 \\ \text{Products} & 0.7576 & -393.5 \\ \hline \text{Net Reaction} & 0.2136 & 164.9 \\ \end{array}$$

Right away, it's apparent that the reaction is entropically favorable ($S_{\text{rxn}} > 0$), but enthalpically unfavorable ($H_{\text{rxn}} > 0$) at room temperature. To find out if the reaction is spontaneous, consider:

$$\Delta G = \Delta H -T\Delta S$$

The reaction is spontaneous when $\Delta G < 0$. Because $\Delta S$ is so close to $0$ ($0.194~\mathrm{kJ/(K\,mol)}$), and $\Delta H$ is so high ($164.91~\mathrm{kJ/mol}$), we should expect already that this reaction is non-spontaneous at room temperature. This is consistent with the fact that methane doesn't readily decompose in moist air, as any cow pasture will tell you. But we can check:

$$\Delta G = 164.91\ \frac{\mathrm{kJ}}{\mathrm{mol}}-298.15~\mathrm{K}\cdot0.194~\frac{\mathrm{kJ}}{\mathrm{K\cdot mol}}=107.07\ \frac{\mathrm{kJ}}{\mathrm{mol}}$$

Quite non-spontaneous. However, since the overall reaction is entropically favorable, we can use $\Delta S$ to overpower the $\Delta H$, by jacking up $T$. Since the industrial reaction takes place between $700$ and $1000~\mathrm{^\circ C}$, let's plug in $700~\mathrm{^\circ C}\ (973.15~\mathrm{K})$ and check that the reaction is indeed spontaneous:

$$\Delta G = 164.91\ \frac{\mathrm{kJ}}{\mathrm{mol}}-973.15~\mathrm{K}\cdot0.194~\frac{\mathrm{kJ}}{\mathrm{K\cdot mol}}=-23.85 \frac{\mathrm{kJ}}{\mathrm{mol}}$$

Voilà! A spontaneous reaction!

Do note, however, that this calculation:

1. ignores any temperature-dependence of the thermodynamic variables;
2. ignores the role of pressure.

Tldr: This reaction is not energetically favorable at room temperature. However, the reaction is entropically favorable. If you heat it up enough (i.e. $\gtrapprox 700~\mathrm{^\circ C}$), the reaction will proceed spontaneously.

Source for thermodynamic values: Oxtoby, Principles of Modern Chemistry Seventh Edition

• Heating is probably a good idea; the first reaction is usually done at temperatures $700$$-$$1100 \ ^\circ \mathrm{C}$ while the other one at $360$. If temperatures are lower (around $250$) possibly with catalysts (copper and zinc oxides, aluminum) one might expect competing reactions: $$\ce{CO + 2H2 -> CH3OH,\\ CO2 + 3H2 -> CH3OH + H2O}.$$ It would be interesting to see the pressures involved. – Linear Christmas Dec 24 '16 at 17:43
• I edited my answer with an update about the pressures required. (3-20atm) – NMJD Dec 24 '16 at 20:36
• For the record, the carbon monoxide-water mixture is know as syngas. – Zhe Dec 24 '16 at 20:47


text:
# ARIMAX with a specified nonlinear model using the arima function in R

I am interested in fitting an ARIMAX model using R. As known, ARIMAX can be understood as a composition of ARIMA models and regression models with exogenous (independent) variables. I have a time series $Y_i$, and want to estimate the ARIMA and nonlinear coefficients. The nonlinear model is the following:

$y_i=β_0+β_1t_i+β_2d+β_3 sin(2πt_i/β_4 )+β_5 (-1^{t_i})+ε_i$, nonlinear regression with an exogenous variable. Where $t_i$ =1, 2…, 60 and

d = dummy variable with 20 0's and 40 number 1's

d=c(rep(0,20),rep(1,40))

And an ARIMA model (1,1,1) for $Y_i$. Therefore, I want to estimate simultaneously the $β_i$ and the ARIMA coefficients in order to avoid the confusion between the exogenous coefficients and ARIMA coefficients. I know that $arima()$ can deal with this formulation but, how do the nonlinear model can be set within function function?. It seems that the xreg term only deals with linear parameters.

• As parameterized, your model isn't identifiable (choose some value for $\beta_3/\beta_4$, and then note that doubling both $\beta_3$ and $\beta_4$ leaves that ratio unchanged) - as the model stands, you can only estimate $\beta_3/\beta_4$. You have to fix that problem with your model before even considering trying to estimate it. – Glen_b Oct 15 '14 at 0:37

Do the parameters $\beta_3$ and $\beta_4$ have any particular interpretation or meaning in the context of your model? You can consider reparameterizing the model merging $\beta_3 t_i /\beta_4$ as $\theta\,t_i$. In this way the model becomes linear in the parameters and you can pass the regressors $t_i$ and $d_t$ through argument xreg in function arima.
You should include $t_i$ only once in the reparameterized model. In your model, the regressor $t_i$ is proportional to the regressor $2\pi t_i$. With this type of collinearity among the regressors the optimization algorithm won't be able to invert the system matrix.
The function stats::arima does not allow you to specify this non-linear parameterization. You should modify the function arima, which is not straightforward since would require among other things recompiling the package. You can also try to create your own function, the functions that you would need are essentially: makeARIMA, KalmanLike and nlm, but this is also quite a hard work. You may ask for further guidance at Stack Overflow.
• Thanks for your comments @Glen_b and javlacalle . I have edited my post and the model has varied a little. With the new model, $beta_3$ and $beta_4$ have a particular interpretation, period and amplitude of a sinus wave. Is there any way to estimate the ARMA parameters and this model parameters in only a single stage? (not estimating first the NLM and then the ARMA). – Hector Oct 15 '14 at 8:47