Thingiverse
Plot Function library for OpenSCAD, with Cartesian, Polar, and Axial coordinates by rcolyer
by Thingiverse
Last crawled date: 3 years, 1 month ago
This is a general purpose function plotting library for OpenSCAD which will render functions with Cartesian coordinates (x & y input, z output), polar/cylindrical coordinates (r & angle input, z output), or axial coordinates (z & angle input, r output). This library is sufficiently flexible that it can be used for more than just plotting functions. As demonstrated in the included demo files, this can efficiently render ordinary objects with surfaces defined by mathematical functions.
While there are a few other function plotting libraries out there for OpenSCAD, this one is particularly robust, fast, and flexible. It uses list comprehension to generate each plot as a single polyhedron, supports multiple user-defined functions of each type in one design, consistently creates properly manifold renders, and executes as quickly as any other rendered object of comparable size.
Since OpenSCAD does not support passing functions as parameters, this library resolves it by allowing the user to declare functions Func1, Func2, etc, PolarFunc1, PolarFunc2, etc, and AxialFunc1, AxialFunc2, etc. Then the number 1, 2, etc is passed to the corresponding plot routine. For example, the following code will create a Cartesian coordinate plot of the following function #1 over the domain -40 through 40 in both x and y with a step size of 0.4:
include
function Func1(x, y) = 2*(1.5 + cos(x*x + y*y/4));
PlotFunction(1, [-40, 0.4, 40], [-40, 0.4, 40]);
The module call PlotFunction can occur anywhere a normal polyhedron could be generated, but the function definition Func1 must be declared at the top-level of the code so that it can be accessed from within the included plotting library. Note that it must "include" plot_function.scad rather than "use" it so that Func1 and others are accessible. A variety of usage demonstrations are in the demo_plot_function.scad file, and the API for the three plotting modules is as follows:
// Plots the numbered function Func1 through Func9, where FuncN is 1 through 9.
// Each function is a function of x and y.
// minx_stepx_maxx should be [minx, stepx, maxx], and likewise for y,
// specifying the domain to be plotted.
// To guarantee a properly manifold shape, the routine will only render
// strictly positive values (z>0) of the defined function. Add an offset if
// needed to achieve this.
module PlotFunction(FuncN, minx_stepx_maxx, miny_stepy_maxy)
// Plots the numbered function PolarFunc1 through PolarFunc9, where
// PolarFuncN is 1 through 9. Each function is a function of radius and
// angle.
// max_r is the outer radius, and min_step is the smallest step size between
// points.
// To guarantee a properly manifold shape, the routine will only render
// strictly positive values (z>0) of the defined function. Add an offset if
// needed to achieve this.
module PlotPolarFunction(PolarFuncN, max_r, min_step=-1)
// Plots the numbered function AxialFunc1 through AxialFunc9, where
// AxialFuncN is 1 through 9. Each function is a function of z-height and
// angle, and returns the radius outward in the xy-plane.
// max_r is the outer radius, and min_step is the smallest step size between
// points.
// minz_stepz_maxz should be [minz, stepz, maxz], and likewise for y,
// specifying the domain to be plotted.
// To guarantee a properly manifold shape, the routine will only render
// strictly positive values (r>0) of the defined function. Add an offset if
// needed to achieve this.
module PlotAxialFunction(AxialFuncN, minz_stepz_maxz, num_circle_steps=360)
While there are a few other function plotting libraries out there for OpenSCAD, this one is particularly robust, fast, and flexible. It uses list comprehension to generate each plot as a single polyhedron, supports multiple user-defined functions of each type in one design, consistently creates properly manifold renders, and executes as quickly as any other rendered object of comparable size.
Since OpenSCAD does not support passing functions as parameters, this library resolves it by allowing the user to declare functions Func1, Func2, etc, PolarFunc1, PolarFunc2, etc, and AxialFunc1, AxialFunc2, etc. Then the number 1, 2, etc is passed to the corresponding plot routine. For example, the following code will create a Cartesian coordinate plot of the following function #1 over the domain -40 through 40 in both x and y with a step size of 0.4:
include
function Func1(x, y) = 2*(1.5 + cos(x*x + y*y/4));
PlotFunction(1, [-40, 0.4, 40], [-40, 0.4, 40]);
The module call PlotFunction can occur anywhere a normal polyhedron could be generated, but the function definition Func1 must be declared at the top-level of the code so that it can be accessed from within the included plotting library. Note that it must "include" plot_function.scad rather than "use" it so that Func1 and others are accessible. A variety of usage demonstrations are in the demo_plot_function.scad file, and the API for the three plotting modules is as follows:
// Plots the numbered function Func1 through Func9, where FuncN is 1 through 9.
// Each function is a function of x and y.
// minx_stepx_maxx should be [minx, stepx, maxx], and likewise for y,
// specifying the domain to be plotted.
// To guarantee a properly manifold shape, the routine will only render
// strictly positive values (z>0) of the defined function. Add an offset if
// needed to achieve this.
module PlotFunction(FuncN, minx_stepx_maxx, miny_stepy_maxy)
// Plots the numbered function PolarFunc1 through PolarFunc9, where
// PolarFuncN is 1 through 9. Each function is a function of radius and
// angle.
// max_r is the outer radius, and min_step is the smallest step size between
// points.
// To guarantee a properly manifold shape, the routine will only render
// strictly positive values (z>0) of the defined function. Add an offset if
// needed to achieve this.
module PlotPolarFunction(PolarFuncN, max_r, min_step=-1)
// Plots the numbered function AxialFunc1 through AxialFunc9, where
// AxialFuncN is 1 through 9. Each function is a function of z-height and
// angle, and returns the radius outward in the xy-plane.
// max_r is the outer radius, and min_step is the smallest step size between
// points.
// minz_stepz_maxz should be [minz, stepz, maxz], and likewise for y,
// specifying the domain to be plotted.
// To guarantee a properly manifold shape, the routine will only render
// strictly positive values (r>0) of the defined function. Add an offset if
// needed to achieve this.
module PlotAxialFunction(AxialFuncN, minz_stepz_maxz, num_circle_steps=360)
Similar models
thingiverse
free
Openscad function plot by RoCMP
...ersion correcting a flaw that produced degenerated polygons in some instances. the examples and comments also have minor changes.
thingiverse
free
Merkabah Openscad by GHerling
...an coordinates define the four vertices of a tetrahedron with edge length 2, centered at the origin:
(±1, 0, −1/√2)
(0, ±1, 1/√2)
thingiverse
free
OpenScad model of servo 9g by totesalaz
...e use of the servo model as a module that can be translated by defining the x, y and z components in the function servo9g(x,y,z);
thingiverse
free
Plot XYZ by ebensmith
...is that have to be manipulated by hand whilst following predetermined coordinates and placing building blocks on the build plate.
thingiverse
free
Vase and bowl openscad generator by bda
...esign.
openscad generate a big polygedron and working fast.
with resolution 1mm render only 7sec and generate 130000 triangles.
thingiverse
free
Introduction to Cartesian Coordinates and Plane by Dimorgoniv
...nction and how to determine domain and range of a set of data points.
print twice and hold together with connectors on the axes.
thingiverse
free
Extruder_Titan_piece-inductive_sensor by fandres7_7
...nozzle]
license
creative commons attribution-sharealike 4.0 international license
follow my work in:
http://gitlab.com/fandres7_7
thingiverse
free
Anet A8 12 mm front sensor fan mount Remix by MarkerDave
...t_probe_bed_position 25
define right_probe_bed_position 194
define back_probe_bed_position 170
define front_probe_bed_position 20
thingiverse
free
centercube() OpenSCAD module by Professional3D
...e boolean parameters x, y and z
or all together with center
each parameter except the first (dimensions of the cube) is optional.
thingiverse
free
Anet A8 Sensor Bracket by Jako124
...t_probe_bed_position 25
define right_probe_bed_position 194
define back_probe_bed_position 170
define front_probe_bed_position 20
Rcolyer
thingiverse
free
Extruder Cleaner by rcolyer
...so that no one will will assume it is another failed print and throw it out. this can happen...
this design works in customizer.
thingiverse
free
Double-Slit Experiment 3D Representation by rcolyer
...ir of display pieces for a select crowd.
this was generated using my plotting library: https://www.thingiverse.com/thing:2391851
thingiverse
free
18650 Battery Holder by rcolyer
...tl file should work well for this. flexible filament might be even nicer for purposes of a battery cap, but i didn't try it.
thingiverse
free
Wallet Comb, Credit Card Sized by rcolyer
... it was a neat design, and it costs about 3 cents worth of plastic to print it.
and yes, you can actually comb your hair with it.
thingiverse
free
Customizable Rippled Chalice / Vase by rcolyer
...adjustable in customizer.
note: the ripple_chalice.scad file uses my plotting library: https://www.thingiverse.com/thing:2391851
thingiverse
free
Baby Hair Comb with Personalized Text by rcolyer
...your printer's properties, some adhesive on the print bed at the ends of the teeth might significantly help in printing this.
thingiverse
free
3D Printed Nails (That Don't Work) by rcolyer
...ps there is a material out there which makes this useful, but pla does not appear to be it.
this works in customizer. good luck!
thingiverse
free
HICTOP Circuit Board Cover Box by rcolyer
...as my first attempt at modifying an existing stl file using openscad, and i found it a little easier than i anticipated it being.
thingiverse
free
HICTOP Prusa i3 (3DP-11) Y-Axis End Brackets by rcolyer
...
note: the openscad file uses my threading library for the clearance and mounting holes. http://www.thingiverse.com/thing:1686322
thingiverse
free
Smooth Basic Hair Comb by rcolyer
...f the hair. also, if you can, i recommend printing this in petg as the slight flexibility makes it a very nice material for this.
Cartesian
3ddd
$1
CARTESIAN STOOL
...cartesian stool
3ddd
cartesian , табурет
(w) 450 mm x (d) 510 mm x (h) 410 mm.
3ddd
free
Cartesian Pulley Single Pendant
...
подвес rhhttp://www.restorationhardware.com/catalog/product/product.jsp?productid=prod60333&categoryid;=cat1701013
3d_export
$10
the mandalorian - full armor and
...for easy printing<br>test model printed on pla material in cartesian printer<br>model divided into:<br>model in format: stl<br>model: high poly<br>other formats...
3d_export
$10
son goku
...collectors, perfect model to be printed on resin and cartesian printers.<br>even on printers that use filaments, the level of...
3d_export
$10
bulma-dragon ball z
...collectibles, perfect model to be printed on resin and cartesian printers.<br>even on printers that use filaments, the level of...
3d_export
$5
storm statue
...like collectible,<br>perfect model to be printed in resin and cartesian printers.<br>even in printers that use filaments, the level of...
thingiverse
free
Cartesian Plane by TFbio
...plane on a white sheet.
size of the bigger plan: 28x28x0.2 [cm]
distance between the holes: 5[mm]
number of the holes: 25254=2500
thingiverse
free
Cartesian Diver Rocket! by teolacambra
...iver rocket! by teolacambra
thingiverse
this is a basic cartesian diver to print yourself. just stick it in the bottle and tada!
thingiverse
free
Cartesian coordinate cross by fx137
...
thingiverse
cartesian coordinate cross as support for 3d design and robot programming. used as helper for euler angle rotations
thingiverse
free
Maja - Cartesian printer in corexy system
...maja - cartesian printer in corexy system
thingiverse
maja - cartesian printer in corexy system.
print field: 150x150x150
Plot
3ddd
$1
PLOTS FOR FLOOR SUPPORT
...plots for floor support
3ddd
триплекс
plots for floor support
turbosquid
$5
plot of land
...squid
royalty free 3d model plot of land for download as skp on turbosquid: 3d models for games, architecture, videos. (1488099)
turbosquid
free
House and plot
...uid
free 3d model house and plot for download as obj and fbx on turbosquid: 3d models for games, architecture, videos. (1279025)
turbosquid
$40
plot-dde.lwo
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
turbosquid
$10
Plots by Cobe
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
turbosquid
$9
Zivy Plot
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
3d_export
$5
vegetable plot
...rt
interior or exterior garden designed in components to be made in waterproof chipboard, with a dynamic design and easy for use
3d_export
$5
cartoon vegetable plot
...lude: -base color -base color with ao -ao -normal opengl -roughness textures format - png textures size 4096 x 4096 px resolution
turbosquid
$60
Plot 1-9.dwg
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
turbosquid
$7
Tile Atlas Concorde 3d Plot
...ile atlas concorde 3d plot for download as max, obj, and fbx on turbosquid: 3d models for games, architecture, videos. (1190262)
Polar
3ddd
$1
Люстра Polar
...люстра polar
3ddd
itre
люстра polar itre
все текстуры вирей
3ddd
$1
Serenissima / Polar chest
...erenissima / polar chest
3ddd
serenissima , polar
serenissima / polar комод и аксессуары
3ddd
$1
Serenissima / Polar bed
.../ polar bed
3ddd
serenissima , polar
кровать с прикроватными тумбами serenissima / polar
3ddd
$1
спальня Polar Serenissima
...
3ddd
polar , serenissima
итальянская спальня polar serenissima, в размере с текстурами.
3d_export
$18
rigged polar bear
...rigged polar bear
3dexport
rigged polar bear
3d_export
$10
polar bear
...polar bear
3dexport
turbosquid
$390
polar bear
...rbosquid
royalty free 3d model polar bear for download as ma on turbosquid: 3d models for games, architecture, videos. (1616264)
turbosquid
$90
Polar Bear
...bosquid
royalty free 3d model polar bear for download as max on turbosquid: 3d models for games, architecture, videos. (1234195)
turbosquid
$25
polar bear
...bosquid
royalty free 3d model polar bear for download as max on turbosquid: 3d models for games, architecture, videos. (1095930)
turbosquid
$10
Polarization Controller
...lty free 3d model polarization controller for download as max on turbosquid: 3d models for games, architecture, videos. (1650264)
Axial
3d_export
$7
Axial fan
...axial fan
3dexport
axial fan
3d_export
$20
industrial axial blower253
...industrial axial blower253
3dexport
industrial axial blower industrial axial blower industrial axial blower
turbosquid
$2
Axial Capacitor
...
royalty free 3d model axial capacitor for download as blend on turbosquid: 3d models for games, architecture, videos. (1501098)
3d_export
$20
Axial compressor 3D Model
...xial compressor 3d model
3dexport
axial compressor jet engine turbine blades gas
axial compressor 3d model qepasol 93563 3dexport
turbosquid
$120
Axial Flow Pump
...id
royalty free 3d model axial flow pump for download as obj on turbosquid: 3d models for games, architecture, videos. (1533995)
turbosquid
free
Axial Wooden Table
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
3d_export
free
collection of axial press fittings for pex pipes
...s fittings for pex pipes
3dexport
this is collection of axial press fittings for pex pipes. the collection includes next models:
turbosquid
free
Collection of axial press fittings for PeX Pipes
...n of axial press fittings for pex pipes for download as blend on turbosquid: 3d models for games, architecture, videos. (1639018)
3d_export
$20
Axial FLux Generator Small Scale Design
...3 rotor design this is a small scale design with a dimension of 11cm approx diameter this is auto desk fusion software compatible
3d_export
$149
axial-flow 9240 combine harvester
...y problem in this model, please do not hesitate to contact us, we are looking forward to continuously dealing with you. markos 3d
Openscad
thingiverse
free
OpenSCAD sphere
...openscad sphere
thingiverse
basic project for openscad.
thingiverse
free
Openscad Football by KySyth
...openscad football by kysyth
thingiverse
openscad not tested
thingiverse
free
Openscad Apple by KySyth
...openscad apple by kysyth
thingiverse
openscad apple = not tested
thingiverse
free
Plugs with openscad by benengel
...plugs with openscad by benengel
thingiverse
plugs with openscad and fontawesome
thingiverse
free
Openscad spirals by mafmuf
...openscad spirals by mafmuf
thingiverse
just fooling around with openscad.
thingiverse
free
Practice on OpenScad by ajensen906
...practice on openscad by ajensen906
thingiverse
a very crude practice on openscad
thingiverse
free
Batteries in OpenSCAD by roman_hegglin
...batteries in openscad by roman_hegglin
thingiverse
common batteries as modules for openscad.
thingiverse
free
OpenScad Propeller by KySyth
...se
trying to make a propeller with openscad = not tested
this is some of the results
added the openscad file but still need work
thingiverse
free
Openscad Cloud by Twanne
...openscad cloud by twanne
thingiverse
openscad cloud.
size can be adjusted
thingiverse
free
Geomag for OpenScad by vicnet
...geomag for openscad by vicnet
thingiverse
openscad file to design geomag things.
Coordinates
3ddd
$1
Coordination Thread Family High Bistro Stool
...istrostool_helix_bumpspec
2048x2048 - highbistrostool_legs_glossy
model's dimensions: 45 cm (h) x 32,5 cm (l) x 32,5 cm (w).
3d_export
$49
forwarder crane coordinate system with harvester head
... in this model, please do not hesitate to contact us, we are looking forward to continuously dealing with you.<br>markos 3d
design_connected
$13
Polygon Crash Pendant Light
...h pendant light
designconnected
coordination polygon crash pendant light computer generated 3d model. designed by sellin, filip.
3ddd
$1
Leica S (typ 006)
...* 4096 poly: without smoothing 78915 with smoothing 605436 coordinates of model:...
3d_export
$45
Low Poly LNG Gas Carrier 02
...emission map. the model is at the center of coordinates high...
3ddd
$1
Ikea Oppland bed
...detailed; elements are either unwrapped or have proper uv coordinates ...
3d_ocean
$20
Feet Keyer
...feet keyer 3docean a script that takes the translate global-world-coordinates and key-frame them regardless of the global control. simply...
3d_export
$15
bed with pillows
...centimeters.<br>sheets, blankets and pillows are made using-marvelous designer. texture coordinates are...
3d_export
$15
bed with pillows
...centimeters.<br>sheets, blankets and pillows are made using-marvelous designer. texture coordinates are...
3ddd
$1
Round stone cladding
...2 variants - with explicit and real world mapping coordinates ...
Function
turbosquid
$1
functional clock
...d
royalty free 3d model functional clock for download as fbx on turbosquid: 3d models for games, architecture, videos. (1378928)
turbosquid
$5
functional door
... model functional door for download as 3ds, obj, c4d, and stl on turbosquid: 3d models for games, architecture, videos. (1483785)
3d_export
$5
multi function box
...multi function box
3dexport
it is multi function box in iges format
3ddd
$1
Fitness Equipament - Functional
...fitness equipament - functional
3ddd
треножер
fitness equipament functional, modeled from real model.
turbosquid
$19
Four function formula
...
royalty free 3d model four function formula for download as on turbosquid: 3d models for games, architecture, videos. (1154985)
turbosquid
$1
functional work table
...yalty free 3d model functional work table for download as max on turbosquid: 3d models for games, architecture, videos. (1198733)
3d_export
free
Multi-functional anaquel
...multi-functional anaquel
3dexport
https://www.dock4all.com/
turbosquid
$12
Multi-Function Knife
... available on turbo squid, the world's leading provider of digital 3d models for visualization, films, television, and games.
turbosquid
$9
function x black coin
...yalty free 3d model function x black coin for download as max on turbosquid: 3d models for games, architecture, videos. (1457828)
turbosquid
$8
Multi-function cylinder mechanism
...lti-function cylinder mechanism for download as ige and sldpr on turbosquid: 3d models for games, architecture, videos. (1223739)
Library
3d_ocean
$5
Library
...library
3docean
book book case library
library
3d_export
$6
library
...library
3dexport
a ready-made model of a library for use in peru
3d_ocean
$5
Library
...library
3docean
book books furniture home home design interior library
home design…
turbosquid
$15
library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1351741)
turbosquid
$9
Library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1433110)
turbosquid
$7
Library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1363568)
turbosquid
$5
Library
...turbosquid
royalty free 3d model library for download as max on turbosquid: 3d models for games, architecture, videos. (1309343)
3ddd
$1
classic library
...classic library
3ddd
library
classic library
3dsmax 2008 vray
3d_export
$10
Library
...library
3dexport
3d_export
free
library
...library
3dexport