#!/usr/bin/gnuplot# Author: Ika# Date: 12/02/2014# last changes:# 2018-01-28: (JoKalliauer) instead of 50 plots with one line one plot with 50 lines, and only the first has a key settermsvgfont'Liberation Sans, 24'setoutput'envelope_string_art.svg'# In this program, the envelope equation is x^2 - 2xy + y^2 -2kx - 2ky + k^2 = 0. # In other words, the family of the string lines is y = -(k-t)x/t + k-t. # Each line connects (0, k-t) and (t, 0).# Here k takes value 1.k=1;# n is the number of the trajectoriesn=51;setmultiplotsetsamples1000setxrange[0:k]setyrange[0:k]setxtics0.2setytics0.2setxzeroaxislt-1lcrgb"black"lw1setyzeroaxislt-1lcrgb"black"lw1unsetlabelsetkeyon#t = i*k*1.0/n;# The following draws the lines iteratively.plot-1*(k-(1*k*1.0/n))*x/(1*k*1.0/n)+k-(1*k*1.0/n)t"k = 1"lcrgb"red"lw1,\
for[i=2:n-1]-1*(k-(i*k*1.0/n))*x/(i*k*1.0/n)+k-(i*k*1.0/n)notitlelcrgb"red"lw1;unsetmultiplotsettermx11setoutput
Licensing
I, the copyright holder of this work, hereby publish it under the following license:
to share – to copy, distribute and transmit the work
to remix – to adapt the work
Under the following conditions:
attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.