Forum Discussion
How use math equations.
Hello community. I am working on a lesson which requires equations. for example, if the user selects "250 GB" in the intro slide. I need that number to automatically carry over to the data slide and be multiplied by 1.125. Then that number I need to be able to be part of another equation.
I am not sure how I should go about designing this. Thank you
- WaltHamiltonSuper Hero
Use these triggers, all of which should have "when timeline starts on this slide" as their when clause.
To find DV:
Adjust variable set DV to variable Slider When timeline starts on slide Data_slide
Adjust variable Multiply DV by 1.125 when tl ...
To find FLRH:
Adjust variable set FLRH to variable DV
Adjust variable Multiply FLRH by 20000
Adjust variable Divide FLRH by 50
Adjust variable set ReviewHours to variable FLRH
Adjust variable Multiply Review Hours by 1.082
To find eDiscoveryCosts:
Adjust variable set Hosting to variable DV
Adjust variable Multiply Hosting by 12
Adjust variable Multiply Hosting by 8 (or if you are really daring, combine the last two triggers, and multiply by 96. See note below about decimals)
Adjust variable set eDiscoveryCosts (eDC) to variable ReviewHours
Adjust variable Multiply eDC by 47.09
Adjust variable Add variable Hosting to eDC
SL has a mind of its own when it comes to decimals. The only way to get an answer in correct $0.00 form is to move it to JS, change it to a string (text), and send it back to SL in a text variable. Many people, when faced with that, do all the calculations in JS, too, because JS commands can be written in a form that more closely resembles the original equations.