## swissgirl 3 years ago Expanding using wolfram

1. swissgirl

@apoorvk

2. swissgirl

wait i messed up the function

3. swissgirl

idk how i am suppoosed to deal with this. Like i have mathematica but not either sure how to use it

4. swissgirl

8.9824391E-7(x^6-94x^5+3529x^4-67624x^3+695548x^2-3624640+7425000)-3.04470962E-5(x^6-88x^5+3001x^4-49618x^3+397840x^2-1237600x)+2.822089947E-4(x^6-84x^5+2689x^4-40734x^3+288208x^2-742560x)- 3.25571254E-4(x^6-81x^5+2476x^4-35436x^3+234880x^2-571200x)+1.742019122E-4(x^6-77x^5+2220x^4-29884x^3+187520x^2-435800x)-6.2386735E-5(x^6-74x^5+2049x^4-26644x^3+162668x^2-371280x)+1.96362980E-6(x^6-66x^5+1681x^4-20556x^3+119980x^2-265200x)

5. estudier

8.98244x10^-7 (x^6-94 x^5 3529 x^4-67624 x^3 695548 x^2 3800360)-304471. (x^6-88 x^5 3001 x^4-49618 x^3 397840 x^2-1237600 x) 0.000282209 (x^6-84 x^5 2689 x^4-40734 x^3 288208 x^2-742560 x)-3.25571

6. estudier

That's what comes out when I pastein Wolfram...

7. estudier

What are you supposed to be doing, solve for x?

8. swissgirl

ummm well actually it didnt allow u to paste everything cuz the input was too large and therefore u got the incorrect answer but i need to expand the following

9. swissgirl

@ParthKohli @Hero Can you check this out?

10. Hero

What are you trying to expand that for?

11. swissgirl

Its expand and find like terms to get a single polynomial

12. ParthKohli

Expand[expression]

13. ParthKohli

Oh, then "expansion" is not the word.

14. ParthKohli

Together[expression]

15. Hero

@swissgirl, you should probably get maple, quick

16. swissgirl

ohhhhhhhhh where wld i do that on wolfram or mathematica?

17. swissgirl

I have mathematica but i have no clue how to use it

18. ParthKohli

Mathematica, of course!

19. swissgirl

Parth can u guide me step by step cuz i am stupiddddd

20. ParthKohli

Just go to any notebook and type in "Together[your expression]".

21. ParthKohli

And then, shift+enter for output.

22. swissgirl

ohhhh ok let me try that give me a sec? Hero do u have a program on maple for interpolating lagrange polynomials?

23. estudier

Maple is OK, got to type in a lot of *'s.....

24. swissgirl

lol idk how to program at allllllll lol So if the program isnt given to me then I wont know how to use it and for this specific section My textbook didnt provide coding so I am stuck

25. ParthKohli

@swissgirl In Mathematica, click on Palettes on the menu bar. You should see a Basic Math Assistant.

26. swissgirl

okkkkkk

27. ParthKohli

There, you get a list of symbols and commands. :)

28. estudier

I suppose that mess is the n+1 points, is that it?

29. swissgirl

yup lol

30. swissgirl

its the \(f(x_n)*L_n(x)\) polynomials

31. swissgirl

I got the wrong answer though. hmmm I wonder y

32. swissgirl

What does together mean?

33. swissgirl

@ParthKohli

34. Hero

Wow, @swissgirl, I'm sorry you're experiencing such difficulty

35. swissgirl

idk I plugged term by term into the calculator and got the correct answer but mathematica for some reason gave me the wrong answer

36. estudier

http://mathworld.wolfram.com/LagrangeInterpolatingPolynomial.html Says Mathematica implents as InterpolatingPolynomial[data,var]

37. ParthKohli

I don't know much about Math :P

38. estudier
39. swissgirl

like look only the first polynomial has like a term without an x 8.9824391E-7(x^6-94x^5+3529x^4-67624x^3+695548x^2-3624640+7425000) so 8.9824391E-7*7425000=6.67 but mathematica gives me this number that is wayyy offff

40. swissgirl

THHANNNKKKKSSSS ESTUDIERRRRRRRRRRRR

41. swissgirl

omg i have been sitting hours here.

42. estudier

I hope you can figure it out, I haven't Mathematica....

43. swissgirl

@estudier I GOT THE CORRECT ANSWEERRRRRRRRRRR lol OMG Finallllyyy

44. swissgirl

@experimentX like y didnt mathematica process all my polynomials. It was giving me an incorrect answer

45. experimentX

huh? really?

46. swissgirl

yaaaaa its weird

47. swissgirl

I may have inputed it incorrectly

48. experimentX

what is this? 8.9824391 E - 7

49. swissgirl

8.9824391*10^-7

50. swissgirl

ohh mayge i gotta bracket the -7

51. swissgirl

let me try that

52. swissgirl

But which brackets would u suggest I use?

53. experimentX

probably due to that ... try to input piecewise.

54. experimentX

( ) small brackets

55. swissgirl

THANKS :)

56. swissgirl

nah it became wierder

57. swissgirl

let me try 10^-n instead of E

58. experimentX

8.9824391*10^(-7)

59. experimentX

Or click (from menu) Palette > Basic math assistant

60. swissgirl

much closer like just a bit off like instead of 6.67 i have 3.47

61. swissgirl

62. swissgirl

Together[(8.9824391*10^-7) (x^6 - 94 x^5 + 3529 x^4 - 67624 x^3 + 695548 x^2 - 3624640 + 7425000) - (3.04470962*10^-5) (x^6 - 88 x^5 + 3001 x^4 - 49618 x^3 + 397840 x^2 - 1237600 x) + (2.822089947*10^-4) (x^6 - 84 x^5 + 2689 x^4 - 40734 x^3 + 288208 x^2 - 742560 x) - (3.25571254*10^-4) (x^6 - 81 x^5 + 2476 x^4 - 35436 x^3 + 234880 x^2 - 571200 x) + (1.742019122*10^-4) (x^6 - 77 x^5 + 2220 x^4 - 29884 x^3 + 187520 x^2 - 435800 x) - (6.2386735*10^-5) (x^6 - 74 x^5 + 2049 x^4 - 26644 x^3 + 162668 x^2 - 371280 x) + (1.96362980*10^-6) (x^6 - 66 x^5 + 1681 x^4 - 20556 x^3 + 119980 x^2 - 265200 x)]

63. swissgirl

oh whoops in mathematica the exponent was where it needed to be

64. experimentX

hmm ... try doing this in pieces ... check every polynomial

65. swissgirl

ohhh should do that let me try that

66. swissgirl

okkkk i think its because i rounded off a number. I think its my problem. Thankksss for helping me outtt :)))))))

67. experimentX

no probs!! have fun swissgirl

68. swissgirl

:)