Solve COMSOL Spring Deformation with Variable Constraint | Beginner Problem

  • Thread starter Thread starter Fprime
  • Start date Start date
  • Tags Tags
    Beginner Comsol
AI Thread Summary
In COMSOL, users can model a metal spring by fixing one end and applying a variable constraint to the other end to analyze deformation. Instead of manually inputting values, the Parametric Solver allows for defining a parameter that can be varied over a range, facilitating the plotting of deformation results. Users can also export the model as an .m file to integrate with MATLAB, enabling more complex computations and geometry adjustments based on parameters. However, utilizing MATLAB for simulations may present a steep learning curve, as it requires familiarity with coding and trial-and-error methods. Overall, leveraging these techniques can streamline the simulation process and enhance efficiency in modeling spring deformation.
Fprime
Messages
2
Reaction score
0
Greetings.

I'm new to COMSOL and am in the stage where I know what I want done, but I just can't get the software to do it.

Suppose I model out a metal spring, and fix one end of it in place. I want to pull on the other end, and then plot some value relevant to the deformation of the spring. Right now, I can input one value as a constraint in the boundary settings, and that works fine. I get my deformation value, but it's slow and tedious to plug in one value at a time, and wait for the solution.

What I want to do is have COMSOL do this for a range of values, and then plot the resulting values. I know it's possible to put in an expression containing variables in the constraint box, but I can't get it to work.

I hope this is an easy question to answer, thanks for helping a newbie out.
 
Engineering news on Phys.org
Anyone?
 
Since I only used Comsol for EM simulations I don't know the module you use but, maybe you could also define the parameter you want to change within the solver itself. In Solver Parameters, you can define one parameter (which in my case is usually the free space wavelength) and use Parametric Solver. This solves the problem for each value.
e.g.
Parameter name: Lambda
Values: 1540e-9:1e-9:1560e-9
then I write Lambda to the dialog box for the free space wl.


Well, also you can export the whole problem as an .m file, and open it up with Comsol with Matlab, from there on, your whole computation will be a block of Comsol code within any kind of Matlab code.

I use this often, since I need to reinitialize my geometry and mesh due to the parameter. For example, if I take radius of a circle in my geometry as a parameter, the preceding trick will fail, since a change in radius will present a new problem and geometry.

I mean you could define a variable for an initial condition value, like

for radius=10e-6:1e-6:20e-6
...
Comsol code in which "radius" is used as one of the parameters
...
end

this would for every time create a new FEM problem (geometry, boundary conditions, mesh etc.) solve it, and save it if you code it down.

If you can, stay away from the latter technique, since working with the simulation as a .m code has a steep learning curve (not that it is hard though, because it is dependent on trial and error.)
 
Thread 'I need a concave mirror with a focal length length of 150 feet'
I need to cut down a 3 year old dead tree from top down so tree causes no damage with small pieces falling. I need a mirror with a focal length of 150 ft. 12" diameter to 36" diameter will work good but I can't think of any easy way to build it. Nothing like this for sale on Ebay. I have a 30" Fresnel lens that I use to burn stumps it works great. Tree service wants $2000.
Hi all, i have some questions about the tesla turbine: is a tesla turbine more efficient than a steam engine or a stirling engine ? about the discs of the tesla turbine warping because of the high speed rotations; does running the engine on a lower speed solve that or will the discs warp anyway after time ? what is the difference in efficiency between the tesla turbine running at high speed and running it at a lower speed ( as fast as possible but low enough to not warp de discs) and: i...
Thread 'Where is my curb stop?'
My water meter is submerged under water for about 95% of the year. Today I took a photograph of the inside of my water meter box because today is one of the rare days that my water meter is not submerged in water. Here is the photograph that I took of my water meter with the cover on: Here is a photograph I took of my water meter with the cover off: I edited the photograph to draw a red circle around a knob on my water meter. Is that knob that I drew a red circle around my meter...
Back
Top