Type (or paste) your ASCIIsvg commands into the textarea. Then click the update button to see the picture. To save your work, select the text (Ctrl-A) and copy it to a text editor (e.g. Notepad). Choose the layout that best fits your screensize:
Type (ASCIIsvg commands and JavaScript) | Display (Requires IE+SVGviewer 3.01 or Mozilla+SVG) |
|
initPicture( xmin, xmax {, ymin {, ymax}} ) | border = "pixelvalue" (default 25) |
grid( {dx, dy} ) | axes( {dx, dy, {"labels"}} ) |
line( [x,y], [u,v] ) | marker = "dot" | "arrow" | "arrowdot" | "none" |
path( [ [x1,y1], [x2,y2], ..., [xn,yn] ] ) | curve( [ [x1,y1], [x2,y2], ..., [xn,yn] ] ) |
plot( "f(x)" {, xmin, xmax, npoints} ) | plot( [ "f(t)", "g(t)" ] {, tmin, tmax, npoints} ) |
stroke = "color" | strokewidth = "pixelvalue" (default 1) |
fill = "color" | strokedasharray = "dashpixel spacepixel" |
fontsize = "pixel" (default 20) | fontweight = "bold" | "normal" |
fontstyle = "italic" | "normal" | fontfamily = "serif"|"sansserif"|"fixed"|"monotype" |
circle( [x,y], r ) | ellipse( [x,y], rx, ry ) |
arc( [x,y], [u,v], r ) | rect( [x,y], [u,v] ) |
text( [x,y], "label" {, position} ) | dot( [x,y] {, "open"|"closed" {, "label", position} ) |
position can be: above, below, left, right, | aboveleft, aboveright, belowleft, belowright, null |
For the plot commmand, the functions f(x), f(t), g(t) can use any valid JavaScript function or constant (without the "Math." prefix): PI, E, +, -, *, /, sqrt, sin, cos, tan, asin, acos, atan, abs, exp, log (=ln), floor, ceil, ... (pi, e, x^y, ln, arcsin, arccos, arctan, sec, csc, cot are defined as well, and cpi, ctheta denote the respective greek letters).
This Editor is useful for learning about coordinate geometry, graphs of functions, parametric curves, JavaScript, SVG, ... Have fun.