If you are interested in this tool, please give it a like. If you have used this for something, please give it a rating and leave a comment to let me know what you used it for; I would love to see what people do with it! If you have any questions at all please leave a comment and I will get back to you as soon as I can.
Future versions of this project will be in the form of a FreeCAD macro rather than a libreoffice spreadsheet. Check out the repository on GitHub to see my progress on this (in its infancy at the time of this writing).
Introduction:
This project consists of a Libreoffice Calc spreadsheet that generates optimized spiral torsion springs using social-cognitive optimization, and a parametric FreeCAD file that takes the numbers copied from the spreadsheet and generates a 3D model of the optimized spring. By creating your own parametric CAD file, you can also use this spreadsheet to optimize springs in any CAD software of your choice. The spreadsheet also provides several useful graphs for visualizing spring characteristics and efficiency.
To use this tool, you need to determine the Young's modulus and yield stress of the material you are printing with. Some rough but usable numbers can be found in the technical data sheets published by reputable filament brands such as Prusament and Polymaker, though they do not take into consideration factors such as print speed, print temperature, and nozzle diameter which also effect these characteristics. Here is some advice on determining these parameters:
Young's Modulus (E):
The Young's modulus is a measurement of how elastic the material is, or in other words, how much the material bends or deforms when a certain amount of pressure is applied to it. In Prusament data sheets it is called “flexural modulus”, and in Polymaker it is called “bending modulus”. Polymaker also lists a separate characteristic called simply “Young's modulus”, but this is really either a tension modulus as listed in the Prusament data sheets or a compression modulus. We want to use the flexural or bending moduli because they are a combination of tensile (stretching) and compression moduli, which is what is really happening in a spiral torsion spring. If it is important to you to create springs that store a specific amount of energy very accurately, then follow these steps to find the actual Young's modulus for your specific material printed on your specific printer:
Yield Stress (σ_y):
This is the amount of stress at which the material will leave its “elastic zone” and become permanently deformed. It is used to calculate the C_1 constraint in the spreadsheet which itself is used by the solver to ensure the material's full elasticity (subject to the safety factor, see below) is used. If you want to truly optimize a spring, you need to make sure you are applying close to the full yield stress when the spring is at it's maximum desired range of motion. I currently do not have a way to experimentally derive a material's yield stress, so I just use the numbers provided by manufacturers.
Safety Factor (δ):
This is a factor applied to the yield stress to ensure that the spring stays well within the elastic zone where it can be reliably used. I use a safety factor of 0.75 because that is the number used by the engineers who wrote the algorithm cited in the bibliography.
Distance between Spring Coils (p_0):
This is a useful parameter for two reasons:
A Note on the Included CAD Models:
In previous versions, the spring was formed with a simple circle for the center pad, and by revolving a rectangle around the center axis to make the spring. The problem with this is: that doesn't actually make an accurate spiral! Also, the spiral never emerged smoothly from the center pad, there was always some unused space there that bothered me. The new center pad is actually formed by a spiral itself-- one with a pitch equal to that of the spring at the end of its range of motion. That way when the spring is all the way deformed, it will at every point be the same distance from the center pad as it will from itself. In other words, when the spring is deformed all the way to the point it is designed for, all of the available space in the center is used up by the center pad. Also, the spring is now formed by a genuine spiral, and by sweeping a spring profile normal to that spiral across its length. This eliminates the need for several calculations from the previous versions, which needed to put the spring profile within the center pad in order to join the two parts.
The parameter r_C used to denote the radius of this center pad, and now it denotes the inner radius of the center pad spiral. So it still basically controls the same thing. The parameter r_P used to be needed to determine how far from origin the center of the spring profile should be, so that it will begin within the center pad and smoothly emerge from it. Then r_E would the the point along this spiral where the actual spring begins (the point at which the spring had fully emerged from the center pad). This is no longer necessary, now the spring profile simply begins at r_E. The old n_P used to denote the number of revolutions from the spring profile, and has been changed to n_R, the number of revolutions of the spring at rest since there is no longer a need for superfluous revolution.
Old model:
![]()
New model:
![]()
New model at maximum deformation (experimental version):
![]()
How to Optimize:
You can theoretically use this spreadsheet to optimize a spring in several different ways, but here is a step-by-step guide to what will probably be the most common form of optimization, that of maximizing the spring constant (stiffness):


Limitations:
Bibliography:
This paper explains how print temperature and speed changes the material properties of 3D printed objects. This is where I got my initial numbers for the Young's modulus and yield stress:
Hsueh, Ming-Hsien & Lai, Chao-Jung & Wang, Shi-Hao & Zeng, Yu-Shan & Hsieh, Chia & Pan, Chieh-Yu & Huang, Wen-Chen. (2021). Effect of Printing Parameters on the Thermal and Mechanical Properties of 3D-Printed PLA and PETG, Using Fused Deposition Modeling. Polymers. 13. 1758. 10.3390/polym13111758.
This is a paper on a different optimization algorithm for 3D-printed coil springs. I tried getting this to work in a spreadsheet for a while before giving up and deciding to create my own from the ground up. I did use a couple things from this paper, including my C_1 constraint. I mostly used the same terminology from this paper as well:
Scarcia, Umberto & Berselli, Giovanni & Melchiorri, Claudio & Ghinelli, Manuele & Palli, Gianluca. (2016). Optimal Design of 3D Printed Spiral Torsion Springs. V002T03A020. 10.1115/SMASIS2016-9218.
I also used some of the equations from omnicalculator and benefited greatly from its explanation of the Archimedean spiral.
Big thanks to Symbolab for helping me double-check my algebra.
Change Log:
10/7/2025: Fixed this issue with the non-articulated model
The author marked this model as their own original creation.