I want help | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

I want help

Can i write a physic equation into method in java? Is that easy or not? To do all the calculation and run the result correctly! Task and equation: https://www.sololearn.com/post/338825/?ref=app

18th Apr 2020, 4:47 PM
Manar naif
Manar naif - avatar
7 Answers
+ 3
Add it to a feed post and link it here Manar naif
19th Apr 2020, 9:18 PM
Tashi N
Tashi N - avatar
+ 2
It would be good to show us the equation.
19th Apr 2020, 8:28 PM
Tashi N
Tashi N - avatar
+ 2
Okay. Start to split up the terms of the equation, calculate the fraction for the e function first. For the Euler function you can use https://docs.oracle.com/javase/8/docs/api/java/lang/Math.html#exp-double- For the other exponential terms, Math.pow should do the trick (I can't read the exponential numbers tbh, but I hope a double is enough) https://docs.oracle.com/javase/8/docs/api/java/lang/Math.html#pow-double-double- Once you've done that for the first value of V, let's say 0.6 try to embed the formula in a loop to increment the value for V from 0.6 to 0.75.
19th Apr 2020, 9:39 PM
Tashi N
Tashi N - avatar
+ 1
Sure, it's possible. But first you need to learn the basics of Java. Since you've already started the tutorial, keep going, practice, and soon you will figure it out.
18th Apr 2020, 4:52 PM
HonFu
HonFu - avatar
0
i have already learned the basics, but this equation i have it's too complicated.
18th Apr 2020, 5:07 PM
Manar naif
Manar naif - avatar
0
i would like to show the equation but i dont know how send photo here or write it
19th Apr 2020, 9:17 PM
Manar naif
Manar naif - avatar
19th Apr 2020, 9:23 PM
Manar naif
Manar naif - avatar