I have a spring that I need to compress 80mm. To do so requires approximately 15kg of force. To compress the spring, I will have the spring in front of a piston head. The piston head will have a protrusion holding 6mm(diameter) by 3mm neodymium magnets. When the solenoid is powered, the magnets will be attracted to the solenoid, which will push the piston head, compressing the spring. The piston head will also have an o-ring sealed with the cylinder, I am not sure how much extra force would be needed to overcome the friction of the seal. A full cycle(cylinder head recoiling to returning to start point) needs to be achieved in 50 - 100ms.

How would I design a solenoid(how many turns of wire, what gauge wire etc...) that can provide 15kg force to compress the spring 80mm? The dimensions of the solenoid cannot be more than 40mm wide or 80mm long(shorter is better) so it fits in my project. Ideal current rating should be around 5A as I have 5Ah battery. I don't mind if the solenoid is cored or core-less. I also have a 12mm diameter soft iron rod but can buy a different core if need be. My budget is around 40 dollars to make the solenoid. I can go over the budget though.

Also, if there is a ready made solenoid that does the job with the necessary dimension, I would be happy to buy that.


  • 2
    \$\begingroup\$ (Ambitious - any timing constraints?) current rating should be 5A as I have 5Ah battery current deliverable and charge deliverable are not related directly. (Where would the hour come from?) \$\endgroup\$
    – greybeard
    Aug 7 at 12:01
  • 1
    \$\begingroup\$ This is likely impossible. Solenoids are capable of generating powerful forces, but the stroke lengths for those forces are VERY short, like a few mm's. When you see a solenoid online with a 20mm stroke that generates a few kg force, that force is only at the very end of travel. At the beginning of travel the force is nearly zero. You will see this clearly if you look at the datasheets for some commercial solenoids. \$\endgroup\$
    – Drew
    Aug 7 at 14:54
  • 1
    \$\begingroup\$ A drawing or sketch of the arrangement would be helpful. Would a linear actuator mechanically connected to the piston head be viable? What's the piston head's area/diameter? \$\endgroup\$
    – greybeard
    Aug 7 at 15:10
  • \$\begingroup\$ I added a diagram. The solenoid can have a core with which the magnets are attracted to, or it could be coreless and the magnets move inside the solenoid, a bit like a solenoid valve. Whichever works best I am fine with as long as it fits the aforementioned specifications. \$\endgroup\$
    – Yassin
    Aug 7 at 15:48
  • \$\begingroup\$ Ouch - about 150 N, .08 m 14 times a second - I get 170 W mechanical, and I suggest to start assuming overall eta below .5 rather than above: electrical power 300 W up. Challenging in 40⌀×80 mm³. Did you check out engineering@SE? \$\endgroup\$
    – greybeard
    Aug 8 at 13:20

1 Answer 1


Not going to happen with a solenoid (distance much greater than diameter).

Good news is the sketch looks like any old linear actuator could be used.

  • \$\begingroup\$ What do you mean by distance much greater than diameter? The design can be altered as well, placing magnets closer to solenoid by extending the magnet housing protrusion. I would rather a solenoid than a linear actuator. \$\endgroup\$
    – Yassin
    Aug 7 at 16:15
  • \$\begingroup\$ Linear actuators are also quite slow and I need this to be fast(i.e recoil spring 70mm in 1/30th of a second). It also doesn't have to be a solenoid, it can be an electromagnet with an iron core. \$\endgroup\$
    – Yassin
    Aug 7 at 16:33
  • \$\begingroup\$ Also, after doing more research, can a linear actuator even "disengage" to allow the spring to push it forwards or will it just be stuck in the same position? \$\endgroup\$
    – Yassin
    Aug 7 at 16:46
  • \$\begingroup\$ @Yassin A linear actuator with a catch mechanism could be released in mere ~ms. How long does it take to reset between releases? \$\endgroup\$ Aug 7 at 16:59
  • \$\begingroup\$ @Yassin need this to be fast - recoil spring 70 mm in 1/30th of a second is in contradiction to There isn't really any timing constraint, and the first line of the question states 80 mm. Please review and edit your question to invite useful answers without need to drill down comment chains not only on the question, but on answers, too. \$\endgroup\$
    – greybeard
    Aug 7 at 18:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.