Click here to Skip to main content
16,015,108 members
Home / Discussions / Algorithms
   

Algorithms

 
GeneralRe: vb6 algorithm Pin
Paul Conrad19-Nov-06 4:56
professionalPaul Conrad19-Nov-06 4:56 
GeneralRe: vb6 algorithm [modified] Pin
Agus Budianto2-Dec-06 21:23
Agus Budianto2-Dec-06 21:23 
QuestionRSA Pin
DanB19839-Nov-06 4:57
DanB19839-Nov-06 4:57 
AnswerRe: RSA Pin
Sebastian Schneider10-Nov-06 3:00
Sebastian Schneider10-Nov-06 3:00 
AnswerRe: RSA Pin
Bagaturia david15-Nov-06 21:56
Bagaturia david15-Nov-06 21:56 
QuestionCosting terrain paths Pin
Kevnar8-Nov-06 8:56
Kevnar8-Nov-06 8:56 
AnswerRe: Costing terrain paths Pin
ejuanpp9-Nov-06 0:40
ejuanpp9-Nov-06 0:40 
GeneralRe: Costing terrain paths [modified] Pin
Kevnar9-Nov-06 2:53
Kevnar9-Nov-06 2:53 
Wow. It never occured to me that the Pythagoreum thing worked in three dimensions. Thanks. That helps a lot.

My question is though, what to change the value of k to? If the target square is n higher or n lower, how do you cost it for the expense of climbing uphill, or downhill as compared to walking over level ground? I thought about giving it an arbitrary value based on the difference in terrain heights, but that seemed kinda clunky to me.

What I should do I suppose is find a chart on the internet of the amount of calories burned in walking as opposed to stair-climbing and wall-climbing. That might help.

Thanks again.

----------------------
...ten minutes later

Okay, I looked up the calorie charts and it turns out that stair-climbing is approximately double straight walking, and wall-climbing is approximate triple straight walking. So if I convert that to angles:
0 = 1
45 = 2
90 = 3

Now how do I convert that into a formula so that values in between return their appropriate costs?

I'll assume the values are the same for going down in terrain as well, though they might be slightly cheaper.


-- modified at 9:13 Thursday 9th November, 2006

cost = 1 + (angle / 45)

d'uh. I better get some coffee. Thanks all.Laugh | :laugh:

-- modified at 9:27 Thursday 9th November, 2006

"Go to, I’ll no more on’t; it hath made me mad." - Hamlet

GeneralRe: Costing terrain paths Pin
ejuanpp9-Nov-06 3:21
ejuanpp9-Nov-06 3:21 
GeneralRe: Costing terrain paths [modified] Pin
Kevnar9-Nov-06 3:40
Kevnar9-Nov-06 3:40 
GeneralRe: Costing terrain paths Pin
ricecake9-Nov-06 4:09
ricecake9-Nov-06 4:09 
GeneralRe: Costing terrain paths Pin
Kevnar9-Nov-06 4:16
Kevnar9-Nov-06 4:16 
GeneralRe: Costing terrain paths Pin
ricecake9-Nov-06 4:37
ricecake9-Nov-06 4:37 
GeneralRe: Costing terrain paths [modified] Pin
Kevnar9-Nov-06 5:24
Kevnar9-Nov-06 5:24 
GeneralRe: Costing terrain paths Pin
ricecake9-Nov-06 5:48
ricecake9-Nov-06 5:48 
GeneralRe: Costing terrain paths Pin
Kevnar9-Nov-06 6:05
Kevnar9-Nov-06 6:05 
GeneralRe: Costing terrain paths Pin
ricecake9-Nov-06 6:46
ricecake9-Nov-06 6:46 
GeneralRe: Costing terrain paths Pin
Kevnar9-Nov-06 7:14
Kevnar9-Nov-06 7:14 
GeneralRe: Costing terrain paths Pin
ricecake9-Nov-06 7:21
ricecake9-Nov-06 7:21 
GeneralRe: Costing terrain paths Pin
Kevnar9-Nov-06 7:31
Kevnar9-Nov-06 7:31 
GeneralRe: Costing terrain paths Pin
ejuanpp9-Nov-06 3:43
ejuanpp9-Nov-06 3:43 
GeneralRe: Costing terrain paths Pin
Kevnar9-Nov-06 4:13
Kevnar9-Nov-06 4:13 
QuestionBeginners question? Where does the exact double value go? Pin
ClockDivider8-Nov-06 6:48
ClockDivider8-Nov-06 6:48 
AnswerRe: Beginners question? Where does the exact double value go? Pin
Rob Graham8-Nov-06 7:09
Rob Graham8-Nov-06 7:09 
GeneralRe: Beginners question? Where does the exact double value go? Pin
Dan Neely8-Nov-06 7:24
Dan Neely8-Nov-06 7:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.