Skip to content

Fix #351 #353

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 12 additions & 8 deletions .github/workflows/full-mpich.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,18 @@ on:
- develop
- master
- slegrand-actions-debug

pull_request:
branches:
- develop

# For development phase
workflow_dispatch:


concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
linux:
strategy:
Expand All @@ -27,7 +31,7 @@ jobs:

name: Ubuntu ${{ matrix.version }} with ${{ matrix.cfg.opts }} \
- ${{ github.workflow }}

runs-on: ubuntu-${{ matrix.version }}

steps:
Expand All @@ -46,7 +50,7 @@ jobs:
./configure --enable-download ${{ matrix.cfg.opts }} \
--prefix="${HOME}/freefem"
./3rdparty/getall -a -o PETSc

- name: PETSc
run: |
cd 3rdparty/ff-petsc
Expand Down Expand Up @@ -84,12 +88,12 @@ jobs:
cfg:
- {opts: --enable-debug}
- {opts: --enable-optim --enable-generic}

name: MacOS ${{ matrix.version }} with ${{ matrix.cfg.opts }} \
- ${{ github.workflow }}

runs-on: macos-${{ matrix.version }}

steps:
- uses: actions/checkout@v4

Expand Down Expand Up @@ -123,7 +127,7 @@ jobs:
./configure --enable-download ${{ matrix.cfg.opts }} \
--prefix="${HOME}/freefem"
./3rdparty/getall -a -o PETSc

- name: PETSc
run: |
cd 3rdparty/ff-petsc
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/full-msmpi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,18 @@ on:
- develop
- master
- slegrand-actions-debug

pull_request:
branches:
- develop

# For development phase
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
windows:
strategy:
Expand All @@ -23,7 +27,7 @@ jobs:
cfg:
# - {opts: --enable-debug}
- {opts: --enable-optim --enable-generic}

name: Windows Server 2022 with ${{ matrix.cfg.opts }} - ${{github.workflow}}
runs-on: windows-2022

Expand Down Expand Up @@ -68,7 +72,7 @@ jobs:
run: |
pacman -R --noconfirm mingw-w64-x86_64-python mingw-w64-x86_64-gdb \
mingw-w64-x86_64-gdb-multiarch

- uses: actions/checkout@v4

- name: Configure
Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/full-openmpi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,18 @@ on:
- develop
- master
- slegrand-actions-debug

pull_request:
branches:
- develop

# For development phase
workflow_dispatch:


concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
linux:
strategy:
Expand All @@ -27,7 +31,7 @@ jobs:

name: Ubuntu ${{ matrix.version }} with ${{ matrix.cfg.opts }} \
- ${{ github.workflow }}

runs-on: ubuntu-${{ matrix.version }}

steps:
Expand Down
15 changes: 10 additions & 5 deletions .github/workflows/minimal.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
name: Minimal version

on:
push:
branches:
- develop
- master
- slegrand-actions-debug

pull_request:
branches:
- develop

# For development phase
workflow_dispatch:


concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
linux:
strategy:
Expand Down Expand Up @@ -59,7 +64,7 @@ jobs:
cfg:
- {opts: --enable-debug}
- {opts: --enable-optim --enable-generic}

name: MacOS ${{ matrix.version }} with ${{ matrix.cfg.opts }} - ${{ github.workflow }}
runs-on: macos-${{ matrix.version }}

Expand Down Expand Up @@ -97,7 +102,7 @@ jobs:
cfg:
- {opts: --enable-debug}
- {opts: --enable-optim --enable-generic}

name: Windows Server 2022 with ${{ matrix.cfg.opts }} - ${{ github.workflow }}
runs-on: windows-2022

Expand Down
12 changes: 8 additions & 4 deletions .github/workflows/sequential.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,18 @@ on:
- develop
- master
- slegrand-actions-debug

pull_request:
branches:
- develop

# For development phase
workflow_dispatch:


concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
linux:
strategy:
Expand Down Expand Up @@ -62,7 +66,7 @@ jobs:
cfg:
- {opts: --enable-debug}
- {opts: --enable-optim --enable-generic}

name: MacOS ${{ matrix.version }} with ${{ matrix.cfg.opts }} - ${{ github.worflow }}
runs-on: macos-${{ matrix.version }}

Expand Down Expand Up @@ -99,7 +103,7 @@ jobs:
cfg:
# - {opts: --enable-debug}
- {opts: --enable-optim --enable-generic}

name: Windows Server 2022 with ${{ matrix.cfg.opts }} - ${{github.workflow}}
runs-on: windows-2022

Expand Down
2 changes: 1 addition & 1 deletion src/fflib/problem.cpp
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -10017,7 +10017,7 @@ bool AssembleVarForm(Stack stack,const MMesh & Th,const FESpace1 & Uh,const FESp
int ddf=K(df);
// AA(ddf,ddf) =tgv;
if (Aii) onBC[ddf]='1'; ;//A->SetBC(ddf, tgv);// change 21 dec 2010 FH (Hack of ILU)
if (B) (*B)[ddf]= tgv1*gg[df];
if (B) (*B)[ddf]=tgv1*gg[df];
if (X) (*X)[ddf]=gg[df];
}
}
Expand Down
42 changes: 38 additions & 4 deletions src/fflib/problem.hpp
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,13 @@
*/
#ifndef PROBLEM_HPP_
#define PROBLEM_HPP_

#include <limits>
namespace FreeFempp {
template<class R>
class TypeVarForm;
}

extern Block *currentblock;

template<class K> class Matrice_Creuse;
Expand Down Expand Up @@ -1379,11 +1386,38 @@ AnyType OpArraytoLinearForm<R,MMesh,v_fes>::Op::operator()(Stack stack) const
ffassert(px->N() == NbOfDF);
}
KN_<R> xx( px ? *(KN_<R> *) px : GetAny<KN_<R> >((*x)(stack) ));
if(zero && NbOfDF )
xx=R();
KN<R> cc;
list<C_F0>::const_iterator ii,ib=l->largs.begin(),
ie=l->largs.end();
using namespace FreeFempp;
TypeVarForm<R> *tvf=FreeFempp::TypeVarForm<R>::Global;
assert( tvf);
bool ret = false;
for (ii=ib;ii != ie;ii++)
{
if (ii->left() == tvf->tBC) {
ret=true;
continue;
}
}
if(zero && NbOfDF)
xx=R();
else if(!zero && NbOfDF && ret) {
cc.resize(xx.n);
cc = xx;
}

if ( pVh && AssembleVarForm<R,MatriceCreuse<R>,MMesh,FESpaceT,FESpaceT>(stack,Vh.Th,Vh,Vh,false,0,&xx,l->largs) )
AssembleBC<R,MMesh,FESpaceT,FESpaceT>(stack,Vh.Th,Vh,Vh,false,0,&xx,0,l->largs,tgv);
if ( pVh && AssembleVarForm<R,MatriceCreuse<R>,MMesh,FESpaceT,FESpaceT>(stack,Vh.Th,Vh,Vh,false,0,&xx,l->largs) ) {
if (!zero && NbOfDF && ret) {
KN<R> bb(xx.n, std::numeric_limits<double>::lowest());
AssembleBC<R,MMesh,FESpaceT,FESpaceT>(stack,Vh.Th,Vh,Vh,false,0,&bb,0,l->largs,tgv);
for(int i = 0; i < xx.n; ++i)
if(bb[i] != std::numeric_limits<double>::lowest())
xx[i] = cc[i] + bb[i];
}
else
AssembleBC<R,MMesh,FESpaceT,FESpaceT>(stack,Vh.Th,Vh,Vh,false,0,&xx,0,l->largs,tgv);
}
return SetAny<KN_<R> >(xx);
}

Expand Down
Empty file modified src/lglib/mymain.cpp
100755 → 100644
Empty file.
Loading