Archive for the ‘Tools’ Category

The following is the word problem in page 5 of Dr. Yeap Ban Har’s book “Bar Modeling-A problem-solving tool” (Thanks Dr. Yeap for allowing me to reference the examples in the book).

Jake is 3 years older than Kyla and 2 years younger than Larry. The total of their ages is 41 years. Find Jake’s age.

Now let’s draw a bar model by writing script with BarModelMaker. First add a bar for each of the 3 persons.

 add bar title="Jake's age"
 add bar title="Kyla's age"
 add bar title="Larry's age"

Now add a box to each of the 3 bars to represent their ages. (We add a label above the box of the first bar with the question mark “?” as the title)
add box with label title=? position=above to bar[1]

 add box to bar[2]
 add box to bar[3]

Add a box to the second bar to represent the 3 years that Jake is older than Kyla. Add a label above the box with the title of “3”.

 add box size=3 stroke-style=dashed to bar[2] with label title=3 position=above

Add a constraint statement specifying that Jake is 3 years older than Kyla.

 box[1] = box[2,1] + 3

Add a box to the third bar to represent the 2 years that Jake is younger than Larray. Add a label above the box with the title of “2”.

 add box size=2 to bar[3] with label title=2 position=above

Add a constraint statement specifying that Jake is 2 years younger than Larry.

 box[1] = box[3] - 2

Add a constraint statement specifying that their total age is 41. Note that Kyla’s age is represented by box[2,1]

 box[1] + box[2,1] + box[3] = 41

Finally add a label to the 3 bars.

 add label title=41 to bar[1 to 3]

We’ve drawn a bar model with 12 statements!


In this example, we’ve used only 4 types of statements:

  • Add bar
  • Add box
  • Add label, and
  • Constraint statement

Here is the script of the bar model:

 add bar title="Jake's age"
 add bar title="Kyla's age"
 add bar title="Larry's age"
 add box with label title=? position=above to bar[1]
 add box to bar[2]
 add box size=3 stroke-style=dashed to bar[2] with label title=3 position=above
 add box to bar[3]
 box[1] = box[2,1] + 3
 add box size=2 to bar[3] with label title=2 position=above
 box[1] = box[3] - 2
 box[1] + box[2, 1] + box[3] = 41
 add label title=41 to bar[1 to 3]

Read Full Post »

BarModelMaker on cnet.com

I’ve uploaded BarModelMaker to cnet.com. It is free.

Please feel free to let me know your comments and suggestions.



Read Full Post »

Here is a word problem:

Adam and Rahmad shared some beads. If Adam gave 1/3 of his share to Rahmad, Rahmad would have 70 more than Adam. If Adam gave 1/5 of his share to Rahmad, Rahmad would have 10 more than Adam. How many beads does Adam have at first?

The following is the bar model drawn with BarModelMaker. Please click on the model to see an animation showing how the model was draw.


From the model, we can see that we can divide Adam’s beads into 15 units. In the first scenario, Adam gives 5 units to Rahmad; and in the second scenario, Adam gives 3 units to Rahmad. So in the second scenario the difference between Rahmad and Adam is 4 units less than the difference between them in the first scenario. The 4 units causes the difference between Rahmad and Adam to be reduced from 70 to 10. And therefore 4 units represent 60 beads, and 1 unit represents 15 beads. So Adam has 15*15=225 beads.

Here is the BarModel script for this model:

add bar title=Adam1
add bar title=Rahmad1
add box size=a to bar[1]
add box size=r to bar[2]
cut box[1] into 3
shift box[1, 3] to bar[2]
update box[2,2] fill=green
box[1, 1 to 2] + 70 = box[2, 1 to 2]
add bar title=Adam2
add bar title=Rahmad2
add box size=a to bar[3]
add box size=r to bar[4]
cut box[3] into 5
shift box[3, 5] to bar[4]
update box[4,2] fill=cyan
box[3, 1 to 4] + 10 = box[4, 1 to 2]
cut box[1, 1 to 3] into 5
cut box [2, 2] into 5
cut box[3, 1 to 5] into 3
cut box[4, 2] into 3
add label title=70 position=above size=70 alignment=right to box[2,6]
add label title=10 position=above size=10 alignment=right to box[4,4]

Read Full Post »

I’ve just finished the 1st draft of BarModelMaker User Manual.

Read Full Post »

I’ve captured a video of the BarModel Player for the following word problem:

Ryan had $200 more than Danish at first. Ryan gave ¾ of his money to Danish. Danish in return gave 2/3 of his money to Ryan. In the end, Ryan had $180 more than Danish. Find the amount of money Danish had in the end.

You can see how the bar model is created step by step, and boxes moving from one bar to another bar in action.

Read Full Post »

Bar Model Maker

I am developing a Windows desktop application, called Bar Model Maker, that allows you to draw Bar Models by writing Bar Model Script. The tool displays the bar model as you are writing the script. Once you’ve specified enough constraints, you will get the accurate bar model.

The user interface will be something as the following screen shot. Beginners can create a bar model by using the dialog boxes on the right. Advanced users can write script directly in the script editor.

Bar Model Maker


Read Full Post »

Bar modeling, also known as Singapore Math Method, is a method that helps students to visualize and understand word problems in Math. However, drawing an effective bar model is challenging, teaching a student to draw bar models is even more so. In most cases, students just see the final models without the explanation about how the models were drawn step by step.

Drawing a model of a complex word problem on paper can be messy and tedious: oftentimes, you have to worry about the size of each box; you have to redraw a bar because the sizes of the boxes are too inaccurate; you have to cut 7 boxes into 3 parts each. After some time, you may forget how a model was drawn.

Isn’t it great if there is a tool that allow a student to specify what to draw rather than draw it manually? The student tells the tool to add a bar, add a box with an unknown size, add another box with a known size, specify the relations between bars or boxes, cut a box into some smaller boxes, shift two boxes from this bar to another bar. And the tool draws the model automatically for you as you are adding your instructions. And you can “replay” the model step by step.

That is why I designed the Bar Model Language-a domain specific language-that allows you to do exactly what I just described. You describe a bar model by writing code, which not only specifies the model, but also serves as the explanation of each step. The code can be saved and “played” later, or translated into an SVG document, which can be put in a Web page, or pasted into a Word document.

Let’s look at an example. Here is a word problem.

Ryan had $200 more than Danish at first. Ryan gave ¾ of his money to Danish. Danish in return gave 2/3 of his money to Ryan. In the end, Ryan had $180 more than Danish. Find the amount of money Danish had in the end.

Here is the final model. You can click on the SVG document and play the model step by step.

Bar Model

From the last two bars we can easily see that

10u = 50 + 180 – 150 = 80

And therefore

u = 8

So Danish had 7u+50 = 7 x 8 + 50 = 106 in the end.

The following is the code of this bar model:

add bar title='R1' as r1
add bar title='D1' as d1
add box to r1
add box to d1
r1 - d1 = 200
cut box[1] from right size=200
add label title="200" position=above to r1[2]
cut each of r1[1 to 2] into 4
add label title="50" position=below to r1[5]
cut d1 into 4
add bar title='R2' as r2
add bar title='D2' as d2
shift r1[1] to r2
shift r1[5] to r2
add label title="50" position=above to r2[2]
shift d1[1 to 4] to d2
shift r1[2 to 4] to d2
shift r1[6 to 8] to d2
cut each of d2[1 to 7] into 3
add label title="21u" position=above to d2[1 to 21]
add bar title='R3' as r3
add bar title='D3' as d3
shift r2[1 to 2] to r3
cut r3[1] into 3
shift d2[1 to 14] to r3
shift d2[22 to 23] to r3
add label title="14u" position=above to r3[5 to 18]
shift d2[15 to 21] to d3
shift d2[24] to d3
add label title="7u" position=above to d3[1 to 7]
add label title=50 position=above to d3[8]
add box size=180 stroke-style=dashed to d3 with label title="180" position=above
r3 = d3
add bar title='R4' as r4
shift r3[1 to 3] to r4
shift r3[5 to 18] to r4
shift r3[4] to r4
shift r3[19 to 20] to r4
add label title="17u" position=above to r4[1 to 17]
add label title=150 position=above to r4[18 to 20]

It seems to be a lot of code. But there are only 6 kinds of statements in the code:

  • add bar
  • add box
  • add label
  • cut box
  • shift box
  • constraints, e.g. r3 = d3

Although the language is pretty simple, it is really a programming language, which may help inspire the students’ interest in computer programming.

Read Full Post »

Older Posts »