# A question about calculus and Programming

I am a very new user and I would like to know how to calculate the following operations in Mathematica. Honestly this is not a homework. I am an french architect and I would like to be back in Math specifically in graph theory. Here we go, to design some structures I need to find some precise values this is why we use primes below for instance. Then, does Mathematica is able to compute successfully such operations? If not what would be the useful application for?

Let $$\cfrac{2n+3x+\epsilon}{y.3x-\epsilon}=\frac{1+\sqrt{5}}{2}.$$

In this case $x$ is a prime factor of $n$ and $\epsilon$ is any definite constant. I would ask to Mathematica to input all prime numbers lower than $n$ represented by $x\in\mathbb{P}$ and to find $y$ for which the relation holds true.

The other question is: if for $x$ I need to specify an interval between two primes lower than $n$ how can I do that?

This is not about factoring but in geometry this can be helpful. Please let me know what is unclear. Thank you

• Almost certainly, Mathematica can handle your problem What do you mean by y.3x? In Mathematica, it would represent a dot-product, but you probably have something else in mind. May 25 '15 at 21:36
• @bbgodfrey Sorry it's a dot-product in this case. Thank you Professor. May 25 '15 at 21:48

Here is a Fred Flintstone method. (1) To create a list of prime numbers:

plist = Table[Prime[k], {k, 10, 15}]


which outputs

{29, 31, 37, 41, 43, 47}

(2) To solve the equation use n = k x where k is an integer:

Solve[(( 2 k + 3 ) x + \[Epsilon])/(3 x y - \[Epsilon]) == GoldenRatio,y]


which provides

{{y -> (6 x + 4 k x + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (x + Sqrt x))}}

you can harvest the solution using

soln = y /. % /. x -> plist

which produces the solution set

{{(174 + 116 k + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (29 + 29 Sqrt)), (186 + 124 k + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (31 + 31 Sqrt)), (222 + 148 k + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (37 + 37 Sqrt)), (246 + 164 k + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (41 + 41 Sqrt)), (258 + 172 k + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (43 + 43 Sqrt)), (282 + 188 k + 3 \[Epsilon] + Sqrt \[Epsilon])/(3 (47 + 47 Sqrt))}}

• This look great. I will try this and be back for comments. Thanks May 25 '15 at 22:12