代码:Python获取黄金分割比例
也可以自己写代码计算,Scipy提供了现成的常量.from scipy.constants import *
print(golden)
print(golden_ratio)
真有意思,一窍也不通,哈哈! 有人尝试列出Golden Ratio长达几千个小数点,我记得是1.6..... Starrry 发表于 2022-4-1 18:37
有人尝试列出Golden Ratio长达几千个小数点,我记得是1.6.....
那么到底什么叫做黄金比例呢 蓝莓糖 发表于 2022-4-1 21:04
那么到底什么叫做黄金比例呢
主要是这个方程式,具体我也不是很懂,哈哈。
This is the ratio of dividing a line segment A into two parts B and C such that A is to B as B is to C.
A
------------+-------
B C
This deceptively simple ratio has fascinated mathematicians for centuries.
It can be written as A/B = B/C.
The ratio A/B is usually designated by the Greek letter phi, and it is approximately equal to 1.618.
Now if your task were to simply output "1.618", it wouldn't be much of a challenge. Printing a text string would do. The challenge is that your entry must print the value of phi for 2400 places after the decimal point, rounded to the nearest value. You may use a text string if you want, but it's very unlikely to be a winning strategy. Starrry 发表于 2022-4-1 21:06
主要是这个方程式,具体我也不是很懂,哈哈。
谢谢告知,大概就是一个线段分成两段,然后得到的比例吧 Starrry 发表于 2022-4-1 21:06
主要是这个方程式,具体我也不是很懂,哈哈。
我也得研究下,为啥黄金分割在设计上这么受欢迎.
页:
[1]