Welcome Guest.   Make a donation to an author on the site November 21, 2014, 08:58:16 PM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
Your Support Funds this Site: View the Supporter Yearbook.
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1]   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: DONE: Automatically compute sizes of tangram pieces  (Read 6750 times)
rmo
Participant
*
Posts: 3

View Profile Give some DonationCredits to this forum member
« on: February 29, 2012, 08:23:37 PM »

A really cool software for my workshop, should not be complex, I would not think.

Basically, I make tangram puzzle pieces. Wooden ones for kids and grownups alike to play with. But there has to be an easier way to figure out the piece sizes.



What I would like to do is be able to input ONE number and all the pieces' side lengths are automatically calculated. So, I can make a tangram any size I want without having to take time to figure out the size of every single piece. If, say, I wanted to make the large square with a base of 10 inches, the program could figure all the lengths.

Here's the breakdown on size relationships, but the image shows it pretty well:

There are seven pieces to the puzzle, arranged in the image as shown to make a square: 5 triangles, 1 square and 1 parallelogram. The triangles are all isosceles, with 2 small ones, 1 middle size, and 2 large ones.

As you can see, the large triangles' hypotenuse is equal to one side of the whole square. The middle triangle's legs are 1/2 the length of the square. The small triangles' hypotenuse is 1/2 the length of the square. The small square's side is equal to 1/2 the middle triangle's hypotenuse, or the whole length of the small triangles' leg. The parallelogram's long side is equal to 1/2 the whole square's side, while the short side is equal to 1/2 of the hypotenuse of the middle triangle.

Is this doable?

Thanks!

Ron
Logged
skwire
Global Moderator
*****
Posts: 4,157



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #1 on: February 29, 2012, 11:07:31 PM »

Here's a preliminary screenshot:



Was this something like you had in mind?
Logged

Target
Honorary Member
**
Posts: 1,411



see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #2 on: March 01, 2012, 12:56:56 AM »

FWIW there are apps around that do similar things, ie calculating 'best fits' for cutting the maximum number of pieces out of a flat plane.

are there likely to be any more variables, eg varying the number of pieces?

and a suggestion - I have no idea if this possible or not, but it may get someone thinking.  Instead of measuring the sides, how about a drawing type application that lets you pick and place the various shapes into a defined outline.  The resulting image could be printed out and used as a 'template' (stick it onto your chosen material and cut along the lines)
Logged

"Look wise, say nothing, and grunt. Speech was given to conceal thought" - Sir William Osler
cranioscopical
Friend of the Site
Supporting Member
**
Posts: 4,195



see users location on a map View Profile Read user's biography. Give some DonationCredits to this forum member
« Reply #3 on: March 01, 2012, 07:43:54 AM »

Was this something like you had in mind?
Nice work, and back in under three hours  Thmbsup
« Last Edit: March 01, 2012, 08:43:48 AM by cranioscopical » Logged

Chris
rmo
Participant
*
Posts: 3

View Profile Give some DonationCredits to this forum member
« Reply #4 on: March 01, 2012, 01:43:11 PM »

Here's a preliminary screenshot:
 (see attachment in previous post)
Was this something like you had in mind?

YES! Perfect!
Logged
skwire
Global Moderator
*****
Posts: 4,157



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #5 on: March 01, 2012, 03:05:32 PM »

YES! Perfect!


Here you go:  Tangram Calc
Logged

rmo
Participant
*
Posts: 3

View Profile Give some DonationCredits to this forum member
« Reply #6 on: March 01, 2012, 08:56:26 PM »

Thank you so much!

Now I can input some numbers for different size tangram puzzles to see which sizes are easiest to make. Works like a dream and I love that it can be more or less exact, depending on what decimal points I want.

Now if only it could sharpen my saw blades!  Grin

Thanks again!!

Ron
Logged
skwire
Global Moderator
*****
Posts: 4,157



Another Coding Snack request? Om nom nom...

see users location on a map View Profile WWW Give some DonationCredits to this forum member
« Reply #7 on: March 01, 2012, 11:27:58 PM »

You're very welcome.  I'm glad you've found it useful.  =]
Logged

Pages: [1]   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.031s | Server load: 0.18 ]