Help with square root

Hi!

I´m trying to make a formula with math block using a square root but I can’t do it.

I want to use a square root like the image.

I tried using a math block with 3 ^ before the square root but it don´t works.

Can any one helps me?

Thanks!

If you need a square root, see this: How can i calculate X Y Z flux density? - #9 by tatiang.

Or do you need a cube root? Here’s how to do that:

I putted an image because I don’t know what it is called in English.

These are the blocks that I have used but it does not do the operation in the correct order, not are the correct blocks or not are the correct form to use it the square root for what I want.

I want to put a number in the text input “T” and that number is the one to use in the operation.

In the previous square root image the number on the text input will replace the “3”.

You need to remove the square root block.

Your blocks create an expression like

512^(sqrt(1/3))

Without the square root block, you will have an expression like

512^(1/3)
2 Likes

WOOOOW! I spend hours in that and you solve it in two messages!

I do it and works perfect!

Thanks!

4 Likes

You’re welcome! :slight_smile:

1 Like

hi can you help me with the code where we need to Find out whether the given number is a perfect cube or not. I am stuck on this

Did that not work? What number are you entering in the text input? What is the value of app variable perfect cube when you do that? And what is the value of Label14?

What happens if you (temporarily) replace Text_Input5's Text with an integer from the Math drawer? What if you tried it with 7 and with 8. What are the results then?

In the text input I am entering random number to find whether that number is perfect cube or not.
For example: 343 in text input
so I want app variable perfect cube to check whether the number in the text input is perfect cube or not and then in label14 it will take the number which is entered in text input and concatenate by showing whether its perfect cube or not.

I have made for perfect square root its working properly.
Here is the link
https://x.thunkable.com/projects/61fcd1503e46120011543934/8f480891-2b72-4147-8aee-47c461890649/designer

It’s not working correctly in all cases.

For example, it shows 343 as not being a perfect cube. There’s a rounding error… if you display the value of app variable perfect cube, it’s 6.999999999 which is then considered not whole.

These topics discuss the problem:

I think you can fix it by adding a “with decimal places” block like this:

(Thanks to @catsarisky for that one.)

image

2 Likes

Thanks alot.
Its working now . I didnt realise the decimals part.

1 Like

I have a job to send to a teacher but I don’t quite understand mathematical formulas. Ask for advice.
Create a calculator application using a square root.


Do you have someone who can help you with math formulas?

Are you able to Google the formulas you don’t understand?

After Googling or using resources like Khan Academy videos, what specific questions do you still have? What does the full assignment look like? It’s easier to answer your questions if you provide the context for those symbols.

1 Like

these are all equivalent

however i don’t understand why you would replace the value of the result if it was a whole number.
image

the way you coded it, if you entered 25, the square root should be 5, but your block displays 25?

meanwhile your other formula is wrong:
image

2 Likes

thank you

Button n! How to set settings in calculator

Help yourself and then we can help you…

1 Like

n! stands for n factorial. for example 4! (four factorial is computed as 4 * 3 * 2 * 1

the answer is practically staring at you. you will need to know what block to use that can count from 1 to 4.
you also would need a block that will multiply each number by the P, which is product of the last step (hint before youbegin set P to 1)
go over each new and multiply it by P - then store the new product in P.
finally make sure you include the special condition: 0! (ie. the factorial of zero is always 1).

try it yourself, put a few blocks together, if it doesn’t work, share a copy of what you got so far.

1 Like