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

Acoustic / Ultrasonic related queries

$
0
0

Hi,

can any one suggest me, how to develop wave equation in comsol model.?

A wairing your reply.

Regards,

Vipul


plot Dean flow vortex

$
0
0

I simulated the flow in a curved channel, and want to see the streamline in the cross section. I defined the cut plane, and since the curve is some sort parameterive curve, I didn't know how to calculate the projected velocity on the x and y axices of the cut plane.

Simulating flow through a branched pipe

$
0
0

I am new to COMSOL. I am looking for a tool that can simulate flow through branched pipe.

I'd like to know if it is possible to simulate 1D solute transport in a pipe section that diverges into 2 sections and converges again .

How do you plot a Temperature graph along this line?

$
0
0

I have a 3D reactor model with baffles, and I want to plot the temperature and concentration of the average velocity path (line shown on the surface of the reactor).

Need a way to determine the temperature or concentration along the line or at certain points of the line.

how to set up a Semi-infinite area

$
0
0

I want to build a semi-infinite area. how to setup the periodic boundary condition

Specifying lengths while creating geometries

$
0
0

I 'm following this tutorial to create a pipe geometry that branches to form 2 sub branches and coverges again.

The geometry is specified by selecting a polygon and specifying the x and y coordinates (the following steps are given in the tutorial) .

Polygon 1 (pol1) 1 In the Geometry toolbar, click Polygon. 2 In the Settings window for Polygon, locate the Object Type section. 3 From the Type list, choose Open curve. 4 Locate the Coordinates section. From the Data source list, choose Vectors. 5 In the x text field, type 0 80 80 90 90 120 120 130 130 180 . 6 In the y text field, type 0 0 0 20 20 20 20 0 0 0.

Here, I don't understand why certain coordinates are mentioned twice. e.g. 80 0; 80 0. Is it required to mention twice when there is a curve?

Secondly, I would like to know how if there is an example available for specifiying curved geometries.

Also, I obseve the length of the pipe segment is in meters (the coordinate positions are specified in meters). Is it possible to specify the length in micrmeters?

Many thanks for your time and attention

COMSOL Unable to Compute Third Order Space Derivative

$
0
0

Hi, I have been working on a project which requires the evaluation of a third order space derivative term in my 1-D PDE, and this is done using the Coefficient Form PDE module. I found that COMSOL outputs the third order derivative d^3u/dx^3 as zero under the results plot.

I know this is clearly not the case since the plot of uxx clearly shows a curve and not a constant.

Since then I have search the internet regarding this issue and have tried other methods of specifying the derivative, including defining a new variable

F=uxx

and plotting d(F,x) in the results section still returns zero for all values of x.

I have also tried different order Langrange shape functions (up to septic) and yet the results are still the same. I am baffled by this as I even tested for a simple function such as

u(x)=4x^4 +3x^3-2x^2+x+7

and I am still unable to obtain the third order space derivative under Results.

Any assistance on this issue would be greatly appreciated. Thank you

Plot 4D Comsol 5.4

$
0
0

Hi, I try to plot an interpolating function consisting of x,y,z (point coordinates) and I (which takes values between 1 and 3). I get the attached photo but the domain is cut into a cube shape, when in reality the y reaches 1000 meters. Who can help me understand why?


Exciting Surface plasmon polaritons with a point source

$
0
0

Hi, I am new to COMSOL and would like to know how to excite surface plasmon polaritons using a point source place the the metal-dielectric interface.

Thanks, Ashwin

Regarding Mode Analysis

$
0
0

Hello Everyone, I am very new to this field so can anyone please suggest me how to model Rectangular Waveguide(WR 90) for mode alalysis so that i can estimate S parameters of composite materials?

extracting information with mpheval() - ndgrid vs meshgrid

$
0
0

Hi,

I could not easily find anything about this topic, so excuse if I missed something.

In page 288 of the LiveLinkForMATLABGuide, there's an example of how to extract information using mpheval() with coordinates. The example states to use:

x0 = [0,1e-2,2.5e-2,5e-2]; y0 = x0; z0 = [5e-3,1e-2,1.1e-2];

[x,y,z] = meshgrid(x0,y0,z0); xx = [x(:),y(:),z(:)]';

T = mphinterp(model,'T','coord',xx);

which gives a (3,N) vector for coordinates (first index marks x, y, or z). The quantity returned, T, has the same size (3,N). Suppose I now want to view the result of one slice (say the x-z plane, for y=2.5e-2). The question is, how can I reshape() T into a (3,Nx,Ny,Nz) tensor, where then I could select all the x-coordinates of T for Ny=2, i.e. in MATLAB:

T3D(1,:,2,:);

After lots of digging around, I found that meshgrid() is not the correct function for this, but one should use ndgrid() instead. Here's an example MATLAB script to show this. We expect the coordinates of an axis to be equal in its plane regardless of where we slice. In other words, the 2D matrix of the x or z coordinate of the x-z plane for arbitrary y, should be equal:

clc;

x0 = [11,12];

y0 = [21,22,23];

z0 = [31,32,33,34];

[x,y,z] = ndgrid(x0,y0,z0); %% works!

%[x,y,z] = meshgrid(x0,y0,z0); %% doesn't!

coords = [x(:),y(:),z(:)]';

xyz = reshape(coords,3,numel(x0),numel(y0),numel(z0));

disp('x-y (x along z)'); % x-y plane, x coordinates, along z

x1=squeeze(xyz(1,:,:,1));

x2=squeeze(xyz(1,:,:,2));

x3=squeeze(xyz(1,:,:,3));

x4=squeeze(xyz(1,:,:,4));

all(x1(:)==x2(:)) && all(x3(:)==x3(:)) && all(x3(:)==x4(:))

disp('x-y (y along z)'); % x-y plane, y coordinates, along z

x1=squeeze(xyz(2,:,:,1));

x2=squeeze(xyz(2,:,:,2));

x3=squeeze(xyz(2,:,:,3));

x4=squeeze(xyz(2,:,:,4));

all(x1(:)==x2(:)) && all(x3(:)==x3(:)) && all(x3(:)==x4(:))

disp('x-z (x along y)'); % x-z plane, x coordinates, along y

x1=squeeze(xyz(1,:,1,:));

x2=squeeze(xyz(1,:,2,:));

x3=squeeze(xyz(1,:,3,:));

all(x1(:)==x2(:)) && all(x3(:)==x3(:))

disp('x-z (z along y)'); % x-z plane, z coordinates, along y

x1=squeeze(xyz(3,:,1,:));

x2=squeeze(xyz(3,:,2,:));

x3=squeeze(xyz(3,:,3,:));

all(x1(:)==x2(:)) && all(x3(:)==x3(:))

disp('y-z (y along x)'); % y-z plane, y coordinates, along x

x1=squeeze(xyz(2,1,:,:));

x2=squeeze(xyz(2,2,:,:));

all(x1(:)==x2(:))

disp('y-z (z along x)'); % y-z plane, y coordinates, along x

x1=squeeze(xyz(3,1,:,:));

x2=squeeze(xyz(3,2,:,:));

all(x1(:)==x2(:))

Just to finalize, here's an example of how I extract the x-z plane of the By magnetic field component at the first and last y index, in MATLAB, in my code:

[Bx,By,Bz, unit] = mphinterp(model,{'mf.Bx','mf.By','mf.Bz'},'dataset','dset1','coord',coords/lu,'solnum',1); % solnum referes to initial time

By3D = reshape(By,NDx,NDy,NDz);

figure; imagesc(squeeze(By3D(:,1,:)));
figure; imagesc(squeeze(By3D(:,end,:)));

lu is the length unit used in COMSOL (I converted everything to meters). NDx,NDy,NDz are the vector lengths of the original x,y,z coordinate vectors. Hope this helps!

ELECTROPHORETIC DEPOSITION

$
0
0

Hello everyone,

I would like to simulate AC electrophoretic deposition of SiC particles in COMSOL. Is it correct to use the electrodepositon module?

Coefficient form PDE: Ergun equation

$
0
0

I am trying to study on the pressure drop along the adsorption column by solving the ergun equation via the PDE. However, the simulation resuls shows no pressure drop. Anyone know how can I solve this?

Parametric sensitivity analysis

$
0
0

Does anybody know how to do Parametric senstivity analysis in comsol 5.3a?

Gradient of the magnetic field is zero

$
0
0

Hi forum,

I'm relatively new to COMSOL and am trying to plot the gradient of the magnetic field from a 2D block magnet in the Magnetic Fields, No Currents (mfnc) physics module, along with a Coefficient Form PDE module to calculate the gradient of the x,y,z components of the field --> I set my source terms to be mf.Hx, mf.Hy, and mf.Hz as the examples below recomended but they seem to be unknown varaibles - this may be the source of the issue.

I am using 2 stationary studies - the first to calculate the magnetic field, the second to calculate the coefficient form PDE and am still having no luck displaying the gradient.

I have attached my model - any help would be much appreciated! Thanks, Alex

https://www.comsol.fr/forum/thread/attachment/98701/Gradients_of_Magnetic_Field_42a-17775.pdf https://www.comsol.com/blogs/plotting-spatial-derivatives-magnetic-field/


Surface integration for gold nanoparticle

$
0
0

What is the expression for surface integration of gold nanoparticle?

Schottky drain current of 2D material FET

$
0
0

Hi Forum, I'm trying to plot the schottky drain current varying by applied gate voltage in WS2 FET, which has p-type doped Si substrate and WS2 channel. Although my design give pretty much accceptable result for ID vs. Vd, ID vs. Vg does not give resonable result. The drain current difference from -30 to 30V gate voltage is only about 5 uA, but what I expected is like an exponential increase. Please give any idea so that I can solve this problem. Thanks for reading.

Including gravity effects in CFD simulation

$
0
0

Hello everyone!

I am modeling laminar flow through a vertical pipe whose inlet is at the base of the pipe. The outlet is normal (90 degrees) to the pipe. The pipe is vertical along the z-axis. My analysis runs without no problems if I do not include gravity effects along the z-axis. However, the simulation never converges if I include the gravity effects. What should I try to be able to get a solution that includes the effects of gravity along the z-axis?

Thank you so much for your time!!

(my geometry only includes the water domain)

Radiation Boundary Condition for Wave Equation in Coefficient for PDE

$
0
0

Hi, I'm currently working with a 1-D wave equation in the Coefficient Form PDE physics.

I want to specify a boundary as an open boundary/ radiation boundary as I do not want any reflection of the incident wave. According to some sources I've referred, an open boundary for 1-D wave equation can be written as a propagation equation

with c being the velocity going outwards.

I would like to know if there is a way to specify this boundary condition for in the Coeffcient Form PDE, preferably without have to deal with weak form expressions.

Many thanks in advance.

Regarding the expression of normal to a curve of 3D surface.

$
0
0

Hi All,

I am working with a 3D-Block (Picture attached). Over this 3D block, there is 2D curve PQ, embaded in ZX-plane Now I wish to specify some perticular condition along the normal to the curve PQ in ZX-plane (along the arrows shown in attached pic).

When I try to specify the the normal (nx,ny,nz), comsol calculates the normal along Y Direction. Because Comsol is computing the normal to semi circled surface PQ and not to the curve PQ. Thus resulting the normal along Y-axis Direction and not along the required direction.

Can someone describe how to find the normal direction to curve PQ?

Viewing all 26323 articles
Browse latest View live