What are patterns?
A pattern is a mental structure showing how to do something, or how something works. Patterns are usually called schemas or schemata in the psychology literature. Calling them patterns gives you more street cred.
Experts’ brains have more patterns than novices’ brains. It’s one of the things that makes them experts. They can also sort through their patterns more quickly, and find the ones that match the situation. Experts’ patterns reflect the underlying structure of the task, while novice patterns are more likely to reflect surface details.
Here’s a pattern from a programming Cycourse:
The pattern has a “condition/action” structure:
Condition: You want to work with files.
Action: Use the sequence: open the file, do something with it, close the file.
The open/close pattern is useless by itself. It becomes useful when it’s combined with other patterns, and applied to a particular task.
Let’s look at some other patterns, to see how they differ.
Here’s a pattern:
Compare it to the pattern we saw earlier:
The Read/process/output pattern is more abstract. It applies across more situations. However, translating it into code takes more work.
Patterns for artifacts vs. patterns for problem solving
The patterns we’ve seen so far are patterns for programs, that is, artifacts that students create.
Here’s another pattern:
The HTML-then-PHP pattern doesn’t describe programs. It’s a pattern for the task of writing programs. The open/close and read/process/output patterns model what a computer does. The HTML-then-PHP pattern models what humans do to write programs. It’s a “problem-solving pattern.”
Here’s one more:
This problem-solving pattern applies not just to programming, but to many other domains. It’s a very abstract problem-solving pattern.
Showing students how to use patterns
You can’t just show a pattern to students and expect them to understand how to use it. Some students will figure it out by themselves, but others won’t. Best to be explicit.
Here are examples from the same programming Cycourse, showing students how to use the patterns.
This shows how to translate the pattern to PHP, the programming language used in that particular Cycourse. Of course, mapping from pattern to code in one step is only possible for the simplest, most concrete patterns.
Check this out:
At the top, there are two general patterns. The line “Do something with it” in the first pattern is replaced by the second pattern. The third pattern shows the result. Pattern embedding is common in programming, mathematics, and other fields.
Pattern embedding is an application of the decomposition pattern we saw before:
Pattern embedding is one way to do decomposition.
The pattern is made slightly more specific to the task to be done.
Now combining embedding, specificity, and finally code translation:
One more example:
This shows students how the pattern is instantiated for a particular task.
Demos are one way to show students how to use patterns. The demos should be by pseudents. It’s OK to make pseudents struggle. Struggle is normal. It’s how people learn. (Thanks to Doug Holton for the reminder.)
Deep learning and patterns
Patterns are fundamental to the way human brains work. People are always looking for patterns. They infer patterns from what they observe, even when their inferences don’t make sense. That’s a good source for superstitions.
We can make deep learning easier for students by making patterns explicit. This helps them:
- Take advantage of what other people have learned. Patterns are patterns because people find them useful.
- Avoid inferring incorrect patterns, like “Before compiling Java code, turn around three times, while asking Baal for his blessing.” (Actually, that one works.)
Further, we can show them how to use the patterns that we show them. Like this example from earlier:
We can show them how to use patterns for artifacts (like programs), for design practices, and other things.
Patterns and transfer
Transfer is when students use what they learned in one context, and apply it in another. This is what we want students to be able to do when they finish a course. For example, take what they learned about linear equations in a math course, and use it a finance course.
Students don’t automatically transfer skills and concepts from one course to the next. Why? Remember Joann’s fun math experience. Here’s her brain after the course:
The dots are concepts and the squares are cues (inputs, like someone saying “a racist hotdog”). MATH 101 concepts are isolated, because the course was taught as math qua math, not math-as-a-tool-to-do-things. Most courses are in silos like this. (Metaphorical silos. You know what I mean.)
The semester after MATH 101, Joann takes FINC 201, Intro to Business Finance. Here’s Joann’s brain partway through the semester:
The MATH 101 stuff is fading, because it isn’t being triggered. The FINC 201 stuff is in its own brain space, because the course is taught in a silo, too. It only has limited connections to other concepts.
One day, the professor begins,
“G’day, humans! Ow are ya? Roight, let’s talk about capital growth. We’ll start with a linear equation. Can someone write the standard formula on the board? Anyone? Anyone?”
Joann might have the information in her brain, up in MATH 101 country, aka, the outback of Joann’s brain. However, she might not know she knows, because activation won’t spread from her FINC 201 professor’s cue to Joann’s outback.
After a pause for disappointment, her professor continues.
“Struth, ya bloody drongos! Remember MATH 101? Remember this?”
The professor draws this on the blackboard:
Now Joann has two cues: the context (MATH 101) and the picture. Aha! She remembers!
Students sometimes have trouble transferring within a course. Joann might be reading chapter 8 of her FINC 201 textbook, and come across a concept that she doesn’t recognize, even though it was covered in chapter 2.
Remember, all of this is normal, given how brains work, and how MATH 101 and FINC 201 are taught. These problems are to be expected.
Cycourses can improve transfer, by being explicit about it. For example, a Cycourse could show the pseudent (a pseudo-student) Jeremy working on a task, and transferring a pattern from one context to another.
Some patterns transfer more easily than others, because they are more abstract, and apply to more situations. Here’s one of the patterns from before:
It applies to a narrow set of circumstances. Unlike this one:
This applies to pretty much every programming task.
There’s another level to patterns, called Big Ideas. That’s next.
Patterns are ways of doing things that people find useful. Some patterns are small and detailed, others are more abstract and general. All of your species thinks with patterns.
Cycourses can show students what patterns are, and how to use them. This is particularly useful for transfer.