Latest Discussions - COMSOL Forums https://www.comsol.com/forum/ Most recent forum discussions Mon, 17 Jun 2024 16:29:22 +0000 COMSOL Forum: Latest Discussions https://www.comsol.com/shared/images/logos/comsol_logo.gif https://www.comsol.com/forum/ Solve a PDE with a 1D domain with several equations that must be satisfied https://www.comsol.com/forum/thread/341171/Solve-a-PDE-with-a-1D-domain-with-several-equations-that-must-be-satisfied?last=2024-06-17T20:51:37Z <p>I am trying to solve a 1D problem on a domain of length L with the following PDE and a series of additional equations (P is the dependent variable):</p> <p><img class="latexImg" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAALwAAAArCAQAAABoIyrbAAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAAAHgAAAB4AJ31WmAAAAAHdElNRQfoBhEQIiTWsfeUAAAFWElEQVRo3uWb4ZWjOgyFP+15DbgFt8CW4CmBLcFbAlMCKSEpYVJCUkIoYShhKUHvR4BgMBMSnJ2dzOXkBIhBRjaydKWIEkIctdb8dXyW3M+CDBUvHssRi2OjFYjF9z9utGlbAFS6T9iJkdxvAe03crJ2z/COafdLtDvftjphlXRbXO6zb4MZLycafWn3S9BXADlg9OdgdmZkuks59HG5z47/BvsbhjbW9d+b4ApHQiPzgdwnx0DxI6udAYgDQqtrUi+BMbnPj4Hi26X0SMaxP+lgcPQQROU+P/olLrssmngOnBSl++5bOfK0i0xc7vNv3ZflD64/maNs25/LoHmZ1uuYk/v824924hfUGr7ox6iFR5ukL1xU7nfADwAx+OCBMxrd83ALPyv3G+BH+8DhzM45e+qWajjDxScehjm53wBnxTftBwDx0PruNUO1G6ymVfyc3O+Adll777wVLO99CO/QnjowqRfWebnfYev8+F9sBRosOb86okqP8puDvAIZ5kyTJUZU7hzEU/19Ek0KdumfvOdqxODIOI6NiVgchv2jKNs5uZGWjkw3Zz7njAur051bx/NIhse0BnADFPoKYij1d5JnzWh6PX72K7fYKBne+n2P4ke/vodn7rj/lkMfyhlKtl0Mgwujmbvun1PiyNmeZTxGSYmjW0VhOwi0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S07+TZ93FJdZfmpxOvxR/9UnzF+1PQVQAAAC10RVh0aWNjOmNvcHlyaWdodABDb3B5cmlnaHQgQXJ0aWZleCBTb2Z0d2FyZSAyMDExCLrFtAAAADF0RVh0aWNjOmRlc2NyaXB0aW9uAEFydGlmZXggU29mdHdhcmUgc1JHQiBJQ0MgUHJvZmlsZRMMAYYAAAAhdEVYdHBzOkhpUmVzQm91bmRpbmdCb3gANTV4MTErMjc4KzYzODAueWoAAAAedEVYdHBzOkxldmVsAFBTLUFkb2JlLTIuMCBFUFNGLTIuMEH5MxMAAAAASUVORK5CYII=" /></p> <p><img class="latexImg" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEsAAAArCAQAAACas707AAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAAAHgAAAB4AJ31WmAAAAAHdElNRQfoBhEQIiWhtscCAAACoklEQVRYw8WY63GrMBCFv72TBtSCWlALSgmkBFogJeAS7BKSEkwJpgS7hFDC3h+2QCLgOLalLOOxHog57B6t9iBKGRPPSU83310CltRYOiyejfbJaGy9fo5tzX5R4S4twxETzTiU+tK2fHAIsyVgHdiP7ZY2mqlR7NgzaJh9KRDDDTGnfNR2Md90EHDndgFYEWPOUGKI3dSRCkK/ACyx1ECHi0GAWCx9NFDRswvvkptZjkPgDzV7DkvMwrBlP22HzN4Sy563kT8DfvQHOAZqCb2dxp7L7Kvt5B2FCqUae0c+1tb9y+orQ53wyTGEDfCNWYllhYWDGamnEHpIt0A5WMPld/ZPDWwiyIOueis3t46BS1iO4RD6iVn5s/wbW4EBS8Vb8I60WCxIy265qrhUENKO3nsfp9r5yD0mBo+j0+5Xy5LkVicBMBzTkXLXRPkTET0BsOx096t3fJpNsHrSYxQq3fzyac+HpamnkIY/8lQCC+gnb4mF2yvv51ucIIaotq7X9p84zOLEteT4EKw+VI5SrR8LVKszT4QVJ4T2XP9g4nr7oRx/17J5lu8By4mGJ+1AlXtXptwCK55+vitjk2aFWw+eBquwtBOw2B8e363BeqrNuHC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qlsuWgmdGyDtNLgFkjZ70WB39e9e8zCRNKorHVYshaRYStCGwSdOcvEUZGeKw/txRpKKJcNRigcMKf//cFinfflNnxzK7KZ9gL49iw3fr74q5zPlVw2Qtzxe3t+kvmVS/gHz5WeUY6c+5QAAAC10RVh0aWNjOmNvcHlyaWdodABDb3B5cmlnaHQgQXJ0aWZleCBTb2Z0d2FyZSAyMDExCLrFtAAAADF0RVh0aWNjOmRlc2NyaXB0aW9uAEFydGlmZXggU29mdHdhcmUgc1JHQiBJQ0MgUHJvZmlsZRMMAYYAAAAidEVYdHBzOkhpUmVzQm91bmRpbmdCb3gAMTYzeDEzKzIyNCs2MzbazlnzAAAAHnRFWHRwczpMZXZlbABQUy1BZG9iZS0yLjAgRVBTRi0yLjBB+TMTAAAAAElFTkSuQmCC" /></p> <p>Could someone help me solve it (?).</p> <p>Thank you very much, Andres</p> Mon, 17 Jun 2024 16:29:22 +0000 4.2024-06-17 16:29:22.341171 Stationary laminar flow driven by buoyancy, in bigger scale. https://www.comsol.com/forum/thread/341163/Stationary-laminar-flow-driven-by-buoyancy-in-bigger-scale?last=2024-06-17T11:46:21Z <p>Hello everyone!</p> <p>I have problems with buoyancy stimulations. I downlaod the case file named "buoyancy_air.mph" from COMSOL Blog. In this case, there is just a cube box whose length is 0.1m, 2 opposite temperature boundaries to transfer heat, left boundaries are insulation, and fixed by air. Suerly, it works well.</p> <p>But the problems came after I changed the length to 0.5m, then it couldn't converge. Finer mesh, other bigger scales failed too. The warning pop-up message said it reached maximum number of iterations.</p> <p>I guess there is somthing wrong if I keep the same settings when the scale is becoming bigger. However, I didn't find the key. This question has puzzled me for weeks, just like a ghost in quantum state. I want to underatand it to simulate buoyancy in architecture, which needs a big scale.</p> <p>The source file and introductions is at "https://www.comsol.com/model/buoyancy-flow-in-air-53441".</p> <p>Thank you if you have some advices. I will be apperciated if you are interest to have a try follow the above steps.</p> Mon, 17 Jun 2024 11:45:41 +0000 4.2024-06-17 11:45:41.341163 How to define recursive functions similar to loops in the components of COMSOL https://www.comsol.com/forum/thread/341161/How-to-define-recursive-functions-similar-to-loops-in-the-components-of-COMSOL?last=2024-06-17T13:16:32Z <p>I want to define a value that changes over time, which requires calling the value of the previous time step. The variable formula is as follows: d(t)=d(t-1)*t+4. At present, I still haven't found a solution, and I hope you can provide guidance. Thanks</p> Mon, 17 Jun 2024 11:35:50 +0000 4.2024-06-17 11:35:50.341161 How should I define the electrode area? https://www.comsol.com/forum/thread/341151/How-should-I-define-the-electrode-area?last=2024-06-17T08:50:24Z <p>I define the electrode area using the nodes on the electrode surface, but during the calculation process, not only the zinc, which serves as the anode, corroded, but the iron, which serves as the cathode, also corroded <strong>(I didn't even define the oxidation reaction for iron)</strong>. I think it's because the deformed geometry couldn't recognize the zinc area (as shown in my diagram), so I remodeled it using an electrode method, but the iron still corroded. Therefore, my question is <strong>how should I accurately define the electrode area</strong>. Thank you!</p> Mon, 17 Jun 2024 08:50:24 +0000 4.2024-06-17 08:50:24.341151 Reaching a steady state with a time dependent (periodic) heat source https://www.comsol.com/forum/thread/341141/Reaching-a-steady-state-with-a-time-dependent-periodic-heat-source?last=2024-06-17T07:15:00Z <p>Hi,</p> <p>I am pretty new to COMSOL. To do my simulation, I am looking for a feature to calculate a steady state that is reached when providing a periodic boundary condition. In detail, the boundary condition is a heat source.</p> <p>I found a similar question (<a href="https://www.comsol.com/forum/thread/27146/steady-state-solutions-with-periodic-waveforms?last=2012-03-21T17:42:12Z">Link</a>), but this is already 10 years old and neither is answered nor does it help me.</p> <p>My current workaround would be to do multiple study steps as described <a href="https://www.comsol.com/support/learning-center/article/Solving-Transient-Models-That-Have-Inconsistent-Initial-Values-50081">here</a>. So first doing a stationary study and afterwards a time dependent study with the periodic heat source but the initial condition comes from the stationary study. For this, I have to separate the boundary conditions for the two studys using the "Modify physics tree and variables for study step" in the settings of the study. The boundary condition for the stationary study hast to be a constant value, because there must not be a time dependency.</p> <p>I still have to obtain the constant value from the periodic study step (doing the rms calculation of the periodic function -> is it possible to do it in COMSOL by a function?). The overall workaround is not efficient. I am thinking about the steady state calculation like it is available in PLECS Blockset. This would be the perfect solution. Can someone help me with that?</p> <p>Thank you very much!</p> <p>Regards, Niklas</p> Mon, 17 Jun 2024 07:15:00 +0000 4.2024-06-17 07:15:00.341141 Exciting a circular waveguide with HE11 mode https://www.comsol.com/forum/thread/341121/Exciting-a-circular-waveguide-with-HE11-mode?last=2024-06-16T19:00:13Z <p>Hello everyone. A short (and hopefully simple) question. How to excite a circular waveguide with HE11 mode? Because there are onle TE amd TM modes for a port boundary condition.</p> Sun, 16 Jun 2024 18:06:20 +0000 4.2024-06-16 18:06:20.341121 Importing dxf file using Java https://www.comsol.com/forum/thread/341111/Importing-dxf-file-using-Java?last=2024-06-16T17:23:43Z <p>Hi there,</p> <p>I'm attempting to use Java code (in Python) to import a DXF file into COMSOL. Everything is working well until I try to utilise a feature from the COMSOL programming manual. It can be found on page 325 (PDF page version 6.2) under the title "Import DXF".</p> <p>I have successfully created my import within the geometry, and upon saving my model and checking it in COMSOL, everything appears correctly. However, I want to adjust my Import Options in COMSOL from "Solid" to "Do not knit". According to the manual, this option is referred to as "convert", which can be set to "solid", "curve", or "off". When I attempt this, I receive an error indicating that this property does not exist.</p> <blockquote> <p>com.comsol.util.exceptions.FlException: Exception: com.comsol.util.exceptions.FlException: Unknown property Messages: Unknown property. - Property: convert</p> </blockquote> <p>I suspect this issue is related to the Java code, as I have successfully used other features from the manual such as "repairgeom" and "selresult", which are functioning correctly.</p> <p>Could you please review this and assist me?</p> <p>Kind regards, Mohammad</p> Sun, 16 Jun 2024 17:23:43 +0000 4.2024-06-16 17:23:43.341111 Magnet - Magnetic and Electric Fields https://www.comsol.com/forum/thread/341102/Magnet---Magnetic-and-Electric-Fields?last=2024-06-14T20:12:16Z <p>The below post is related to an <a href="//www.comsol.com//forum/thread/30224/magnet-magnetic-and-electric-fields">archived discussion</a></p> <hr /> <p>Hello,</p> <p>I am trying to create a stationary magnet within the Magnetic and Electric Fields setting. I have tried using Ampere's Law and Current Conservation for each pole of the magnet, but keep getting a singular matrix error.</p> <p>I have seen lots of examples of how to create magnets in the (MF) setting, but I can't figure out how to create it in (MEF).</p> <p>Any recommendations would be greatly appreciated!</p> <p>Thanks, Tesla</p> Fri, 14 Jun 2024 19:26:38 +0000 4.2024-06-14 19:26:38.341102 Manually defining the Periodic Boundary Condition in COMSOL https://www.comsol.com/forum/thread/341091/Manually-defining-the-Periodic-Boundary-Condition-in-COMSOL?last=2024-06-14T18:42:26Z <p>In COMSOL while applying the Periodic Boundary Condition(PBC) it is necessary to select edge or boundary for solid continuos surfaces, but my case model domine is dicreate elements so i am looking for manually applying the PBC on descreat points. Is is possible to apply? if then please give the idea</p> Fri, 14 Jun 2024 18:42:26 +0000 4.2024-06-14 18:42:26.341091 Simulating magnetic field of an RF Coplanar Waveguide https://www.comsol.com/forum/thread/341082/Simulating-magnetic-field-of-an-RF-Coplanar-Waveguide-?last=2024-06-14T18:11:41Z <p>Hello,</p> <p>I hope all is well. I was wondering if someone could help me with simulating the magnetic field due to exciting a coplaner waveguide in the RF module. I added magnetic fields Physics module and a stationary solver step, but I cannot get a plot of the magnetic field</p> Fri, 14 Jun 2024 16:12:48 +0000 4.2024-06-14 16:12:48.341082 Issues when solving linear system in Frequency Domain study step when removing symmetry BCs https://www.comsol.com/forum/thread/341061/Issues-when-solving-linear-system-in-Frequency-Domain-study-step-when-removing-symmetry-BCs?last=2024-06-14T08:00:49Z <p>Hi,</p> <p>I have a COMSOL Multiphysics model in which I simulate an optical cavity with a high Q-factor mode around 194 THz. My goal is to first solve for the eigenmodes of the optical cavity using the 'Eigenvalues' study step. From this, I obtain the extact eigenfrequency of my desired mode. In a next step I would like to excite this mode using a 'Frequency Domain' study step. To do this I place a magnetic dipole in the cavity to excite this mode.</p> <p>I first performed this sequence of steps on a model which uses a PEC (XZ plane) and PMC (YZ plane) to exploit the symmetry of my mode. Everything works well and in my simulation with the 'Frequency Domain' study step, I can see that I have excited the correct mode.</p> <p>When I move the PMC boundary condition to investigate a design that is not symmetric in the x-direction, I can solve the 'Eigen Frequency' problem. However, when I now plug the eigenfrequency of my mode in the 'Frequency Domain' step, the simulation gives the following error:</p> <p><em>The following feature has encountered a problem: - Feature: Stationary Solver 1 (sol1/s1) *Undefined value found. - Detail: NaN or Inf found when solving linear system using BiCGStab.</em> *</p> <p>I have tried the same for a model without any symmetry boundary conditions and got the same error. I have verified that the correct BC apply when I remove the PMC. Strange enough I get this error after the following lines in the output file:</p> <p><em>Iter SolEst Damping Stepsize #Res #Jac #Sol LinIt LinErr LinRes ------- Current Progress: 71 % - Solving linear system Memory: 47703/48062 59739/60208 1 - 1.0000000 - 1 1 1 1 1.2e+51 1 ---------- Current Progress: 100 % - Solving linear system Memory: 5231/49874 9221/61944 Solution time: 262 s. (4 minutes, 22 seconds) Physical memory: 49.87 GB Virtual memory: 61.94 GB Ended at Jun 13, 2024, 10:07:23 AM.</em></p> <p>Which seems to suggest that my model did actually work and solved the Frequency Domain study step. Can anyone help me understanding what is going wrong here?</p> Fri, 14 Jun 2024 08:00:49 +0000 4.2024-06-14 08:00:49.341061 Effect of temperature on simulation of piezoelectric sensor. https://www.comsol.com/forum/thread/341051/Effect-of-temperature-on-simulation-of-piezoelectric-sensor?last=2024-06-14T06:19:05Z <p>Hello Everyone I am simulating a piezoelectric sensor. I want to see the effect of temperature on sensor specification like resonance frequency, displacement and their sensitivity. Can anyone help me to configure a model which can simulate the structure with temperature?</p> Fri, 14 Jun 2024 06:19:05 +0000 4.2024-06-14 06:19:05.341051 Two-Phase Flow to model the water entry in a tube https://www.comsol.com/forum/thread/341042/Two-Phase-Flow-to-model-the-water-entry-in-a-tube?last=2024-06-13T23:58:17Z <p>Hi, I am Martha. I am working on a project to analyze the water flow path through two materials. I want to model the air in a tube and see if the suction is enough to pull the water from the soil. Does anyone have an idea of how I could model it? At this moment, I am thinking about using the two-phase flow.</p> <p>Thank you!</p> Thu, 13 Jun 2024 23:58:17 +0000 4.2024-06-13 23:58:17.341042 Electromagnetic Waves simulation including also Electrical Circuit and Magnetic Fields physics https://www.comsol.com/forum/thread/341041/Electromagnetic-Waves-simulation-including-also-Electrical-Circuit-and-Magnetic-Fields-physics?last=2024-06-14T12:51:00Z <p>Hi, my first effort simulating electromagnetic fields generated by an electric circuit. In this case a simple bandbass filter. I utilize three physics: Electromagnetic Waves, Electrical Circuit and Magnetic Fields. First I would like to do a frequency domain study. All went quite fine if all components (except the pcb and wiring) were lumped parts and included in Electromagnetic Waves physics. Changing the coil to a geometrical model and using also Magnetics Fields physics made it more difficult to solve. And what for I cannot define the components in the Electromagnetic Waves if I included Electrical Circuit physics (the capacitors in the circuit). My ultimate goal would be an electromagnetic simulation (both frequency and time) for a more complicated circuit including a power converter (a switch, a transformer, capacitors and pcb with wiring). The transformer and wires would be geometrical models and the rest could would be lumped parts. This first simple model I managed to solve in one frequency point (about 0.5-1 hours simulation time) but the simulation failed at the second point. 1) Is there errors in the model? 2) Maybe a different solver or changes in the solver configuration?</p> Thu, 13 Jun 2024 22:31:29 +0000 4.2024-06-13 22:31:29.341041 Problems with coil core https://www.comsol.com/forum/thread/341032/Problems-with-coil-core?last=2024-06-13T22:28:54Z <p>Dear All,</p> <p>I'm stuck on a very simple problem, but it prevents me from analyzing my model. When adding a core to my coil, the inductance should be greater, but it simply doesn't change. Can anybody help me? In the attached model I have a square coils with the input and output, interfacing the air boundaries. Simply enabling the material core I can set the presence of a core.</p> <p>Thanks comsol 6.2</p> Thu, 13 Jun 2024 22:28:54 +0000 4.2024-06-13 22:28:54.341032 K values stays constant and spring structure gets deformed on force application in COMSOL https://www.comsol.com/forum/thread/340961/K-values-stays-constant-and-spring-structure-gets-deformed-on-force-application-in-COMSOL?last=2024-06-14T13:31:52Z <p>Hello Experts,</p> <p>I recieved an error in my 3D model in comsol for a force sensor . We use the concept F = Kx(Hooke law)</p> <p>On point of application of the force as shown in K values error screenshot, the spring gets deformed when I run the l6 parameter defined value from (5,1,7) mm range. I attached the screenshots of the error.</p> <p>1) displacement_z direction screenshot : denotes the displacement of the spring in z direction. 2) k variable formula screenshot: shows the formula to evaluate the k value . 3) k values error screenshot: shows the k value as constant even when we vary the parameter range from 5 mm to 7 mm range since the springs gets deformed as can be seen in the diagram. The point of application of force F is shown in the diagram.</p> <p>Can you please suggest the cause behind this error and how can i fix it?</p> <p>P.S: The .mph file is 30MB therefore it is not possible to upload in the post as we have upload file limit of 5MB</p> <p>Kind regards Amit</p> Thu, 13 Jun 2024 14:09:00 +0000 4.2024-06-13 14:09:00.340961 Eigenvalue/Eigenvalue boundary conditions https://www.comsol.com/forum/thread/340951/EigenvalueEigenvalue-boundary-conditions?last=2024-06-13T10:37:23Z <p>Dear forum,</p> <p>I have a stationary study of the flow around a cylinder performed in comsol using a nondimensional framework. Now I want to find the leading eigenvalues using this study and I have a couple of questions: 1) How to define the shift value if the eigenvalue is a complex number? Is it correct to say RealPartValue+i*ImaginaryPartValue? 2) I dont find a way to set the boundary conditions of the eigenvalue problem, are they somehow already implemented? So far I tried several options but everytime I get Lambda=0 as results.</p> <p>Additional question: I have tried to implement the weak formulation of an eigenvalue problem using the Weak Form PDE but again I don't see the boundary condition options. Also, Is it possible to use the data from a SPF study such as velocities and pressure and implement the weak fomulation of an eigenvalue problem?</p> <p>Reagrds, Robert</p> Thu, 13 Jun 2024 10:37:23 +0000 4.2024-06-13 10:37:23.340951 use of several selections in mphinterp https://www.comsol.com/forum/thread/340941/use-of-several-selections-in-mphinterp?last=2024-06-13T08:48:46Z <p>Hi,</p> <p>I am using mphinterp with selection.</p> <p>The "help" indicates that it can be a list of selected elements</p> <blockquote> <blockquote> <blockquote> <blockquote> <blockquote> <blockquote> <blockquote> <blockquote> <p>> selection Positive Integer array | Selection list String | {'all'} &lt;&lt;&lt;&lt;&lt;&lt;&lt;&lt;</p> </blockquote> </blockquote> </blockquote> </blockquote> </blockquote> </blockquote> </blockquote> </blockquote> <p>However, when I test an array of selected elements, I get an error message : "only a single boundary is allowed"</p> <p>Which is it ? Can I export values from a plane made of several surface elements ?</p> <p>Best regards, Alexandra.</p> Thu, 13 Jun 2024 08:48:46 +0000 4.2024-06-13 08:48:46.340941 How to export all plots and all plot data for every experiment in a Parametric Sweep? https://www.comsol.com/forum/thread/340912/How-to-export-all-plots-and-all-plot-data-for-every-experiment-in-a-Parametric-Sweep?last=2024-06-12T22:23:55Z <p>I am running a parametric study on a 3D model. I have a cut plane dataset that I am using to generate a 2D surface plot. I want to export every 2D surface plot as an image, and also export a .csv of the dataset. I want to do this for each parameter in the parametric study, with the parameter values automatically placed in the filename. Can this be done in Comsol?</p> <p>I can do this manually, by manually writing out the filename and then exporting each 2D surface plot as an image and then a .csv dataset for every single different parameter in the sweep, but I will be doing a large sweep, and it is not feasible to sit and do that for every single experiment in the sweep.</p> <p>I have tried exporting the plot data in a CSV format all at once, but I get the error "Data can only be exported if the same mesh is used for all parameters" (see attached image)</p> Wed, 12 Jun 2024 22:23:55 +0000 4.2024-06-12 22:23:55.340912 Thermal Runaway Modeling negative temperature https://www.comsol.com/forum/thread/340911/Thermal-Runaway-Modeling-negative-temperature?last=2024-06-17T16:09:35Z <p>Hello everyone,</p> <p>I am building a model to investigate the thermal runaway propagation behavior in a battery module. I am currently facing a problem where I keep getting negative temperatures between the cells that are next to propagate. The propagation also happens way too fast (within a minute for 11 cells) so I am wondering if those negative temperatures might be the reason. It might be important to add that the negative temperatures keep appearing in the battery holders which are placed at the bottom part of the batteries. When I delete them, the negative temperatures disappear.</p> <p>Do you have any idea why this might be happening? Any advice is welcome, thank you!</p> Wed, 12 Jun 2024 21:01:12 +0000 4.2024-06-12 21:01:12.340911