Quantcast
Channel: Latest Discussions - COMSOL Forums
Viewing all 26192 articles
Browse latest View live

python for comsol

$
0
0
I was wondering if one can use Python or VBA (without the LIVE link EXCEL option) to control COMSOL, rather than Java or Matlab.

--
NAFTALI HERSCOVICI

modeling a 3d electromagnet in a stationary study

$
0
0
Hey i am having som trouble.

it is giving me this error:
and i can't figure out why!
i tried to use and modify the "Multi_Turn Coil Winding around a Rectangular Ferromagnet cleared.mph" to help me make it. i modified the size and use it in a stationary rather than frequency domain so it fits my needs. but i can't seem to compute it.

im new in comsol, so it might just be a brain fart.

the error i get is:
Division by zero.
- Function: /
Failed to evaluate variable.
- Variable: comp1.mf.Jey
- Defined as: ((comp1.mf.ICoil_1*comp1.mf.mtcd1.eCoily)*N)/comp1.mf.mtcd1.area
Failed to evaluate variable.
- Variable: comp1.mf.Jy
- Defined as: comp1.mf.Jiy+comp1.mf.Jey
Failed to evaluate expression.
- Expression: d((comp1.mf.d*(-comp1.mf.Hx*comp1.mf.testcurlAx-comp1.mf.Hy*comp1.mf.testcurlAy-comp1.mf.Hz*comp1.mf.testcurlAz+comp1.mf.Jx*test(comp1.mf.Adepx)+comp1.mf.Jy*test(comp1.mf.Adepy)+comp1.mf.Jz*test(comp1.mf.Adepz)))*(dvol),{test@24})

the file is to large to upload it here. so i put it in my google drive at:
drive.google.com/open?id=0B52pVuxc2-oFU1FDNnZXV19aTms

thank you in advance.

How to couple two physics for linear magnetostriction

$
0
0
Dear Researchers,
I am trying to implement linear magnetostriction in comsol as suggested in this link: www.comsol.com/paper/coupled-s...gnetostriction-in-comsol-6357.
I am trying to couple both magnetic field (mf) module and solid mechanics (solid) module in comsol 5.1.

Now my problems are:
(1) I want to include the strain dependent magnetic field term in the AC/DC module. I was trying to include that strain dependent term in the initial field description as:
A = (-lambda_s*solid.eXX*x + lambda_s*solid.eYY*y)*z_hat so that I would have a strain dependent magnetic field. Is there any better way to include that strain dependent magnetic field term?

(2) Secondly, I have a magnetic field dependent initial strain term in the solid mechanics physics module. But the problem is, I want to couple this physics together, how can I do that? It seems that comsol is always solving the magnetic filed calculation first and then solving the solid mechanics physics.

I am eagerly waiting for your response.

Thank you.
Khalid

Time Stepping ( solve node)

$
0
0
please guide me
in comsol 3.5a:

i want to use General PDE form for modeling of a discharge.
the Dimension is 1D ; x=[0,1] mm
i have 8 general pde forms for "Poisson equation, ions density and electron energy"

in x=0 , potential=V0*cos(2*pi*Freq*t)
in x=1 mm, potential =0

Freq= 13.6e6 MHz

I build the model very exactly.
my problem is in Time Stepping ( solve node)

if I run model for 150 cycles , my results are Acceptable. ==>range(0,(1/13.6e6-0)/(24-0),150/13.6e6)
but if I run model for 1 cycle, my results aren't Acceptable.==>range(0,(1/13.6e6-0)/(24-0),1/13.6e6)

I know when I would choose 1 cycle ,The calculations are repeated until convergence is achieved !
so you do not have to select 150 cycles.

So what's the problem?

thanks

2D results as initial conditions to a 3D model

$
0
0
Hi,

I'm doing a simulation of moisture and heat distribution on a soil profile.
On the first step I've made a 2D simulation of my soil that is a rectangle.
Now I have a heat exchanger buried in my soil and therefore, I have a "z" axis to add to my model. Assuming that the changes in the soil occurs just on depth direction, I want to take the results of my 2D simulation and put as initial conditions to my extruded 3D soil domain.
I've searched here but didn't found how to do this. Any tip for me?

Another problem, the mesh won't be the same. How to solve this?

Thanks in advance.

PDE: variables with different units

$
0
0
Hi!

I am new with Comsol. I'm studying an hydro-thermal system of equations based on different variables (water pressure, grade of saturation and pressure on the solid skeleton).

Using PDE with constant coefficient, how I can insert three variables with different units in the version 5.3?

Hope someone can help me.
Thank you,
Cristina

2-way FSI model with automatic re-meshing stops with inverted mesh elements

$
0
0
Hello everyone,

I am trying to simulate the expansion of a filled magma chamber due to the injection of new magma (density= 2300 kg/m^3, dynamic viscosity= 1e5 Pa*s). I am interested in studying the flow of the magma in the chamber while it expands the chamber walls and deform the surrounding elastic material (Young´s modulus=30e9 Pa, density=2400 kg/m^3, and Poisson´s ratio=0.25).
This is a 2-way FSI problem. I am using an axisymmetric domain (see image) and the automatic re-meshing technique mainly to improve the mesh of the fluid of the magma chamber, subjected to a strong expansion.
The analysis always stops due to inverted mesh elements (the inverted element are those along the fluid-solid interface), no matter if I improve the mesh with smaller elements at the interface or if I increase the time steps. I reduced the tolerance to 0.0001, but doesn´t help. I can control the quality of the mesh by using the mesh quality as condition for re-meshing. I set the threshold for the minimum mesh quality at 0.5, but it doesn´t help. The solution doesn´t converge (and I still get inverted mesh elements) even if the mesh doesn´t look bad at all.

Does anyone have any idea about how to improve the model to solve this problem, or about what could be the reason for the elements' inversion?

Any help is very appreciated!
Thank you,
Erika

Dispersion Curve in plate

$
0
0
Hello, everyone
I am studying elastic waves and metamaterial which exhibits some extraordinary phenomena.
What I am curious about is how to obtain the dispersion curve of the lamb wave.
As I refer to this video (www.youtube.com/watch v=HMgdXMNigCA&t=292s), there are some questions.
1) As far as I know, the lamb wave propagates through the plate while the "verticial displacement" changes.
Thus, I can't understancd how we get the dispersion curve in 2D.
2) Let's assume the width and height of the rectangular introduced in the video are 10[mm] and 100[mm], respectively. Then what is the thickness of that plate?

Thank you for reading my writing.

Importing odd shape (DEM and XYZ available)

$
0
0
Hi All,

I'm trying to import an oddly shaped blob (a lat lon height description of a flow field). I have the data in both DEM (a square image with NoData values) and in a columnar ascii text file that only contains the data points that exist [lat lon H].

For the DEM, I import with Definitions->Functions->Elevation, but the nodata values result in my desired flow field surrounded by zeros (or whatever I put in for the missing data value). The Parametric Surface created from this includes all of these zero values instead of just the flow field (the flat blue part on the "interp" figure), and the parametric surface is thus *very* bad ("parametric" figure ... from 1000 knots). Is there a way to parameterize only the blob I am interested in?

NaNs as the "missing data" value make a nice plot in the Definitions Elevation Plot, but fail in the Parametric surface solver. I've tried to make missing data value a negative number, such that I could split the volume at zero, and delete the negative values later, but the Parametric surface is so bad with all the noData values that it won't be useful.

Importing with the ASCII file also interpolates in between the fingers of the flow field ...

How can a eliminate the area of NoData before making a Parametric Surface? (The flat blue part in the image).

simulation of levitating magnet moving due to induced forces

$
0
0
I've been doing a lot of reading on this forum and somehow my questions have only been partially answered:

1.) Can MEF physics be used with a time-dependent solver if it is coupled with a physics module that does allow for a time-dependent solver? In the context of my problem: there is a magnet moving horizontally above an aluminum plate, which induces eddy currents that impart forces on the magnet; can I couple MEF with the Moving Mesh and Global ODE modules and use the time-dependent solver to simulate how the magnet's trajectory would change due to the induced forces?

2.) If that could not be done with MEF, would it work with MF? I know that you need MEF for eddy currents, but would the induced forces still be simulated in MF?

I would really appreciate any sort of help with this. I can't upload my model since it's too big, but you can download it here drive.google.com/file/d/0B7-aY...J1OHNlYVk2T0E/view?usp=sharing

characterization of piezoelectric PVDF films

$
0
0
Dear all,
I'm trying to model the electromechanical behaviour of a PVDF (Polyvinylidene Fluoride, a polymer) commercial film. I need the coefficients included in the elasticity matrix, the piezoelectric coupling matrix and the permittivity matrix.
Neither the revendor provides this kind of characterization of PVDF film nor I can easily find these coefficients in literature. How can I solve this problem? Did anyone studied similar systems?

It would be very appreciated if you could give me some hints.

Thank you.
Lucia

Coupling magnetic field (no current) with solid state BH curve

$
0
0
Hi All,

I want to model magnetostriction phenomena. I found an example (nonlinear_magnetostriction.mph) where the magnetic field is created by a coil (current density J0) and which uses Magnetic Field (mf) physics equations. In my study I use a permanent magnet, and so I have to use Magnetic Field No Current (mfnc) equations to solve my problem.

Solving the magnetic part alone is not a problem, when I use a BH curve of my magnetostrictive material or when I use only a constant permeability value µr.

I add the solid mechanic physics equation (linked to the magnetic field), only for my magnetostrictive material.
I am perfectly able to find a solution when I use a constant µr value to define “magnetically” my magnetostrictive materials.

But when I change the magnetic definition of my material to a BH curve I have the following error:

Failed to evaluate variable.
- Variable: mod1.mfnc.Hz
- Geometry: 1
- Domain: 1
Failed to evaluate variable.
- Variable: mod1.mfnc.mfc3.minput_magneticfieldz
- Defined as: mod1.mfnc.Hz
Failed to evaluate variable.
- Variable: mod1.mfnc.normB
- Defined as: (mod1.mat4.BHCurve.BH(((unit_m_cf*sqrt(((mod1.mfnc.mfc3.minput_magneticfieldz^2)+((mod1.mfnc.mfc3.minput_magneticfieldy^2)+(mod1.mfnc.mfc3.minput_magneticfieldx^2)))))/unit_A_cf))*unit_T_cf)
Failed to evaluate expression.
- Expression: subst(mod1.mfnc.normB,mod1.mfnc.HX,(unit_A_cf/unit_m_cf))
Failed to evaluate expression.
- Expression: nojac(((unit_m_cf*(subst(mod1.mfnc.normB,mod1.mfnc.HX,(unit_A_cf/unit_m_cf))-mod1.mfnc.normB))/unit_A_cf))
Failed to evaluate variable.
- Variable: mod1.mfnc.normDiff
- Defined as: nojac(((unit_m_cf*(subst(mod1.mfnc.normB,mod1.mfnc.HX,(unit_A_cf/unit_m_cf))-mod1.mfnc.normB))/unit_A_cf))
Failed to evaluate expression.
- Expression: (mod1.mfnc.normDiff*mod1.mfnc.HZ)

The error is concerning the variables: mod1.mfnc.Hx, mod1.mfnc.Hy or mod1.mfnc.Hz with no rules.

I have already done some tests:
- Even if the solid mechanics has no linked to the previous magnetic calculation, I have the error.
- If I add a heat transfer instead of the solid mechanics, I am able to find the magnetic solution.

I am using Comsol 4.2a.
The BH curve that I use is the inverse of the HB curve from the magnetostrictive material used in the nonlinear magnetostrictive example.

What could I change to find a solution with a BH curve?

Initial Values setting during parametric sweep calculation

$
0
0
Hi all,

When I was doing parametric sweep in a stationary solver, I found that once the "stationary solver" is started, the initial value for every parametric step is defined by solution of the last parametric step. But in my case, I want to custom the initial values during the parametric calculation steps using solutions i get from other solvers so that the convergence can be faster.

Is that possible in comsol ?

Thank you guys in advance!

Chen Bin

Is it possible to model MAGNETOSTRICTIVE materials in comsol, just like for the piezoelectric materials?

$
0
0
Dear colleagues,

In comsol, there are predefined models for the piezoelectric materials. For magnetostrictive materials, they have similar properties as the piezoelectric counterparts. However, a predefined physics for them is not available till today. Implementing the strong coupling magneto-mechanical relationship seems to be not easy. Does anyone have experience on this topic? Could you please share your skills on the magnetostrictive modeling using comsol?

For the modelers at comsol, could you please give some instructions?

Thank you very much.

A.R.

*Now Available* COMSOL Multiphysics 5.2

$
0
0
Hello COMSOL Community,

COMSOL Multiphysics(R) and COMSOL Server(TM) 5.2 are now available for download.

Install now to access the most stable and finished product we ever released.

Version 5.2 can be downloaded at:
www.comsol.com/product-download

Read the full release highlights at:
www.comsol.com/release/5.2

*Highlights of New Features and Tools Available in Version 5.2*

- COMSOL Multiphysics, Application Builder, and COMSOL Server
Streamlined workflow in the Application Builder with Editor Tools for bringing any model parameter, physics setting, and results such as numerical data and plots into the user interface of an app with a few mouse clicks. Enhancements to user experience with the customization of graphic toolbar buttons, plot while solving, dynamics updates of graphics, improved copy-paste between applications, and more. A more powerful COMSOL Server™ with applications launching up to five times faster, the ability to reconnect to running applications, and launch of single dedicated applications upon login. More robust license management with better handling of lost connection and licenses released during a session.

- Apps
More than 50 app examples demonstrating the power of the Application Builder for electrical, mechanical, fluid, and chemical simulations.

- Geometry and Mesh
Mesh Parts are introduced making it easier to import surface and volume meshes for use in geometry building. More robust tetrahedral meshing. An additional geometry operation, Partition Domains, to extend the reach of hexahedral meshing.

- Mathematical Modeling Tools, Studies, and Visualization
Annotations for displaying customized texts and results in 2D and 3D plots. Users can choose to store only a selected part of the solution for postprocessing purposes. PARDISO solver for clusters. Improved FFT studies. Residual operator that can be used to plot the residual in each point in space to get an intuitive visualization of where the error is largest.

- Electrical
The AC/DC Module features an effective nonlinear constitutive relations formulation for approximating nonlinear magnetic materials in the frequency domain. Shared library files can be used to create magnetic materials that include hysteresis and irreversible effects. Smith plots are available in the RF Module.

- Mechanical
Shared library files can be used to create nonlinear structural materials. Contact robustness improvements in the Structural Mechanics Module for curved surfaces and small relative displacements. The Heat Transfer Module has a symmetry plane for surface-to-surface radiation and external temperatures for thin layers. The Acoustics Module includes octave and 1/3rd octave plots.

- Fluid
Laminar three-phase flow multiphysics interface in the CFD Module based on the phase-field method. More turbulence support for rotating machinery and a free surface tool for frozen rotor studies. With the Pipe Flow Module users can model compressible flow in pipes and expansion and contractions due to sudden changes in the cross-section area of the pipes.

- Chemical
The Chemical Reaction Engineering Module allows catalytic particles of different particle shapes (spheres, cylinders, flakes, and user defined based on area and volume). The Corrosion Module supports the modeling of thin beam structures.

- Multipurpose
The Particle Tracing Module supports model particle-matter interactions for simulating high-energy physics and powerful particle counters for counting the number of particles in domains and on boundaries.

Enjoy COMSOL Multiphysics and COMSOL Server 5.2!
Valerio

--
Valerio Marra, Ph.D.
Technical Marketing Manager
COMSOL, Inc.
+1-781-273-3322
valerio@comsol.com

Modeling Magnetostriction - mod1.Azy variable

$
0
0
Hello
I'm modeling magnetostriction in a laminated core in 2D. I have studied the '''non linear_magnetostriction'' model in COMSOL and have compare my model with that. In my model everything looks alright but the model does not run and returns the following error:

Fail to evaluate variable Jacobian.
- Variable: mod1.Azy
- Geometry: 1
- Domain: 2 ,5 , . . .
-Feature: stationary solver 1(sol1/s1)

Anybody has any comments?
Regards
Hamid

What's wrong with Nickel Steel Supersquare 80?

$
0
0
Hello everyone.

I just read the blog "Modeling Magnetostriction Using COMSOL" and downloaded the model "Nonlinear Magnetostrictive Actuator and Sensor".

I replaced the material "soft Iron" by "Nickel Steel Supersquare 80" and run the model again. Then error was shown.

Can anyone tell me why this material can not be used?

Thank you.

Simulation of inverse magnetostriction (Villari effect)

$
0
0
Could someone please help me with simulation of inverse magnetostriction? The general ideal is to apply stress (spatially non-uniform) to a magnetostrictive pillar and calculate the resulting magnetization.

Simulation of magnetic field generated by AC current through Multiturn coil and biasing with permanent magnet

$
0
0
Dear Sir/Madam,
I want to simulate the magnetic field which is generated by Multi turn coil by supplying alternating current in the presence of biasing arrangement with permanent magnet. this magnetic field, I want to utilize for magnetostrictive actuator. Can you help me in this regards? like which module I have to select in 2D axissymmetry.

I studied the linear magnetostriction paper and nonlinear magnetostriction paper available on this topic. but they took one coil for generation of magnetic field. But I have to take one coil with mutliturn, alternating current and biasing arragement with permanent magnet.
Thanks and Regards

Acoustic Pressure Variation

$
0
0
Hi all,

I'm simulating a membrane structure.
I wish to check membrane displacement as a function of acoustic pressure.
I just checked it is possible in acoustic module...
Being a new COMSOL user can anyone please let me know what Physics and studies should in use...
or can point to relevant thread if known....

Thanks in advance....

--
Mack
Viewing all 26192 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>