Illegal symbol Log Out | Topics | Search
Moderators | Register | Edit Profile

FlexPDE User's Forum » User Postings » Illegal symbol « Previous Next »

Author Message
Top of pagePrevious messageNext messageBottom of page Link to this message

Serge-Étienne Parent (dernier_recours)
Junior Member
Username: dernier_recours

Post Number: 3
Registered: 04-2005
Posted on Thursday, June 09, 2005 - 04:17 pm:   

Hello,

This is a gas diffusion/advection model. I obtain the error message "Illegal Symbol" with the student license of FlexPDE 4.2.15. The definitions have been revised into Matlab, they are coherent. Maybe the variables and equations are not correctly stated?

Thanks,

SÉP

application/octet-streammy pde file
essai01.pde (5.9 k)
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert Thode (rct130)
Junior Member
Username: rct130

Post Number: 3
Registered: 11-2003
Posted on Thursday, June 09, 2005 - 06:45 pm:   

HI,

When defining equations you need to have an = sign for each equation. I am not sure if you need to define all those variables. Can some be put in the Definitions section.

See the example REACTION.PDE in the help file, its formulation might be close to what you are trying to model.

Rob
rob@soilvision.com
Top of pagePrevious messageNext messageBottom of page Link to this message

Serge-Étienne Parent (dernier_recours)
Member
Username: dernier_recours

Post Number: 4
Registered: 04-2005
Posted on Monday, June 13, 2005 - 01:48 pm:   

Thanks for the reply. The equations were adjusted. It seems ok for the problem statements. Now, solving...

The solver crashes and tells me that there is an error:
DIVIDE BY ZERO

I tried different SELECT options, but the error persists. I tried also to force some (definition) variables to be non-zero -- a=max(b*c,0.001) -- but when a variable is forced, another makes the solver stop.

Should I force all variables to be non-zero or is there an option with SELECT I should use?

application/octet-streammy new pde file
essai01.pde (6.2 k)
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert G. Nelson (rgnelson)
Moderator
Username: rgnelson

Post Number: 378
Registered: 06-2003
Posted on Monday, June 13, 2005 - 02:41 pm:   

The "Divide by zero" report shows the position in the script where this error occurred. It is in dividing by y_o2.

Your definition of y_o2 is:
y_o2=c_o2/(c_co2+c_o2+c_n2)


All the quantities in this expression are system variables, which by default are initialized to zero. Ergo, divide by zero.

If you want to divide by these things, you must provide non-zero INITIAL VALUES for the variables.

Top of pagePrevious messageNext messageBottom of page Link to this message

Amlan Banerjee (amlan)
Member
Username: amlan

Post Number: 4
Registered: 07-2005
Posted on Tuesday, July 19, 2005 - 04:52 pm:   

Hi:

I getting an error message "operands are not of the same type".

I am giving the part of my code here where i am getting the error message. every time i am trying to run the code it highlights the + sign and telling me operand error.

EQUATIONS

Vol: dt(Vol)=abs(Vol)^(2/3)*(Ohm-1)

c_Al: 1e-8*dt(c_Al) = div(D*grad(c_Al))+(3*(c_Al*vel))-(2*abs(Vol)^(2/3)*(Ohm-1))

c_H: 1e-8*dt(c_H)=div(D*grad(c_H))+ (3*(c_H*vel))+ (3*abs(Vol)^(2/3)*(Ohm-1))

c_SiO2: 1e-8*dt(c_SiO2) = div(D*grad(c_SiO2*vel))+(3*(c_SiO2))-(2*abs(Vol)^(2/3)*(Ohm-1))


please let me know how to solve this error.

sincerely

Amlan
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert G. Nelson (rgnelson)
Moderator
Username: rgnelson

Post Number: 409
Registered: 06-2003
Posted on Tuesday, July 19, 2005 - 07:00 pm:   

You didn't say which of the four plus signs shown was the one with the error.

Nevertheless, judging from your previous posting, I would guess that you have some multi-byte characters imbedded in the text.

Did you prepare this script with an external editor?

I suggest that using FlexPDE's built-in editor you go to the point of the error and delete the offending symbol and one on each side of it, and retype the text. This should eliminate the invisible character or multi-byte code and allow the script to run.

Add Your Message Here
Post:
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Password:
Options: Enable HTML code in message
Automatically activate URLs in message
Action:

Topics | Last Day | Last Week | Tree View | Search | Help/Instructions | Program Credits Administration