CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums

Search Results

Register Blogs Members List Search Today's Posts Mark Forums Read

Showing results 1 to 6 of 6
Search took 0.00 seconds.
Search: Posts Made By: alexeym
Forum: OpenFOAM Programming & Development September 17, 2013, 14:03
Replies: 17
Views: 4,097
Posted By alexeym
I create temporary alphaCheck_ field on every...

I create temporary alphaCheck_ field on every call to correct method (so I don't need this field on the class level) as I thought you only need this variable in correct() method. If you're going to...
Forum: OpenFOAM Programming & Development September 13, 2013, 17:14
Replies: 17
Views: 4,097
Posted By alexeym
You are right, I forgot to change the name in all...

You are right, I forgot to change the name in all places. This time I've fixed it.

I don't know why, there's no major differences between our file sets (diff -u kOmega2006.* kOmega2006C2.* gives...
Forum: OpenFOAM Programming & Development September 13, 2013, 02:12
Replies: 17
Views: 4,097
Posted By alexeym
Well... 1. As you'd like to change alphad_...

Well...

1. As you'd like to change alphad_ it should not be declared as const. This will fix the last error.

2. On the other hand if you create alphad_ as

volScalarField alphad_
(
...
Forum: OpenFOAM Programming & Development September 12, 2013, 16:34
Replies: 17
Views: 4,097
Posted By alexeym
1. Well, you can try to create it as you've...

1. Well, you can try to create it as you've described it in the post. Though I'm not quite sure that mag(...) can be negative. Do I get it right and you'd like to check sign of scalar product of two...
Forum: OpenFOAM Programming & Development September 11, 2013, 01:18
Replies: 17
Views: 4,097
Posted By alexeym
As you can see from the error message: you are...

As you can see from the error message: you are trying to iterate over scalar but forAll statement usually used for iterating over a field. And your alphad_ and alphado_ are really scalars:


...
Forum: OpenFOAM Programming & Development September 10, 2013, 05:39
Replies: 17
Views: 4,097
Posted By alexeym
Maybe it can be rewritten as alphad_ =...

Maybe it can be rewritten as

alphad_ = 0.5*(1 - sign(alphaCheck))*alphado_ + 0.5*(1 + sign(alphaCheck))*alphad_;


Or you can loop over the field with


forAll(alphad_, cellI))
{
Showing results 1 to 6 of 6

 
Forum Jump

All times are GMT -4. The time now is 00:21.