传不了图,写个退而求其次……等等,谁说传不了图?
不谢邀,传不了图,写个退而求其次的答案
^ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | +----------------------------------------------------------------------------------------------------&>
不谢邀,我们无路可退,被迫传个图
传不了图,写个退而求其次的答案:
1.手机上下载desmos
2.键入1/x-ceil(1/x)【不知是上取整还是下取整,后者的话还要在此式上-1】
1.买个树莓派,里面自带一个免费的 Wolfram Mathematica:
Plot[1/x - Floor[1/x], {x, 0, 1}, PlotRange -&> All]
2.或者去 WolframAlpha,输入 1/x - Floor[1/x]
下载Wolfram Mathematica,输入以下代码:
Plot[1/x-IntegerPart[1/x],{x,0,1}]
想要获取字元画可以输入以下指令:
file = "D:\***.png";(*其中***.png是要转换的图片*) pic = Import[file]; pic = ColorConvert[pic, "Grayscale"]; pic = Thumbnail[pic, 100]; data = ImageData[pic]; color = " - - - + + + . . . 1 1 1 2 2 2 3 3 3 4 4 4 5 5 5 6 6 6 7 7 7 8 8 8 9 9 9 * * * # # #"; color = StringSplit[color]; closeMatch[c_] := color[[IntegerPart[c*100/2.5 + 1]]]; pic1 = Grid[Map[closeMatch, data, {2}], Spacings -&> {0, 0}]; Export["**.png", pic1](*导出图片**.png*)
退不了其次,写个传了图的答案
................................................................................ *.*..*....*..............*........................*............................. .*.................................................*............................ ....................................................*........................... .................*...................................*.......................... ..........................*...........................*......................... .......................................................**....................... .........................................................*...................... ...........................*..............................*..................... .............*.............................................**................... .............................................................*.................. ..............................................................**................ ..................*.........*...................................*............... .................................................................**............. ...................................................................**........... .............................*.......................................**......... .......................................................................**....... .........................................................................**..... ...*..........................*............................................**... ...................*.........................................................*** ...............................*................................................ ................................................................................ ..............*................................................................. .........*......................*............................................... ...........*.................................................................... .................................*.............................................. ....*...............*........................................................... ..................................*............................................. ................................................................................ ................................................................................ ...................................*............................................ ................................................................................ .....................*..............*........................................... .....................................*.......................................... ......*........*................................................................ ......................................*......................................... ................................................................................ ......................*................*........................................ ................................................................................ ........*...............................*....................................... .........................................*...................................... ..........................................*..................................... .......................*........................................................ ............*..............................*.................................... .......*....................................*................................... ................*............................*.................................. ................................................................................ ........................*.....................*................................. ...............................................*................................ ................................................*............................... .................................................*.............................. ................................................................................
(define (zhihu x) (- (/ 1 x) (floor (/ 1 x))))
(define x (let loop ((tmp 0.00001)) (if (&<= tmp 1.6) (cons tmp (loop (+ tmp 0.02))) ()))) (define y (map zhihu x)) (define (close? a b) (if (&< (abs (- a b)) 0.01) #t #f)) (call-with-output-file "c:/users/lh/desktop/zhihu.txt" (lambda (p) (let loop ((x 0)) (if (&<= x 1.6) (begin (display "." p) (loop (+ x 0.02)))) (newline p)) (let loop ((row 1)) (if (&>= row 0) (let loop2 ((tmp1 x) (tmp2 y)) (if (null? tmp1) (begin (display " " p) (loop (- row 0.02))) (if (close? (car tmp2) row) (begin (display "*" p) (loop2 (cdr tmp1) (cdr tmp2))) (begin (display "." p) (loop2 (cdr tmp1) (cdr tmp2)))))))) (let loop ((x 0)) (if (&<= x 1.6) (begin (display "." p) (loop (+ x 0.02)))) (newline p)) done))
这个IO没写好,画出来老是有几行(和行坐标对应的)空行,手动调整一下就好了。我懒得去检查了。
再画一个sin(8x)的图像
................................................................................................................................................................ ..................****...........................................................................***............................................................ ................*.............................................................................*.......*......................................................... ..............*..........*..............................................................................*....................................................... .........................................................................................................*...................................................... ..........................................................................................*..................................................................... .........................................................................................*...................................................................... ............................................................................................................*................................................... .........*...................................................................................................*.................................................. ........*....................................................................................................................................................... ................................*............................................................................................................................... .....................................................................................*.......................................................................... ................................................................................................................*............................................... ..................................*............................................................................................................................. ...................................................................................*............................................................................ ..................................................................................................................*............................................. ....................................*........................................................................................................................... .................................................................................*.............................................................................. ..*.................................................................................................................*..........................................* ......................................*......................................................................................................................... ................................................................................................................................................................ *............................................................................................................................................................*.. ........................................*.....................................*................................................................................. .......................................................................................................................*........................................ ................................................................................................................................................................ ............................................................................*................................................................................... .........................................................................................................................*................................*..... ...........................................*.................................................................................................................... ..........................................................................*..................................................................................... ...........................................................................................................................*............................*....... .............................................*.................................................................................................................. ........................................................................*....................................................................................... .............................................................................................................................*.................................. ..............................................................................................................................*......................*.......... ................................................*............................................................................................................... .................................................*...................*.......................................................................................... ..................................................*.................*........................................................................................... ...................................................*...............*............................................................................................ ....................................................*.............*............................................................................................. .....................................................*..............................................................................*..........*................ .......................................................*.......*.............................................................................*.................. ................................................................................................................................................................
..... ................. ..........................]]/]]]........ .......................]@@@@@@@@@@..... ......./@@@@@@@`....,@@@O@O@@OO@@@@`... ....,@@@@@@@@@@@@@^.=@@@O@@@@@@@@@@@.... ...,@@@O@@@@@@@@@@@@@@@@@@@@@@@@O@@@... ...=@@@@@@@@OO@@OO@@@@O@@@@@@@@@@@@@@... .../@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@^... ...O@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@^.... ...=@@O@@@@@@OO@@@@@@@@@@@@@@@@@@@@@..... ....=@@O@@@@@@@@@@@@@@@@@@@@@@@O@@@`..... .....=@@@O@@@@@@@@@@@@@@@@@@@@O@@@^...... ......=@@@O@@@@@@@@@@@@@@@@@@O@@@`....... ........@@@@@@@@@@@@@@@@@@@@O@@@...... . .....,@@@@O@@@@@@@@@@@O@@@^....... . . .....@@@@O@@@@@@O@@@@`...... ........,@@@@@O@@@@@@`........ .........,@@@@@@@`...... .........[[`.... . ............ .......... ..
1、打开repl.it,选择Python,等它载入跳转新页面。
2、输入以下代码:
import numpy as np import matplotlib.pyplot as plt
num_points = 10000
x = np.linspace(0.001,0.999,10000) y = 1/x - np.floor(1/x)
plt.plot(x,y) plt.show()
你会看到一个非常反人类的图形,极不规则又在 之间。
哈哈哈哈,楼下的朋友贴吧玩多了吧。
保持队形:
传不了图,写个退而求其次的答案
1,手机端下载Graph Plotter或Graph Calculator,下载完成打开进入界面
2,找到高斯函数(对应为floor),在括弧里输入
3,观察在 之间的图像
下载geogebra自己输入表达式就看到了
没有现代软体,退而求其次,用上古时期的GrafEq画的
先导出PCX再到BMP再到PNG,可麻烦了
不过效果并不逊色于现代软体呢(笑)
代码
x = linspace(0.0001,1,1000);
y = 1./x - floor(1./x);
plot(x,y)
用python或者matlab画个图就那么难?
你们是真传不了图还是炫技还是违规了
替楼上贴一个
传不了图,写个退而求其其其其奇奇怪怪为什么我可以?
帮楼上贴个图
忽略第三行忘记写等号
: